0% found this document useful (0 votes)
19 views

Android

The document provides an overview of the Android operating system, including its architecture, core components, application types and development process. It discusses topics like activities, services, content providers, broadcast receivers and other app components. It also covers layouts, views, animation and adapting to different screen orientations in Android applications.

Uploaded by

Viral Music
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views

Android

The document provides an overview of the Android operating system, including its architecture, core components, application types and development process. It discusses topics like activities, services, content providers, broadcast receivers and other app components. It also covers layouts, views, animation and adapting to different screen orientations in Android applications.

Uploaded by

Viral Music
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 7

Page 1: Android Overview

What is Android?: Android is a mobile operating system based on a modified version of Linux. It is
originally open source and free. The first version is Android 1.0 (Tiramisu).

Features of Android:

Storage: Uses SQLite, a light operational database for data storage.

Connectivity: Supports GSM, EDGE, 3G, 4G, Wi-Fi, Bluetooth, LTE, and more.

Messaging: Supports both SMS and MMS.

Web Browsing: Based on open-source web technologies, featuring a Chrome browser engine.

Media Support: Handles formats like H.263, H.264, MP4, and others.

Hardware Support: Includes accelerometer, camera, digital compass, multi-touch screen, flash
support, wireless earpiece connections, and hotspots.

Page 2: Android Architecture

Android Architecture Components:

Application Framework: Includes Application Home, Technical Aspects, and Core Application
Framework components like Activity, View System, and Service Providers.

Runtime and Libraries: Core Libraries including FreeType, WebKit, and the Dalvik Virtual Machine are
key components.

Hardware Layer: Consists of Device Drivers (Camera, Flash, Innovations), Binder (for inter-process
communication), Keypad, Wi-Fi, Audio, and Power Management.

Dalvik Virtual Machine: A special virtual machine optimized for mobile devices, focusing on efficient
power usage and performance. It is the core engine for running Android applications and includes
layers for security and graphics processing.

Surface Manager: Manages different application windows and interfaces, ensuring smooth operation
and user interaction.

Webkit: The kernel of Web Browsing in Android, ensuring efficient and effective internet navigation.

Page 3: Android Application Types and Development

Static and Dynamic Applications:

Static Applications: These are applications that do not require an internet connection, such as
calculator and camera apps.

Dynamic Applications: These are applications that rely on an internet connection, like Facebook and
music streaming apps.
Frontend and Backend in Android:

Frontend Development: This involves what a user is able to see and interact with, such as images,
text, and other UI elements. These are usually designed in XML and constitute the visual aspects of
Android applications.

Backend Development: This part of the development is not visible to users. It includes elements like
databases and is a crucial part of the backend functionality of Android applications.

Android Development Process:

Application Processing: Involves the use of Android Development Environment (ADE) and Android
Virtual Devices (AVD). It also includes development on actual Android devices.

Execution and Compilation: Discusses the compilation and execution process in Android, including
the installation of mobile apps. It implies that Android applications are similar to executable files in
other operating systems.

Page 4: Android System Components and Application Framework

Android Kernel:

Hardware Component Integration: The kernel includes device drivers for various hardware
components of Android devices, ensuring seamless integration and functionality.

Libraries in Android:

Core Code Libraries: These libraries contain the core code that provides the main features of
Android, including database support and functionalities for web browsing.

Webkit Library: Provides functionalities for web browsing, an essential part of the Android
experience.

Android Runtime:

Partition and Application Running: The runtime provides the environment for running Android
applications using Java. It includes the Dalvik Virtual Machine, which enables each app to run its own
process.

Dalvik Virtual Machine: A virtual toolbox for Android, optimized for battery efficiency in devices with
limited memory and CPU resources.

Application Framework:
Framework Capabilities: Exposes various capabilities of the Android OS to application developers,
allowing them to utilize these features in their applications.

Application Interaction: The framework enables top-layer applications to interact with the Android
device (like phone controls, browser, etc.) and manages applications downloaded or installed from
the Android market. It also locates applications that users have downloaded, providing a
comprehensive management system.

Page 5: Android Application Architecture

Android Architecture Environment:

Encourages the ability to publish and share activities securely with another application. The
following application services are architectural cornerstones of all Android applications:

Activity Manager: Controls the life cycle of your activities, including the start of activities.

Views: Used to construct the user interface for your activities.

Notification Manager: Provides a consistent mechanism for signaling users.

Content Provider: Manages application-shared data.

Resource Manager: Handles access to externalized resources.

Dalvik Virtual Machine (VM):

Key Element of Android: The Dalvik VM is a custom VM design, allowing multiple instances to run
efficiently on a variety of devices.

Underlying Linux Kernel: The Dalvik VM gives the device underlying Linux license compatibility,
providing low-level functionality including security, threading, and memory management. It also
makes it possible to write CC++ or other applications directly on the underlying Linux OS.

Page 6: Types of Android Applications

