SlideShare a Scribd company logo
Daniel Switkin
Senior Software Engineer, Google Inc.
Android Application Development
Goal
• Get you an idea of how to start developing
Android applications
• Introduce major Android application concepts
• Walk you through a sample application in the
development environment
Agenda
• System architecture
• Hello World!
• Application components
• Practical matters
• Toolchain
What is Android?
• A free, open source mobile platform
• A Linux-based, multiprocess, multithreaded OS
• Android is not a device or a product
• It’s not even limited to phones - you could build
a DVR, a handheld GPS, an MP3 player, etc.
Android Runtime
DalvikVirtual
Machine
Core Libraries
Application Framework
View
System
Content
Providers
Resource
Manager GTalk ServiceLocation
Manager
Activity Manager
Package Manager
Window
Manager
Telephony
Manager
Notification
Manager
Linux Kernel
Display
Driver Camera Driver Bluetooth
Driver
Flash Memory
Driver
Binder (IPC)
Driver
Power
ManagementUSB Driver Keypad Driver WiFi Driver Audio
Drivers
Libraries
FreeType
SGL SSL
SQLite
WebKit
libc
Surface Manager
OpenGL | ES
Media
Framework
Applications
Home PhoneContacts Browser ...
Hello World!
The History of GUIs
• Hardcoded to the screen
• Hardcoded to the window
• Hardcoded within a view hierarchy
• Dynamic layout within a view hierarchy
Generating GUIs
• Two ways to create GUIs: in XML or in code
• Declarative route via XML has advantages
• A lot of your GUI-related work will take place in:
•res/layout
•res/values
•@id/name_for_component gives you
handle for referencing XML declarations in code
Views
• Views are building blocks
• Examples:
• Can be as basic as:TextView, EditText, or
ListView
• Fancier views: ImageView, MapView,WebView
Layouts
• Controls howViews are laid out
• FrameLayout : each child a layer
• LinearLayout : single row or column
• RelativeLayout : relative to otherViews
• TableLayout : rows and columns
• AbsoluteLayout : <x,y> coordinates
Layouts are resizable
480x320
240x320
320x240
Layouts are customizable
res/layout/share.xml res/layout-land/share.xml
Layout Parameters
• Specify many aspects of what’s being rendered
• Examples:
• android:layout_height
• android:layout_width
• Tip: start with documentation for a specificView
or Layout and then look at what’s inherited from
parent class
Application Components
Basic components
Activities
UI component typically
corresponding to one screen.
BroadcastReceivers Respond to broadcast Intents.
Services
Faceless tasks that run in the
background.
ContentProviders Enable applications to share data.
Activities
• Typically correspond to one screen in a UI
• But, they can:
• be faceless
• be in a floating window
• return a value
Intents
• Think of Intents as a verb and object; a
description of what you want done
• Examples: VIEW, CALL, PLAY, etc.
• System matches Intent with Activity that can best
provide that service
• Activities and BroadcastReceivers describe what
Intents they can service in their IntentFilters (via
AndroidManifest.xml)
Intents
GMail
Contacts
Chat
Home
Picasa
Blogger
“Pick photo”
Client component makes a
request for a specific action
System picks best
component for that action
Components can be
replaced any time
New components can use
existing functionality
Photo
Gallery
BroadcastReceivers
• Components designed to respond to broadcast
Intents
• Think of them as a way to respond to external
notifications or alarms
• Applications can invent and broadcast their own
Intents as well
Services
• Faceless components that run in the background
• Example: music player, network downlaod, etc.
• Bind your code to a running service via a
remote-able interface defined in an IDL
• Can run in your own process or separate
process
ContentProviders
• Enables sharing of data across applications
• Examples: address book, photo gallery, etc.
• Provides uniform APIs for:
• querying (returns a Cursor)
• delete, update, and insert rows
• Content is represented by URI and MIME type
Practical matters
Storage and Persistence
• A couple of different options:
• Preferences
• Flat file
• SQLite
• ContentProvider
Packaging
• Think of .apk files as Android packages
• Everything needed for an application is bundled
up therein
• Basically a glorified ZIP file
Resources
• res/layout: declarative layout files
• res/drawable: intended for drawing
• res/anim: bitmaps, animations for transitions
• res/values: externalized values for things like
strings, colors, styles, etc.
• res/xml: general XML files used at runtime
• res/raw: binary files (e.g. sound)
Assets
• Similar to Resources
• Differences:
• Read-only
• InputStream access to assets
• Any kind of file
• Be mindful of file sizes
Application Lifecycle
• Application lifecycle is managed by the system
• Application start/stop is transparent to the user
• End-user only sees that they are moving between
screens
• Read documentation for android.app.Activity
Toolchain
Emulator
• QEMU-based ARM emulator
runs same system image as
a device
• Use same toolchain to work
with devices or emulator
Eclipse Plugin
Project template
Debugging
Call stack
Breakpoints, single stepping
Examine variables
Eclipse demo
Q & A

