IT 72 – Current Trends in
IT
Android Application
Development
Prepared by:
JOHN D. TAJONES
IT 72 – Current Trends in IT
Android Application Development
Course Objective
This course aims to teach students basic Android programming and
will also discuss some advance concepts related to Android
application development.
After completing this course you will find yourself at a moderate level of
expertise in Android programming from where you can take yourself to
more advance Android development topics.
IT 72 – Current Trends in IT
Android Application Development
Grading System
Midterm/Final Term (Lecture)
Quiz - 30%
1HE/Project - 30%
Maj. Exam - 35%
Attendance - 5%
100%
IT 72 – Current Trends in IT
Android Application Development
Grading System
Term Grade = 1/2(Lecture) + 1/2(Lab)
FINAL GRADE = 1/3(MTG) + 2/3(FTG)
Reminder:
50% passing
IT 72 – Current Trends in IT
Android Application Development
Android: An Overview
Android is an open source and Linux-based operating system for
mobile devices.
It was developed by Google with a user interface based on direct
manipulation. It is designed primarily for touchscreen mobile
devices such as smartphones and tablet computers, with specialized
user interfaces for televisions (Android TV), cars (Android
Auto), and wrist watches (Android Wear).
Android applications can be packaged easily and can be sold out
either through a store such as Google Play or the Amazon
Appstore.
IT 72 – Current Trends in IT
Android Application Development
Market Share
IT 72 – Current Trends in IT
Android Application Development
Android - Architecture
IT 72 – Current Trends in IT
Android Application Development
Android - Architecture
1. Linux Kernel provides basic system functionality like process
management, memory management and device management.
2. Libraries – comprise of set of libraries such as libraries in
playing or recording audio or audio.
3. Android Runtime – provides Java Virtual Machine called
Dalvik Virtual Machine (DVM). It enables every android
application to run its own process.
4. Application Framework – provides higher level services to the
application in the form of Java classes.
5. Applications
IT 72 – Current Trends in IT
Android Application Development
Application Components
It is essential building blocks of and Android application.
Components are loosely coupled by the application manifest file
[Link] which describes each component of the
application and how they interact.
Four Application Components:
1. Activities – represents a single screen with a user interface.
2. Services – component that runs in the background to perform long
running-applications.
3. Broadcast Receivers - respond to broadcast messages from other
applications or from the system.
4. Content Providers - supplies data from one application to others on
request.
IT 72 – Current Trends in IT
Android Application Development
Application Components
Additional components:
COMPONENTS DESCRIPTION
Represents a behavior or a portion of user interface in an
Fragments
Activity.
UI elements that are drawn onscreen including buttons, lists
Views
forms etc.
View hierarchies that control screen format and appearance
Layouts
of the views.
Intents Messages wiring components together.
External elements, such as strings, constants and drawables
Resources
pictures.
Manifest Configuration file for the application
IT 72 – Current Trends in IT
Android Application Development
Android Version and API Level Comparison
OS Version Name Release Date API Level
Android 5.0 Lollipop Oct 17, 2014 20
Android 4.4 KitKat Oct 31, 2013 19
Android 4.3 Jelly Bean Jul 24, 2013 18
Android 4.2 Jelly Bean Nov 13, 2012 17
Android 4.1 Jelly Bean Jul 9, 2012 16
Android 4.0.2, 4.0.3 Ice Cream Sandwich - 15
Android 4.0 Ice Cream Sandwich - 14
Android 3.2 Honeycomb Jul 15, 2011 13
Android 3.1 Honeycomb May 10, 2011 12
Android 3.0 Honeycomb Feb 22, 2011 11
Android 2.3.3 – 2.3.7 Gingerbread Feb 9, 2011 10
Android 2.3 Gingerbread December 6, 2010 9
Android 2.2 Froyo May 20, 2010 8
IT 72 – Current Trends in IT
Android Application Development
Android Version and API Level Comparison
OS Version Name Release Date API Level
Android 2.1 Éclair Jan 12, 2010 7
Android 2.0.1 Éclair Dec 3, 2009 6
Android 2.0 Éclair Oct 26, 2009 5
Android 1.6 Donut Sep 15, 2009 4
Android 1.5 Cupcake Apr 30 2009 3
Android 1.1 Banana bread Feb 9, 2009 2
Android 1.0 Apple pie Sep 23, 2008 1
IT 72 – Current Trends in IT
Android Application Development
What you should know?
Prerequisites in Android Application Development
Object-oriented programming concepts
Experience with Java
XML fundamentals
Familiar with Android functionalities
IT 72 – Current Trends in IT
Android Application Development
What you should know?
Prerequisites in Android Application Development
Object-oriented programming concepts
Experience with Java
XML fundamentals
Familiar with Android functionalities
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Development Tools
Java JDK
ADT (Android Development Tools) Bundles for Windows or Android
Studio
Update Android SDK packages
Android Virtual Device (AVD) – Simulator
Configuring Actual Device for Testing
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Java SE Developer Kit (JDK)
Download and install latest Java Standard Edition Developer Kit at http://
[Link]/technetwork/java/javase/downloads/[Link]
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
ADT Bundles for Windows or Android Studio (BETA)
Download at [Link]
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
ADT Bundles for Windows or Android Studio (BETA)
Download at [Link]
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Install and update Android SDK Packages
Installation of packages can be made through SDK manager.
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Install and update Android SDK Packages
Be sure to install the necessary packages:
1. Android SDK Tools (recent version)
2. Android SDK Platform-tools
3. Android SDK Build-tools
4. SDK Platform (for specific SDK version)
Optional packages
1. Samples for SDK
2. ARM EABi System Image
3. Intel x86 Atom System Image (requires HAXM installer)
4. Google APIs
5. Sources for Android SDK
6. Google USB Driver (Extras)
7. Intel x86 Emulator Accelerator (HAXM installer)
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Creating Android Virtual Devices (AVD)
ARM-based AVD
Required ARM EAB1 v7a SDK package
Enable snapshot will save the current state of the emulator.
Intel-based AVD
Required Intel x86 Atom System Image and Intel x86 Emulator (HAXM)
Install HAXM via /%sdkbundleroot%/sdk/extras/intel/HAXM/ directory.
IT 72 – Current Trends in IT
Android Application Development
Development Environment Setup
Configuring Actual Device for Testing
Download Google USB Driver using SDK Manager
If actual device is not supported with Google USB Driver, download
the OEM Drivers for that specific mobile device.
You can use Device Manager in updating or installing le device
driver.
Set the device in debugging mode by clicking Settings ->
Applications -> Development -> then check USB debugging and
Stay Awake
To add a device console on Eclipse click Window -> Show View ->
Other…. Then under the Android folder, choose Devices then click
Ok.
Device console will appear showing the status of your device.
IT 72 – Current Trends in IT
Android Application Development
Hello World Example
IT 72 – Current Trends in IT
Android Application Development
Anatomy of Android Application
IT 72 – Current Trends in IT
Android Application Development
Anatomy of Android Application
IT 72 – Current Trends in IT
Android Application Development
Layout Fundamentals
Android application must support multiple screen sizes and
resolution.
Types of Layout Container
LinearLayout (default)