android development orientation for starters v4 seminar

20
Android Development for Starters

Upload: joemarie-amparo

Post on 12-Jun-2015

879 views

Category:

Education


1 download

DESCRIPTION

This slide was created for Bohol Island State University - Calape Campus Android Development Seminar on December 08, 2012

TRANSCRIPT

Page 1: Android development orientation for starters v4   seminar

Android Development for Starters

Page 2: Android development orientation for starters v4   seminar

Define Android

Enumerate Android Versions

Identify tools in Android Development

State components in Eclipse

Run Android Application in Emulator

Objectives

Page 3: Android development orientation for starters v4   seminar

Android Devices

Page 4: Android development orientation for starters v4   seminar

o Open mobile platform by Google

o Defined as Software Stack for mobiles

o Start of Open Handset Alliance

o Maintained by Android Open Source Project

o Brought from Danger Inc. by Google

What is Android?

Page 5: Android development orientation for starters v4   seminar

Android Versions

Page 6: Android development orientation for starters v4   seminar

Android Version Market Share

Page 7: Android development orientation for starters v4   seminar

What will you need?

Page 8: Android development orientation for starters v4   seminar

Please refer to:

http://developershaven.blogspot.com

Installation

Page 9: Android development orientation for starters v4   seminar

Android Development Tool

Page 10: Android development orientation for starters v4   seminar

Application Components

Activity - java class that extends Activity

Services - runs in background for period of time

Broadcast Receivers - receives and react to broadcast announcement

Content Providers - store and retrieve data for all applications

Intents - the intention of an action

Page 11: Android development orientation for starters v4   seminar

Activities

Page 12: Android development orientation for starters v4   seminar

Services

• Run in the background

• Can be bound to an application

• Needs to be declared in manifest file

• Like Activities, has a structured life cycle

Page 13: Android development orientation for starters v4   seminar

Project Components

Page 14: Android development orientation for starters v4   seminar

XML

• Used to define some of the resourceso Layouts (UI)o Strings

• Manifest file

• Shouldn’t usually have to edit it directly, Eclipse can do that for you

• Preferred way of creating UIso Separates the description of the layout from any

actual code that controls ito Can easily take a UI from one platform to another

Page 15: Android development orientation for starters v4   seminar

R Class

• Auto-generated: you shouldn’t edit it

• Contains IDs of the project resources

• Enforces good software engineering

• Use findViewById object to access the resourceso Ex. Button b = (Button)findViewById(R.id.button1)

Page 16: Android development orientation for starters v4   seminar

Layouts

• Eclipse has a great UI creatoro Generates the XML for you

• Composed of View objects

• Can be specified for portrait and landscape modeo Use same file name, so can make completely different

UIs for the orientations without modifying any code

Page 17: Android development orientation for starters v4   seminar

Running in Eclipse

• Similar to launching a regular Java app, use the launch configurations

• Specify an Android Application and create a new one

• Specify activity to be run

• Can select a manual option, so each time program is run, you are asked whether you want to use the actual phone or the emulatoro Otherwise, it should be smart and use whichever one

is available

Page 18: Android development orientation for starters v4   seminar

QUESTIONS???

Page 19: Android development orientation for starters v4   seminar

• Installation: http://developershaven.blogspot.com

• Google API: http://mfarhan133.wordpress.com/2010/10/01/generate-google-maps-api-key-for-android/

• Android Developer’s Website : http://developer.android.com/index.html

• Numerous Forums & other developer sites, including:o http://www.javacodegeeks.com/2011/02/android-google-maps-tutorial.htmlo http://efreedom.com/Question/1-6070968/Google-Maps-Api-Directionso http://stackoverflow.com o http://www.anddev.org/google_driving_directions_-_mapview_overlayed-t826.html

Resources & Acknowledgements

Page 20: Android development orientation for starters v4   seminar

Joemarie Comeros Amparo

Android Developer

Nano Equipment Pte. Ltd. – Singapore

www.about.me/joemarieamparo

THANK YOU VERY MUCH!