17
CODE CRUNCH QUICKSTART TO ANDROID DEVELOPMENT By: Obed Ademang – GDG, UCC Lead

Code crunch

Embed Size (px)

Citation preview

Page 1: Code crunch

CODE CRUNCH QUICKSTART TO ANDROID DEVELOPMENT

By: Obed Ademang – GDG, UCC Lead

Page 2: Code crunch

04/12/2023Nene Padi Ademang (Obed) 2

NO ANDROID DEVICE

NO KNOWLEDGE

OF PROGRAMMI

NG

NOT A DEVELOPER

I LIKE APPS

Page 3: Code crunch

04/12/2023Nene Padi Ademang (Obed) 3

Overview of the Platform

Page 4: Code crunch

04/12/2023Nene Padi Ademang (Obed) 4

Android Platform

It is a software stack for mobile devices.

It contains:

OS Kernel, system libraries, application frameworks and key apps

Android Software Development Kit (SDK):

Libraries and development tools for creating android applications

There are lots of documentation on:

http://developer.android.com/training

Page 5: Code crunch

04/12/2023Nene Padi Ademang (Obed) 5

Applications

HOME CONTACT PHONE BROWSER …

Application Framework

PACKAGE MANAGER

TELEPHONY MANAGER

RESOURCE MANAGER

LOCATION MANAGER

NOTIFICATION MANAGER

ACTIVITY MANAGER

WINDOW MANAGER

CONTENT PROVIDERS

VIEW SYSTEM

Linux Kernel

KEYPAD DRIVER

AUDIO DRIVER

WiFi DRIVERPOWER

MANAGEMENT

DISPLAY DRIVER

CAMERA DRIVER

FLASH MEMORY

BINDER DRIVER

Libraries

OPEN GL/SG FREETYPE WEBKIT

SGL libc

SOFTWARE MANAGER

MEDIA FRAMEWORK

SQLITE

SSL

Android Runtime

CORE LIBRARIES

DALVIK VIRTUAL MACH.

Page 6: Code crunch

04/12/2023Nene Padi Ademang (Obed) 6

Development

Page 7: Code crunch

04/12/2023Nene Padi Ademang (Obed) 7

Android Development Environment

ADT Bundle

Latest Android platform

Eclipse + ADT Plugin

Latest system image for emulator

Additional development tools

Prerequisite

Windows 7 / Mac OS X (Intel x86) / Various Linux Distros

At least Java SE 6

Knowledge about Java Programming

Page 8: Code crunch

04/12/2023Nene Padi Ademang (Obed) 8

Demo

Page 9: Code crunch

04/12/2023Nene Padi Ademang (Obed) 9

Pros & Cons of the Emulator

Pros Cons

Page 10: Code crunch

04/12/2023Nene Padi Ademang (Obed) 10

Advance Features of Emulator

The emulator helps test some advance features like

Network speed/Latency

Battery power

Location coordinates

Emulated calls

Page 11: Code crunch

04/12/2023Nene Padi Ademang (Obed) 11

Demo

Page 12: Code crunch

04/12/2023Nene Padi Ademang (Obed) 12

Overview of Activity Life Cycle and Intents

Page 13: Code crunch

04/12/2023Nene Padi Ademang (Obed) 13

Activity

An application component that provides a screen with which users can interact in order to do something.

An application usually consists of multiple activities that are loosely bound to each other.

Each time a new activity starts, the previous activity is stopped, but the system preserves the activity in a stack (the "back stack").

startActivity()

startActivityForResult()

Page 14: Code crunch

04/12/2023Nene Padi Ademang (Obed) 14

Page 15: Code crunch

04/12/2023Nene Padi Ademang (Obed) 15

Intents

Explicit intent

Implicit Intent

Intent intent = new Intent(this, SignInActivity.class);startActivity(intent);

Intent intent = new Intent(Intent.ACTION_SEND);intent.putExtra(Intent.EXTRA_EMAIL, recipientArray);startActivity(intent);

Page 16: Code crunch

04/12/2023Nene Padi Ademang (Obed) 16

Demo

Page 17: Code crunch

04/12/2023Nene Padi Ademang (Obed) 17

THANK YOU