More Related Content

What's hot

Context oriented architecture - Put the boundary in the right place
Context oriented architecture - Put the boundary in the right placeContext oriented architecture - Put the boundary in the right place
Context oriented architecture - Put the boundary in the right place
Leonardo Proietti
 
Demo Neo4j - Big Data Paris
Demo Neo4j - Big Data ParisDemo Neo4j - Big Data Paris
Demo Neo4j - Big Data Paris
Neo4j
 
Introduction to Android
Introduction to AndroidIntroduction to Android
Introduction to Android
HopeDeveloper
 
Building Maps with Leaflet
Building Maps with LeafletBuilding Maps with Leaflet
Building Maps with Leaflet
Jereme Causing
 
Domain Driven Design Ruby Ways - JURNAL 05/10/2017
Domain Driven Design Ruby Ways -  JURNAL 05/10/2017Domain Driven Design Ruby Ways -  JURNAL 05/10/2017
Domain Driven Design Ruby Ways - JURNAL 05/10/2017
Jonathan Wylliem
 
Introduction to C#
Introduction to C#Introduction to C#
Introduction to C#
SharePointKE
 
SiriusCon17 - Eclipse Sirius at a glance
SiriusCon17 - Eclipse Sirius at a glanceSiriusCon17 - Eclipse Sirius at a glance
SiriusCon17 - Eclipse Sirius at a glance
Obeo
 
Web Development Technologies
Web Development TechnologiesWeb Development Technologies
Web Development Technologies
Vignesh Prajapati
 
Reversengineering
ReversengineeringReversengineering
Reversengineering
Prakruthi Sudanandappa
 
Why do I Love C#?
Why do I Love C#?Why do I Love C#?
Why do I Love C#?
Abhishek Sur
 
Digital Library Cloud Services
Digital Library Cloud ServicesDigital Library Cloud Services
Digital Library Cloud Services
IIIF_io
 
Android
Android Android
Android
Edureka!
 
Android development course in pune ppt.
Android development course in pune ppt.Android development course in pune ppt.
Android development course in pune ppt.
sambhajimeher
 
Startup Bootcamp - Intro to NoSQL/Big Data by DataZone
Startup Bootcamp - Intro to NoSQL/Big Data by DataZoneStartup Bootcamp - Intro to NoSQL/Big Data by DataZone
Startup Bootcamp - Intro to NoSQL/Big Data by DataZone
Idan Tohami
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
Joni
 

What's hot (15)

Context oriented architecture - Put the boundary in the right place
Context oriented architecture - Put the boundary in the right placeContext oriented architecture - Put the boundary in the right place
Context oriented architecture - Put the boundary in the right place
 
Demo Neo4j - Big Data Paris
Demo Neo4j - Big Data ParisDemo Neo4j - Big Data Paris
Demo Neo4j - Big Data Paris
 
Introduction to Android
Introduction to AndroidIntroduction to Android
Introduction to Android
 
Building Maps with Leaflet
Building Maps with LeafletBuilding Maps with Leaflet
Building Maps with Leaflet
 
Domain Driven Design Ruby Ways - JURNAL 05/10/2017
Domain Driven Design Ruby Ways -  JURNAL 05/10/2017Domain Driven Design Ruby Ways -  JURNAL 05/10/2017
Domain Driven Design Ruby Ways - JURNAL 05/10/2017
 
Introduction to C#
Introduction to C#Introduction to C#
Introduction to C#
 
SiriusCon17 - Eclipse Sirius at a glance
SiriusCon17 - Eclipse Sirius at a glanceSiriusCon17 - Eclipse Sirius at a glance
SiriusCon17 - Eclipse Sirius at a glance
 
Web Development Technologies
Web Development TechnologiesWeb Development Technologies
Web Development Technologies
 
Reversengineering
ReversengineeringReversengineering
Reversengineering
 
