Professional Documents
Culture Documents
Introductory Concepts
Objectives
Understand the characteristics of mobile devices and how they affect the development of mobile applications Have an overview of the Android Platform
Mobile Devices
Small in size
mobility and convenience
Limited memory
primary (RAM) and secondary (disk) affects the writing of programs - conserve the use of this precious resource
Mobile Devices
Robust and reliable
always carried along must stand the force of bumps, motion and occasional drops
Limited connectivity
low bandwidth some are not connected at all most use wireless connections
Android
Android, Inc.
Palo Alto, California, United States October, 2003 Andy Rubin, Rich Miner
August, 2005
Google acquired Android Inc. wholly-owned subsidiary of Google Inc. group of 84 technology and mobile companies innovation in mobile experience for Android
Android
Android
Software stack for mobile device
Operating system Middleware Key applications
Android O.S based on linux kernel Large Community of Developers writing applications Each version is developed under a code name based on a dessert item
Cupcake, Donut, Eclair, Froyo, Gingerbread, Honeycomb, and Ice Cream
Android
Features
Application framework Dalvik virtual machine Integrated browser Optimized graphics SQLite
enables reuse and replacement of components optimized for mobile devices
based on the open source WebKit engine custom 2D graphics library; 3D graphics based on the OpenGL ES 1.0 specification structured data storage
Media support
common audio, video, and still image formats (MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, GIF)
Android
GSM Telephony Bluetooth, EDGE, 3G, and WiFi Bluetooth, Camera, GPS, compass, and Camera, accelerometer Rich development environment
hardware dependent device emulator, tools for debugging, memory and performance profiling, plugin for the Eclipse IDE hardware dependent hardware dependent
Android
Android
Application Fundamentals
Java Android package (.apk) Sandboxed Manifest, resources, components (Activities, Services, Content providers, Broadcast receivers)
Android
Activities
represents a single screen with a user interface when new activity starts, it is pushed onto the back stack UI can be built with XML or Java Lifecycle callback methods
onCreate(), onStart(), onResume(), onPause(), onStop(), and onDestroy()
Android
Services
perform long running operations in the background no UI runs independently of the component that created it can be bound to by other application components
Android
Content Providers
store and retrieve data and make it accessible to all applications only way to share data across applications data is exposed as a simple table exposes a public URI that uniquely identifies its dataset
Android
Broadcast Receivers
responds to system-wide broadcast announcements
Ex: low battery charge
applications can initiate their own broadcasts no UI but can create bar notifications