Android OS Core Cryyyyyyuujuoncepts.pptx

viratreddy5353 7 views 31 slides Jun 20, 2024
Slide 1
Slide 1 of 31
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31

About This Presentation

Ddndkkx


Slide Content

Android OS : Core Concepts Dr. Jeyakesavan Veerasamy Sr. Lecturer University of Texas at Dallas [email protected]

Agenda Introduction to Android devices Environment overview Android concepts Application components Activities, Services, Content providers, Broadcast receivers “Hello” application Summary

Development Environment Java Development Kit (JDK) Eclipse IDE Android Development Tools (ADT) plug-in SDK starter package Platforms (1.0, 2.0, 3.0, 4.1, …) Tools (debug, …) Reference: http://developer.android.com/sdk/installing.html JDK Eclipse ADT Plug-in Android SDK

Development Process for Android Applications

Android Architecture

Android Runtime Environment Dalvik VM for each application common Linux kernel JRE x.class y.class Linux kernel VM VM APP APP …

Basics: UNIX security compare it with Windows security

Application Security Android operating system is based on multi-user Linux system. Each application is treated as a different user. Each application uses unique Linux user ID. E very application runs as a Linux process.

Application security … It's possible to arrange for two applications to share the same Linux user ID, in which case they are able to access each other's files – can run as same Linux process and share the same VM (applications use same certificate). An application can request permission to access device data such as the user's contacts, SMS messages, the mountable storage (SD card), camera, Bluetooth, and more. All application permissions must be granted by the user at install time.

Processes & Threads Every application runs in its own process and all components of the application run in that process, by default -- UI thread Any slow, blocking operations in an activity should be done in a new thread, to avoid slowing down the user interface. If application does not respond in 5 seconds, " application not responding " (ANR) dialog appears.

Process lifecycle: Importance Hierarchy Foreground process Visible process Service process Background process Empty process “Lower importance” tasks may be killed by Android – why? How to select a lucky one from a pool?

IPC Remote procedure calls (RPCs)

Android Application components Activities - front-end UI screens Services – back-end support Content providers – application data SQLite, web or SD card Broadcast receivers – handle system events

Activitating Components: Intent

Basics: Data Exchange A1 A3 A2 A4

Basics: Data Exchange Binary or text data  XML or JSON … Independent data checkers tools available. A1 A3 A2 A4

Sample XML data file Text format: Belgian Waffles, 5.95, two of our famous Belgian Waffles with plenty of real … , 650 Strawberry Belgian Waffles, 7.95, light Belgian waffles covered with …., 900

Application info: Manifest file Declare components Declare application requirements Application Resources?

Activity lifecycle: 3 states Resumed or Running Paused Stopped

State machine

Code

Service Lifecycle

User Interface Design

XML Layouts Declare UI elements in XML . Android provides a straightforward XML vocabulary that corresponds to the View classes and subclasses. Instantiate layout elements at runtime . Your application can create View and ViewGroup objects (and manipulate their properties) programmatically.

Application Resources

Building & running Android app

Program to say “Hello!”

Native Development Kit (NDK) Use C/C++ for development primarily for performance critical components

Summary Clean, sophsticated , yet reasonably simple. Android requires strong Java skills – heavy use of derived classes (inheritance). Development: Java code & XML definitions Reference: http:// developer.android.com/sdk/installing.html Install Android development environment and play with a few examples or try your own ideas! Marketable skill in the industry!

More references http://www.vogella.de/articles/AndroidIntent/article.html http://developer.android.com/resources/browser.html?tag=sample

Questions & Answers [email protected]
Tags