Why do I Love C#?
Why do I Love C#?Why do I Love C#?
Why do I Love C#?
 
Digital Library Cloud Services
Digital Library Cloud ServicesDigital Library Cloud Services
Digital Library Cloud Services
 
Android
Android Android
Android
 
Android development course in pune ppt.
Android development course in pune ppt.Android development course in pune ppt.
Android development course in pune ppt.
 
Startup Bootcamp - Intro to NoSQL/Big Data by DataZone
Startup Bootcamp - Intro to NoSQL/Big Data by DataZoneStartup Bootcamp - Intro to NoSQL/Big Data by DataZone
Startup Bootcamp - Intro to NoSQL/Big Data by DataZone
 
Introduction to ASP.NET
Introduction to ASP.NETIntroduction to ASP.NET
Introduction to ASP.NET
 

Viewers also liked

Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trialDigital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
Ali Mian
 
Open source mobile development solutions
Open source mobile development solutionsOpen source mobile development solutions
Open source mobile development solutions
Daniel Downs
 
Mobile app development sylhet it academy
Mobile app development  sylhet it academyMobile app development  sylhet it academy
Mobile app development sylhet it academy
Sylhet IT Academy
 
1 Intro
1 Intro1 Intro
ALI SHAN CV Software-Engineer-Resume
ALI SHAN CV Software-Engineer-ResumeALI SHAN CV Software-Engineer-Resume
ALI SHAN CV Software-Engineer-Resume
ALI SHAN
 
eCertificate
eCertificateeCertificate
eCertificate
Pragati Singh
 
Android course (lecture2)
Android course (lecture2)Android course (lecture2)
Android course (lecture2)
Amira Elsayed Ismail
 
Naveen ResuMeS - Copy (1)
Naveen ResuMeS - Copy (1)Naveen ResuMeS - Copy (1)
Naveen ResuMeS - Copy (1)
Naveen Srivastava
 
Day1 before getting_started
Day1 before getting_startedDay1 before getting_started
Day1 before getting_started
Ahsanul Karim
 
Android course (lecture1)
Android course (lecture1)Android course (lecture1)
Android course (lecture1)
Amira Elsayed Ismail
 
CV EXAMPLE
CV EXAMPLE CV EXAMPLE
Developing a mobile application curriculum which empowers authentic
Developing a mobile application curriculum which empowers authenticDeveloping a mobile application curriculum which empowers authentic
Developing a mobile application curriculum which empowers authentic
Daniel Downs
 
CV IT Support-Software Engineer
CV IT Support-Software EngineerCV IT Support-Software Engineer
CV IT Support-Software Engineer
Mohd Ahmed
 
Android Basic- CMC
Android Basic- CMCAndroid Basic- CMC
Android Basic- CMC
Pragati Singh
 
Android MapView and MapActivity
Android MapView and MapActivityAndroid MapView and MapActivity
Android MapView and MapActivity
Ahsanul Karim
 
Artificail Intelligent lec-1
Artificail Intelligent lec-1Artificail Intelligent lec-1
Artificail Intelligent lec-1
tjunicornfx
 
Example Single Page CV
Example Single Page CVExample Single Page CV
Lecture 5: Storage: Saving Data Database, Files & Preferences
Lecture 5: Storage: Saving Data Database, Files & PreferencesLecture 5: Storage: Saving Data Database, Files & Preferences
Lecture 5: Storage: Saving Data Database, Files & Preferences
Ahsanul Karim
 
Client-Server
Client-ServerClient-Server
Client-Server
Ahsanul Karim
 
Mahmoud Elmasry CV - Senior Software Quality Assurance Engineer
Mahmoud Elmasry CV - Senior Software Quality Assurance EngineerMahmoud Elmasry CV - Senior Software Quality Assurance Engineer
Mahmoud Elmasry CV - Senior Software Quality Assurance Engineer
Mahmoud Elmasry
 

Viewers also liked (20)

Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trialDigital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
Digital brain co_13_print_crystalgraphics.com_powerpoint_templates_trial
 
Open source mobile development solutions
Open source mobile development solutionsOpen source mobile development solutions
Open source mobile development solutions
 
Mobile app development sylhet it academy
Mobile app development  sylhet it academyMobile app development  sylhet it academy
Mobile app development sylhet it academy
 
1 Intro
1 Intro1 Intro
1 Intro
 
