android fundamental
DESCRIPTION
Android fundamental, slide presentasi dalam acara bedah buku "24JAM!! Pintar Pemrograman Android" di STMIK AKAKOM YogyakartaTRANSCRIPT
mBEDAH Buku24JAM!! Pintar Pemrograman Android
AKAKOM #Jogja | 21/3/13
@omayib
Facebook.com/omayib
2971F7CB
Arif Akbarul HudaPenulis | Freelance Programmer | Trainer
Promo …
Promo …
www.omayib.com www.indocode.net
Promo …
www.omayib.com
www.omayib.com
Promo …
www.indocode.net
*Lets begin
Version & Target Device…
Version & Target Device…
Komponen Android
Activity Views Intent
Broadcastreceiv
erService Content
provider
Komponen android…
activity
Acvitivy
“User interface yang bisa digunakan untuk berinteraksi antara user dengan aplikasi”
Komponen android…
views
views
basic building block for user interface components
a rectangular area on the screen and is responsible for drawing and event handling
Example Button, EditText, Listview,CalendarView,Checkbox,ImageView,TextView etc
Komponen android…
intent
intent
• a facility for late run-time binding between components in the same or different applications
• Example 1 : from Login page to dashboard page
• Example 2: from whatsapp -> activating camera
Komponen android…
BroadcastReceiver
BroadcastReceiver
• a component that responds to system-wide broadcast announcements
• Example 1 : Batteray low• Example 2 : screen has turned off• Example 3 : picture was captured
Komponen android…
Service
Service
• a component that runs in the background to perform long-running operations or to perform work for remote processes
• No need User Interface• Example 1 : music player• Example 2 : Tweeter App when
fetching new tweet• Example 3 : perform file I/O
Komponen android…
Content Provider
Content Provider
• A content provider manages a shared set of application data
• No need User Interface• Example 1 : manage User Contact• Example 2 : manage SQLite
database
Komponen android…
DDMS android…
DDMS android…
Lifecycleapp (DEMO)
Lifecycle App android…
Multiple screen
Supporting different device
Multiple Screen
layout
DRAG & DROP !
Tips bikin layout
Komponen Properti value
RelativeLayout
Layout_width Match_parent
Layout_height Match_parent
backgorund #ff0000
Textview id textView2
Layout_width Wrap_content
Layout_height Wrap_content
text username
EditText id inUser
Layout_width Wrap_content
Layout_height Wrap_content
...
layout
Klik Kanan > Properties
Tips clientserver
layout
Client Server
Asyntaks
AsyncTask enables proper and easy use of the UI thread. This class allows to perform background operations and publish results on the UI thread without having to manipulate threads and/or handlers.
no Asyntaks vs asyntaks
process process
time time
p1p1
p2
Push Notification