Introduction to Android
Contents
What is Android? Setting up for Android Development Anatomy of an Android App Hello World on Android Where to go from here
What is Android? 1 of 2
History
Google acquires Android, Inc July 2005 Google forms Open Handset Alliance - Nov 2007 Release 1.0 of SDK Sept. 2008 Google releases Android source code Oct 2008 T-Mobile G-1 phone released in US Oct 2008
http:// [Link]/wiki/Google_Android
What is Android? 2 of 2
Concepts / Philosophy
Complete software stack based on Linux kernel 2.6.24 Feature-rich Application Framework Dalvik virtual machine optimized for Android / mobile device architecture Full, well-documented development environment
[Link]
Android Development Prerequisites
Java JDK 5 or 6 (JRE is not sufficient!) Eclipse 3.3 or higher (note: no current Netbeans support) Android SDK (latest official release is R1.1)
Android Development Setup (Eclipse)
Setup software update site Download and install current plugin Add SDK path to Preferences -> Android
[Link]
Android Development Key Concepts 1 of 2
Activity
User interface 'container' essentially a screen A simple or compound component which is used by an activity e.g. lists, buttons, grids, text boxes (like a 'control' in Symbian) Objects which can be used to launch activities and to pass data to sub-activities
View
Intent
Android Development Key Concepts 2 of 2
Service
Content Provider
Non-UI component which provides ancillary functionality Can be same or different process Mechanism to share data across different applications (app data is private) Bind data to UI views
Adapters
SQLlite database
Android Development App Structure
Application Manifest
Specifies Activities, Intents and Permissions defined as part of the app drawable: contains graphics resources layout: contains UI layout information values: contains data content, e.g. string values Used to store files accessed in raw form
Resources
Assets
Android Application Architecture
Each application runs as a separate (Linux) process Application Life Cycle
Apps implement callback methods in response to system events (e.g. when processes get stopped / paused / restarted by Application Manager for resource management purposes) Allows applications to persist / restore their state
Android Development Deployment
Application package files (.APK)
created via Android Asset Packaging Tool (AAPT) Eclipse invokes AAPT automatically
Android Development Tools
Android Emulator Android Debug Bridge (ADB)
Used for installing and debugging Android apps Used to create installables
Android Asset Packaging Tool (AAPT)
http://
Android Development Tutorials and Sample Code
Hello World [Link] Notepad Tutorial http:// [Link]/guide/tutorials/notepad/in API Demos is your friend!!!
Android Development Useful links
[Link] [Link]
Android Advanced Topics
Android is Open Source!
Git repository available
Extending Android
Java Native Interface (JNI) is available
Android News
Android SDK 1.5 pre-release now available