ALI SHAN CV Software-Engineer-Resume
ALI SHAN CV Software-Engineer-ResumeALI SHAN CV Software-Engineer-Resume
ALI SHAN CV Software-Engineer-Resume
 
eCertificate
eCertificateeCertificate
eCertificate
 
Android course (lecture2)
Android course (lecture2)Android course (lecture2)
Android course (lecture2)
 
Naveen ResuMeS - Copy (1)
Naveen ResuMeS - Copy (1)Naveen ResuMeS - Copy (1)
Naveen ResuMeS - Copy (1)
 
Day1 before getting_started
Day1 before getting_startedDay1 before getting_started
Day1 before getting_started
 
Android course (lecture1)
Android course (lecture1)Android course (lecture1)
Android course (lecture1)
 
CV EXAMPLE
CV EXAMPLE CV EXAMPLE
CV EXAMPLE
 
Developing a mobile application curriculum which empowers authentic
Developing a mobile application curriculum which empowers authenticDeveloping a mobile application curriculum which empowers authentic
Developing a mobile application curriculum which empowers authentic
 
CV IT Support-Software Engineer
CV IT Support-Software EngineerCV IT Support-Software Engineer
CV IT Support-Software Engineer
 
Android Basic- CMC
Android Basic- CMCAndroid Basic- CMC
Android Basic- CMC
 
Android MapView and MapActivity
Android MapView and MapActivityAndroid MapView and MapActivity
Android MapView and MapActivity
 
Artificail Intelligent lec-1
Artificail Intelligent lec-1Artificail Intelligent lec-1
Artificail Intelligent lec-1
 
Example Single Page CV
Example Single Page CVExample Single Page CV
Example Single Page CV
 
Lecture 5: Storage: Saving Data Database, Files & Preferences
Lecture 5: Storage: Saving Data Database, Files & PreferencesLecture 5: Storage: Saving Data Database, Files & Preferences
Lecture 5: Storage: Saving Data Database, Files & Preferences
 
Client-Server
Client-ServerClient-Server
Client-Server
 
Mahmoud Elmasry CV - Senior Software Quality Assurance Engineer
Mahmoud Elmasry CV - Senior Software Quality Assurance EngineerMahmoud Elmasry CV - Senior Software Quality Assurance Engineer
Mahmoud Elmasry CV - Senior Software Quality Assurance Engineer
 

Similar to Lecture3

Android application development
Android application developmentAndroid application development
Android application development
Linh Vi Tường
 
Androidify workshop
Androidify workshopAndroidify workshop
Androidify workshop
Alexey Buzdin
 
Android Workshop_1
Android Workshop_1Android Workshop_1
Android Workshop_1
Purvik Rana
 
Introduction to Android (before 2015)
Introduction to Android (before 2015)Introduction to Android (before 2015)
Introduction to Android (before 2015)
Chien-Ming Chou
 
Consistent UI Across Android Devices
Consistent UI Across Android DevicesConsistent UI Across Android Devices
Consistent UI Across Android Devices
Irene Duke
 
Android quick talk
Android quick talkAndroid quick talk
Android quick talk
SenthilKumar Selvaraj
 
Android Introduction
Android IntroductionAndroid Introduction
Android Introduction
Sharmistha Mandal
 
Introduction to Android
Introduction to AndroidIntroduction to Android
Introduction to Android
NitinMehra2205
 
Introduction to android
Introduction to androidIntroduction to android
Introduction to android
Jawad Mohmand
 
Android OS and its Features
Android OS and its FeaturesAndroid OS and its Features
Android OS and its Features
Harshad Lokhande
 
My androidpresentation
My androidpresentationMy androidpresentation
My androidpresentation
niteshnarayanlal
 
Synapseindia android apps application development
Synapseindia android apps application developmentSynapseindia android apps application development
Synapseindia android apps application development
Synapseindiappsdevelopment
 
Angular mobile angular_u
Angular mobile angular_uAngular mobile angular_u
Angular mobile angular_u
Doris Chen
 
Introduction to Android Development.pptx
Introduction to Android Development.pptxIntroduction to Android Development.pptx
Introduction to Android Development.pptx
asmeerana605
 
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
DuckMa
 
Android Deep Dive
Android Deep DiveAndroid Deep Dive
Android Deep Dive
Marko Gargenta
 
Android Application Development GDSC DCE Darbhanga.pptx
Android Application Development GDSC DCE Darbhanga.pptxAndroid Application Development GDSC DCE Darbhanga.pptx
Android Application Development GDSC DCE Darbhanga.pptx
DCETechnicalClub
 