Foreground Apps:

These are apps that are useful only when actively used in the foreground. They are effectively
suspended when not visible.

Examples include gaming and map applications.

Background Apps:

Applications with limited interaction, often spending much of their time hidden.
Common examples include caching, evening, and SMS auto-responders.

Intermittent Apps:

Operate interactively but perform most of their work in the background.

These applications run diligently, notifying the user when appropriate.

Example: MediaPlayer widget.

Home Screen Widgets:

Some applications are represented only as a home screen widget.

Users can create interactive, visual elements that they can add to their home screen.

These are typically used to display dynamic information, such as battery level, weather updates,
time, date, etc.

Page 7: Structure of an Android Application

Basic Components of an Android Application:

Source Code: Contains Java source files needed for your project, like MainActivity.java.

Resource Directory: Contains drawable resources, layout files, and other resources used in the
project. These files are referenced throughout the project.

Android Library (Current Version): This contains a file called Android.jar, which includes all the
necessary class libraries for an Android application.

Assets Folder: Holds assets used by your application such as task files, database files, etc., and all the
downloadable resources.

Layouts and Values: Contains layout files (layout) and values for various resources.

Android Manifest File:

Manifest File: AndroidManifest.xml is the manifest file for the Android application. It specifies the
permissions needed by your application and other features. It also includes other details such as
application components.

Page 8: Android App Components and Structure

Android App Components:


Activities:

Define the User Interface (UI) and facilitate user interaction with the smartphone.

For example, an email application might have one activity that shows a list of emails and another to
compose an email.

Services:

Handle background processing associated with an application.

Used for long-running operations. For instance, a service might play music in the background while
the user is in a different application, or it might fetch data over the network without blocking user
interaction via an activity.

Code Examples:

Activity Example: Demonstrates how an activity is implemented as a subclass of Activity.

Example: public class MainActivity extends Activity { ... }

Service Example: Illustrates how a service is defined for handling background tasks.

Example: public class MyService extends Service { ... }

Broadcast Receivers

Broadcast Receivers: They handle communication between the Android system and applications.
Broadcast receivers respond to system-wide broadcast messages. For example, applications can
initiate broadcasts to let other applications know that some data is available for use.

Content Providers

Content Providers: These components handle data and database management issues. They supply
data from one application to others on request. Content providers ensure that the data is always
available in the required format.

Advanced Android Development Concepts

Android Activity Classes

Activities: Represent the user interface. For example, an email application might have one activity
for showing a list of emails and another for composing an email.

Services: Handle background processing. A service might play music in the background or fetch data
over the network without blocking user interaction.

Broadcast Receivers: Handle communication between the Android system and applications,
responding to broadcast messages.

Content Providers: Manage data and database management issues, supplying data from one
application to others on request.

Layouts and Views


Frame Layout: Suitable for single views but can hold multiple views, layered on top of each other.

Table Layout: Organizes views in rows and columns, each row containing multiple views.

Relative Layout: Enables positioning views relative to each other or the parent view.

Adapting to Display Orientation

Discusses handling screen orientation changes, including techniques like anchoring views to the
edges and resizing/repositioning views according to the orientation.

Basic Views in Android

Describes fundamental UI elements like TextView, Button, CheckBox, RadioButton, ToggleButton,


and RadioGroup.

Android Animation

Covers various types of animations, including Translate, Alpha, Scale, and Rotation, used to enhance
the UI.

Resource Management

Details on managing resources like strings, colors, dimensions, and styles for consistency and easier
localization.

Styles and Themes

Explains using style and theme resources to maintain a consistent look and feel across the
application.

Android Project Structure

Discusses the structure of an Android project, including essential folders like Assets, Drawable, and
layout files.

Performance Optimization

Offers guidelines for creating optimized layouts and views to enhance performance, including
avoiding unnecessary nesting and deep view hierarchies.

AutoComplete TextView
 AutoComplete TextView: This view provides suggestions automatically while the
user is typing, enhancing the user experience in forms or search fields. It utilizes an
adapter to manage the suggestions data.
Progress Bar View
 Progress Bar View: Used to provide visual feedback for long-running tasks. For
example, it can be used to show the progress of a file download or a background
task.
Android Animation
 Types of Animation: The document describes different types of animations in
Android, such as Translate, Alpha, Scale, and Rotation. Each type serves a specific
purpose:
 Translate: Moves a view along the X or Y axis.
 Alpha: Changes the transparency of a view.
 Scale: Changes the size of a view.
 Rotation: Rotates a view around a pivot point.
Handling Resources in Android
 String Resources: Externalizing strings for consistency and easier localization.
 Color Resources: Defining colors using hexadecimal values.
 Dimension Resources: Specifying sizes and margins in consistent units.
Styles and Themes
 Styles and Themes: The document explains the use of style and theme resources in
Android. Styles allow specifying attribute values used by views, facilitating a
consistent look and feel.

You might also like