Android development orientation for starters v2
Android development orientation for starters v2Android development orientation for starters v2
Android development orientation for starters v2
Joemarie Amparo
 
Synapse india reviews on android application
Synapse india reviews on android applicationSynapse india reviews on android application
Synapse india reviews on android application
saritasingh19866
 
Android application development for TresmaxAsia
Android application development for TresmaxAsiaAndroid application development for TresmaxAsia
Android application development for TresmaxAsia
Michael Angelo Rivera
 

Similar to Lecture3 (20)

Android application development
Android application developmentAndroid application development
Android application development
 
Androidify workshop
Androidify workshopAndroidify workshop
Androidify workshop
 
Android Workshop_1
Android Workshop_1Android Workshop_1
Android Workshop_1
 
Introduction to Android (before 2015)
Introduction to Android (before 2015)Introduction to Android (before 2015)
Introduction to Android (before 2015)
 
Consistent UI Across Android Devices
Consistent UI Across Android DevicesConsistent UI Across Android Devices
Consistent UI Across Android Devices
 
Android quick talk
Android quick talkAndroid quick talk
Android quick talk
 
Android Introduction
Android IntroductionAndroid Introduction
Android Introduction
 
Introduction to Android
Introduction to AndroidIntroduction to Android
Introduction to Android
 
Introduction to android
Introduction to androidIntroduction to android
Introduction to android
 
Android OS and its Features
Android OS and its FeaturesAndroid OS and its Features
Android OS and its Features
 
My androidpresentation
My androidpresentationMy androidpresentation
My androidpresentation
 
Synapseindia android apps application development
Synapseindia android apps application developmentSynapseindia android apps application development
Synapseindia android apps application development
 
Angular mobile angular_u
Angular mobile angular_uAngular mobile angular_u
Angular mobile angular_u
 
Introduction to Android Development.pptx
Introduction to Android Development.pptxIntroduction to Android Development.pptx
Introduction to Android Development.pptx
 
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
Matteo Gazzurelli - Andorid introduction - Google Dev Fest 2013
 
Android Deep Dive
Android Deep DiveAndroid Deep Dive
Android Deep Dive
 
Android Application Development GDSC DCE Darbhanga.pptx
Android Application Development GDSC DCE Darbhanga.pptxAndroid Application Development GDSC DCE Darbhanga.pptx
Android Application Development GDSC DCE Darbhanga.pptx
 
Android development orientation for starters v2
Android development orientation for starters v2Android development orientation for starters v2
Android development orientation for starters v2
 
Synapse india reviews on android application
Synapse india reviews on android applicationSynapse india reviews on android application
Synapse india reviews on android application
 
Android application development for TresmaxAsia
Android application development for TresmaxAsiaAndroid application development for TresmaxAsia
Android application development for TresmaxAsia
 

Recently uploaded

Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
Rohit Gautam
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
ThomasParaiso2
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
Neo4j
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
Alpen-Adria-Universität
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
Neo4j
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Malak Abu Hammad
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
Adtran
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems S.M.S.A.
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
Neo4j
 

Recently uploaded (20)

Large Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial ApplicationsLarge Language Model (LLM) and it’s Geospatial Applications
Large Language Model (LLM) and it’s Geospatial Applications
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...GridMate - End to end testing is a critical piece to ensure quality and avoid...
GridMate - End to end testing is a critical piece to ensure quality and avoid...
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
 
Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
Video Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the FutureVideo Streaming: Then, Now, and in the Future
Video Streaming: Then, Now, and in the Future
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
GraphSummit Singapore | Neo4j Product Vision & Roadmap - Q2 2024
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdfUnlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
Unlock the Future of Search with MongoDB Atlas_ Vector Search Unleashed.pdf
 
Pushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 daysPushing the limits of ePRTC: 100ns holdover for 100 days
Pushing the limits of ePRTC: 100ns holdover for 100 days
 
Uni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdfUni Systems Copilot event_05062024_C.Vlachos.pdf
Uni Systems Copilot event_05062024_C.Vlachos.pdf
 
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
GraphSummit Singapore | Enhancing Changi Airport Group's Passenger Experience...
 

Lecture3

  • 1. Daniel Switkin Senior Software Engineer, Google Inc. Android Application Development
  • 2. Goal • Get you an idea of how to start developing Android applications • Introduce major Android application concepts • Walk you through a sample application in the development environment
  • 3. Agenda • System architecture • Hello World! • Application components • Practical matters • Toolchain
  • 4. What is Android? • A free, open source mobile platform • A Linux-based, multiprocess, multithreaded OS • Android is not a device or a product • It’s not even limited to phones - you could build a DVR, a handheld GPS, an MP3 player, etc.
  • 5. Android Runtime DalvikVirtual Machine Core Libraries Application Framework View System Content Providers Resource Manager GTalk ServiceLocation Manager Activity Manager Package Manager Window Manager Telephony Manager Notification Manager Linux Kernel Display Driver Camera Driver Bluetooth Driver Flash Memory Driver Binder (IPC) Driver Power ManagementUSB Driver Keypad Driver WiFi Driver Audio Drivers Libraries FreeType SGL SSL SQLite WebKit libc Surface Manager OpenGL | ES Media Framework Applications Home PhoneContacts Browser ...
  • 7. The History of GUIs • Hardcoded to the screen • Hardcoded to the window • Hardcoded within a view hierarchy • Dynamic layout within a view hierarchy
  • 8. Generating GUIs • Two ways to create GUIs: in XML or in code • Declarative route via XML has advantages • A lot of your GUI-related work will take place in: •res/layout •res/values •@id/name_for_component gives you handle for referencing XML declarations in code
  • 9. Views • Views are building blocks • Examples: • Can be as basic as:TextView, EditText, or ListView • Fancier views: ImageView, MapView,WebView
  • 10. Layouts • Controls howViews are laid out • FrameLayout : each child a layer • LinearLayout : single row or column • RelativeLayout : relative to otherViews • TableLayout : rows and columns • AbsoluteLayout : <x,y> coordinates
  • 13. Layout Parameters • Specify many aspects of what’s being rendered • Examples: • android:layout_height • android:layout_width • Tip: start with documentation for a specificView or Layout and then look at what’s inherited from parent class
  • 15. Basic components Activities UI component typically corresponding to one screen. BroadcastReceivers Respond to broadcast Intents. Services Faceless tasks that run in the background. ContentProviders Enable applications to share data.
  • 16. Activities • Typically correspond to one screen in a UI • But, they can: • be faceless • be in a floating window • return a value
  • 17. Intents • Think of Intents as a verb and object; a description of what you want done • Examples: VIEW, CALL, PLAY, etc. • System matches Intent with Activity that can best provide that service • Activities and BroadcastReceivers describe what Intents they can service in their IntentFilters (via AndroidManifest.xml)
  • 18. Intents GMail Contacts Chat Home Picasa Blogger “Pick photo” Client component makes a request for a specific action System picks best component for that action Components can be replaced any time New components can use existing functionality Photo Gallery
  • 19. BroadcastReceivers • Components designed to respond to broadcast Intents • Think of them as a way to respond to external notifications or alarms • Applications can invent and broadcast their own Intents as well
  • 20. Services • Faceless components that run in the background • Example: music player, network downlaod, etc. • Bind your code to a running service via a remote-able interface defined in an IDL • Can run in your own process or separate process
  • 21. ContentProviders • Enables sharing of data across applications • Examples: address book, photo gallery, etc. • Provides uniform APIs for: • querying (returns a Cursor) • delete, update, and insert rows • Content is represented by URI and MIME type
  • 23. Storage and Persistence • A couple of different options: • Preferences • Flat file • SQLite • ContentProvider
  • 24. Packaging • Think of .apk files as Android packages • Everything needed for an application is bundled up therein • Basically a glorified ZIP file
  • 25. Resources • res/layout: declarative layout files • res/drawable: intended for drawing • res/anim: bitmaps, animations for transitions • res/values: externalized values for things like strings, colors, styles, etc. • res/xml: general XML files used at runtime • res/raw: binary files (e.g. sound)
  • 26. Assets • Similar to Resources • Differences: • Read-only • InputStream access to assets • Any kind of file • Be mindful of file sizes
  • 27. Application Lifecycle • Application lifecycle is managed by the system • Application start/stop is transparent to the user • End-user only sees that they are moving between screens • Read documentation for android.app.Activity
  • 29. Emulator • QEMU-based ARM emulator runs same system image as a device • Use same toolchain to work with devices or emulator
  • 31. Debugging Call stack Breakpoints, single stepping Examine variables
  • 33. Q & A