SlideShare ist ein Scribd-Unternehmen logo
1 von 22
Android 1
Android Training
By Khaled Anaqwa
WHAT MAKES AN ANDROID
APPLICATION?
 Activities
 Service
 Content

Providers

 Intents
 Broadcast

Receivers

 Widgets
 Notifications
Activities






An activity represent a single screen with a
user interface
Most applications contain multiple activities
When a new activity starts, it is pushed onto
back stack
User interface can built with xml or java(xml is
recommended)
Monitor lifespan through callback methods
like onStart() , onPause() ,etc
Service







Services perform long-running operations in
the background
Dose not contain a user interface
Useful for things like network operations,
playing music , etc.
Run independently of the component that
created it.
Can be bound to by other application
components, if allowed (when all of them
unbind, the service is destroyed)
Content Providers








Used to store and retrieve data and make it
accessible to all applications(the only way to
share data across apps)
They encapsulate the data, and provide
mechanisms for defining data security
connects data in one process with code running
in another process.
Exposes a public URI that uniquely identifies data
set
Data is exposed as a simple table on DB model
Android contains many providers for things like
contacts, media ,etc
Broadcast Receivers
 Is

a component that responds to systemwide broadcast announcements
 Example :announcing that the screen has
turned off , the battery is low, etc.
 App can also initiate their own broadcasts
 Contain no user interface
 They can create status bar notifications
APPLICATION’S PRIORITY AND
ITS PROCESS’ STATES
 All

Android applications continue running
and in memory until the system needs
resources for other applications.
1. Active processes
 Active

(foreground) processes have
application components the user is
interacting with.






Activities in an active state
Broadcast Receivers executing onReceive
Services executing onStart, onCreate
Running Services that have been flagged
to run in the foreground
2. Visible processes
 Visible

but inactive
processes are those
hosting “visible”
Activities. This happens
when an Activity is only
partially obscured (by
a non-full-screen or
transparent Activity).
3. Started Service processes
 Processes

hosting Services that have been
started. Because these Services don’t
interact directly with the user, they
receive a slightly lower priority than visible
Activities or foreground Services.
4. Background processes
 Processes

hosting Activities that aren’t
visible and that don’t have any running
Services. There will generally be a large
number of background processes that
Android will kill using a last-seen-first-killed
pattern in order to obtain resources for
foreground processes.
5. Empty processes
 To

improve overall system performance,
Android will often retain an application in
memory after it has reached the end of its
lifetime. Android maintains this cache to
improve the start-up time of applications
when they’re relaunched.
These processes are routinely killed, as
required.
Manifest XML








It names the Java package for the application(unique
identifier for the app.)
It describes the components of the application
It determines which processes will host application
components.
It declares which permissions the application must have
permissions that others are required to have in order to
interact with the application's components.
It declares the minimum level of the Android API that
the application requires.
It lists the libraries that the application must be linked
against.
How Android features are
reflected in the manifest file?
 Intent

Filters
 Icons and Labels
 Permissions
 Libraries
Intent Filters
 The

core components of an application
(its activities, services, and broadcast
receivers) are activated by intents.
 An intent is a bundle of information (an
Intent object) describing a desired action
including the data to be acted upon, the
category of component that should
perform the action, and other pertinent
instructions.
By Actions
By Category
Permission




A permission is a restriction limiting access to a
part of the code or to data on the device.
The limitation is imposed to protect critical
data and code that could be misused to
distort or damage the user experience.
here are some permissions defined by
Android:





android.permission.CALL_EMERGENCY_NUMBERS
android.permission.READ_OWNER_DATA
android.permission.SET_WALLPAPER
android.permission.DEVICE_POWER
Type of Permissions
 <uses-permission>
 <permission>
 <permission-tree>(element

declares a
namespace for a group of permissions)
 <permission-group>(defines a label for a
set of permissions)
 (tree-group)It affects only how the
permissions are grouped when presented
to the user.
Libraries
 <uses-library

android:name="string"
android:required=["true" | "false"] />
 Specifies a shared library that the
application must be linked against. This
element tells the system to include the
library's code in the class loader for the
package.
 Google Play uses the <uses-library>
elements declared in your app manifest
to filter your app from devices that do not
meet it's library requirements.
 All

of the android packages such as

 android.app

(application components)
 android.content(Content sharing,
Resource,Package management)
 android.view (basic user interface classes that
handle screen layout and interaction with the
user.)
 android.widget (mostly visual UI elements)

are in the default library that all applications
are automatically linked against.
 some packages (such as maps) are in
separate libraries that are not
automatically linked.

Weitere ähnliche Inhalte

Andere mochten auch

Chapter 5 ms access-1
Chapter 5   ms access-1Chapter 5   ms access-1
Chapter 5 ms access-1Pratik Gupta
 
Android Transition
Android TransitionAndroid Transition
Android TransitionCharile Tsai
 
Android Training (Animation)
Android Training (Animation)Android Training (Animation)
Android Training (Animation)Khaled Anaqwa
 
Content provider in_android
Content provider in_androidContent provider in_android
Content provider in_androidPRITI TELMORE
 
Android Training (Content Provider)
Android Training (Content Provider)Android Training (Content Provider)
Android Training (Content Provider)Khaled Anaqwa
 
Android Training (Storing & Shared Preferences)
Android Training (Storing & Shared Preferences)Android Training (Storing & Shared Preferences)
Android Training (Storing & Shared Preferences)Khaled Anaqwa
 
Wifi direct p2p app
Wifi direct p2p appWifi direct p2p app
Wifi direct p2p appgeniushkg
 
Chapter 3 storage media and devices
Chapter 3   storage media and devicesChapter 3   storage media and devices
Chapter 3 storage media and devicesPratik Gupta
 
Chapter 8 system analysis and design
Chapter 8   system analysis and designChapter 8   system analysis and design
Chapter 8 system analysis and designPratik Gupta
 
Introduction to Wi-Fi Direct
Introduction to Wi-Fi DirectIntroduction to Wi-Fi Direct
Introduction to Wi-Fi DirectWei-Tsung Su
 
Smartphone sensor and gesture
Smartphone sensor and gestureSmartphone sensor and gesture
Smartphone sensor and gestureBhavya5800
 
C hapter 1 types-and_components_of_computer_system[1][1]
C hapter 1   types-and_components_of_computer_system[1][1]C hapter 1   types-and_components_of_computer_system[1][1]
C hapter 1 types-and_components_of_computer_system[1][1]Pratik Gupta
 
Android sensors
Android sensorsAndroid sensors
Android sensorsdatta_jini
 
Android - Broadcast Receiver
Android - Broadcast ReceiverAndroid - Broadcast Receiver
Android - Broadcast ReceiverYong Heui Cho
 
Android - Sensor Manager
Android - Sensor ManagerAndroid - Sensor Manager
Android - Sensor ManagerYong Heui Cho
 

Andere mochten auch (20)

Chapter 5 ms access-1
Chapter 5   ms access-1Chapter 5   ms access-1
Chapter 5 ms access-1
 
Android Transition
Android TransitionAndroid Transition
Android Transition
 
Android Training (Animation)
Android Training (Animation)Android Training (Animation)
Android Training (Animation)
 
Uses of MS Access in Business
Uses of MS Access in BusinessUses of MS Access in Business
Uses of MS Access in Business
 
MS Access Training
MS Access TrainingMS Access Training
MS Access Training
 
Content provider in_android
Content provider in_androidContent provider in_android
Content provider in_android
 
Wi-Fi Direct
Wi-Fi DirectWi-Fi Direct
Wi-Fi Direct
 
Android Training (Content Provider)
Android Training (Content Provider)Android Training (Content Provider)
Android Training (Content Provider)
 
Android Training (Storing & Shared Preferences)
Android Training (Storing & Shared Preferences)Android Training (Storing & Shared Preferences)
Android Training (Storing & Shared Preferences)
 
Wifi direct p2p app
Wifi direct p2p appWifi direct p2p app
Wifi direct p2p app
 
Android Sensor System
Android Sensor SystemAndroid Sensor System
Android Sensor System
 
Chapter 3 storage media and devices
Chapter 3   storage media and devicesChapter 3   storage media and devices
Chapter 3 storage media and devices
 
Chapter 8 system analysis and design
Chapter 8   system analysis and designChapter 8   system analysis and design
Chapter 8 system analysis and design
 
Introduction to Wi-Fi Direct
Introduction to Wi-Fi DirectIntroduction to Wi-Fi Direct
Introduction to Wi-Fi Direct
 
Smartphone sensor and gesture
Smartphone sensor and gestureSmartphone sensor and gesture
Smartphone sensor and gesture
 
C hapter 1 types-and_components_of_computer_system[1][1]
C hapter 1   types-and_components_of_computer_system[1][1]C hapter 1   types-and_components_of_computer_system[1][1]
C hapter 1 types-and_components_of_computer_system[1][1]
 
Android Sensor
Android SensorAndroid Sensor
Android Sensor
 
Android sensors
Android sensorsAndroid sensors
Android sensors
 
Android - Broadcast Receiver
Android - Broadcast ReceiverAndroid - Broadcast Receiver
Android - Broadcast Receiver
 
Android - Sensor Manager
Android - Sensor ManagerAndroid - Sensor Manager
Android - Sensor Manager
 

Ähnlich wie Android Training (android fundamental)

Android application development
Android application developmentAndroid application development
Android application developmentMd. Mujahid Islam
 
Introduction to Android Development
Introduction to Android DevelopmentIntroduction to Android Development
Introduction to Android DevelopmentAly Abdelkareem
 
Nativa Android Applications development
Nativa Android Applications developmentNativa Android Applications development
Nativa Android Applications developmentAlfredo Morresi
 
Mobile Application Guideline | Mobile App Development Company
Mobile Application Guideline | Mobile App Development Company Mobile Application Guideline | Mobile App Development Company
Mobile Application Guideline | Mobile App Development Company Arna Softech Private Limited
 
Android core components.pptx
Android core components.pptxAndroid core components.pptx
Android core components.pptxAdarshNair65
 
Android 101 Session @thejunction32
Android 101 Session @thejunction32Android 101 Session @thejunction32
Android 101 Session @thejunction32Eden Shochat
 
Hello android world
Hello android worldHello android world
Hello android worldeleksdev
 
Android development Training Programme Day 2
Android development Training Programme Day 2Android development Training Programme Day 2
Android development Training Programme Day 2DHIRAJ PRAVIN
 
Android app fundamentals
Android app fundamentalsAndroid app fundamentals
Android app fundamentalsAmr Salman
 
A Framework for Providing Selective Permissions to Android Applications
A Framework for Providing Selective Permissions to Android ApplicationsA Framework for Providing Selective Permissions to Android Applications
A Framework for Providing Selective Permissions to Android ApplicationsIOSR Journals
 
Android training course
Android training courseAndroid training course
Android training courseAdarsh Pandey
 

Ähnlich wie Android Training (android fundamental) (20)

Android application development
Android application developmentAndroid application development
Android application development
 
Unit2
Unit2Unit2
Unit2
 
Android beginners David
Android beginners DavidAndroid beginners David
Android beginners David
 
Introduction to Android Development
Introduction to Android DevelopmentIntroduction to Android Development
Introduction to Android Development
 
Nativa Android Applications development
Nativa Android Applications developmentNativa Android Applications development
Nativa Android Applications development
 
Android Development Basics
Android Development BasicsAndroid Development Basics
Android Development Basics
 
Mobile Application Guideline | Mobile App Development Company
Mobile Application Guideline | Mobile App Development Company Mobile Application Guideline | Mobile App Development Company
Mobile Application Guideline | Mobile App Development Company
 
Android core components.pptx
Android core components.pptxAndroid core components.pptx
Android core components.pptx
 
Android 101 Session @thejunction32
Android 101 Session @thejunction32Android 101 Session @thejunction32
Android 101 Session @thejunction32
 
Hello android world
Hello android worldHello android world
Hello android world
 
Android
AndroidAndroid
Android
 
Android os
Android osAndroid os
Android os
 
Android development Training Programme Day 2
Android development Training Programme Day 2Android development Training Programme Day 2
Android development Training Programme Day 2
 
Android app fundamentals
Android app fundamentalsAndroid app fundamentals
Android app fundamentals
 
Android101
Android101Android101
Android101
 
A Framework for Providing Selective Permissions to Android Applications
A Framework for Providing Selective Permissions to Android ApplicationsA Framework for Providing Selective Permissions to Android Applications
A Framework for Providing Selective Permissions to Android Applications
 
Attendance_App
Attendance_AppAttendance_App
Attendance_App
 
Android OS
Android OSAndroid OS
Android OS
 
Android training course
Android training courseAndroid training course
Android training course
 
Android components
Android componentsAndroid components
Android components
 

Mehr von Khaled Anaqwa

Android Training (Storing data using SQLite)
Android Training (Storing data using SQLite)Android Training (Storing data using SQLite)
Android Training (Storing data using SQLite)Khaled Anaqwa
 
Android Training (Sensors)
Android Training (Sensors)Android Training (Sensors)
Android Training (Sensors)Khaled Anaqwa
 
Android Training (Media)
Android Training (Media)Android Training (Media)
Android Training (Media)Khaled Anaqwa
 
Android Training (AdapterView & Adapter)
Android Training (AdapterView & Adapter)Android Training (AdapterView & Adapter)
Android Training (AdapterView & Adapter)Khaled Anaqwa
 
Android Training (Android UI)
Android Training (Android UI)Android Training (Android UI)
Android Training (Android UI)Khaled Anaqwa
 
Android Training (Intro)
Android Training (Intro)Android Training (Intro)
Android Training (Intro)Khaled Anaqwa
 
Android Training (Java Review)
Android Training (Java Review)Android Training (Java Review)
Android Training (Java Review)Khaled Anaqwa
 

Mehr von Khaled Anaqwa (7)

Android Training (Storing data using SQLite)
Android Training (Storing data using SQLite)Android Training (Storing data using SQLite)
Android Training (Storing data using SQLite)
 
Android Training (Sensors)
Android Training (Sensors)Android Training (Sensors)
Android Training (Sensors)
 
Android Training (Media)
Android Training (Media)Android Training (Media)
Android Training (Media)
 
Android Training (AdapterView & Adapter)
Android Training (AdapterView & Adapter)Android Training (AdapterView & Adapter)
Android Training (AdapterView & Adapter)
 
Android Training (Android UI)
Android Training (Android UI)Android Training (Android UI)
Android Training (Android UI)
 
Android Training (Intro)
Android Training (Intro)Android Training (Intro)
Android Training (Intro)
 
Android Training (Java Review)
Android Training (Java Review)Android Training (Java Review)
Android Training (Java Review)
 

Kürzlich hochgeladen

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 

Kürzlich hochgeladen (20)

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 

Android Training (android fundamental)

  • 2. WHAT MAKES AN ANDROID APPLICATION?  Activities  Service  Content Providers  Intents  Broadcast Receivers  Widgets  Notifications
  • 3. Activities      An activity represent a single screen with a user interface Most applications contain multiple activities When a new activity starts, it is pushed onto back stack User interface can built with xml or java(xml is recommended) Monitor lifespan through callback methods like onStart() , onPause() ,etc
  • 4. Service      Services perform long-running operations in the background Dose not contain a user interface Useful for things like network operations, playing music , etc. Run independently of the component that created it. Can be bound to by other application components, if allowed (when all of them unbind, the service is destroyed)
  • 5. Content Providers       Used to store and retrieve data and make it accessible to all applications(the only way to share data across apps) They encapsulate the data, and provide mechanisms for defining data security connects data in one process with code running in another process. Exposes a public URI that uniquely identifies data set Data is exposed as a simple table on DB model Android contains many providers for things like contacts, media ,etc
  • 6. Broadcast Receivers  Is a component that responds to systemwide broadcast announcements  Example :announcing that the screen has turned off , the battery is low, etc.  App can also initiate their own broadcasts  Contain no user interface  They can create status bar notifications
  • 7. APPLICATION’S PRIORITY AND ITS PROCESS’ STATES  All Android applications continue running and in memory until the system needs resources for other applications.
  • 8. 1. Active processes  Active (foreground) processes have application components the user is interacting with.     Activities in an active state Broadcast Receivers executing onReceive Services executing onStart, onCreate Running Services that have been flagged to run in the foreground
  • 9. 2. Visible processes  Visible but inactive processes are those hosting “visible” Activities. This happens when an Activity is only partially obscured (by a non-full-screen or transparent Activity).
  • 10. 3. Started Service processes  Processes hosting Services that have been started. Because these Services don’t interact directly with the user, they receive a slightly lower priority than visible Activities or foreground Services.
  • 11. 4. Background processes  Processes hosting Activities that aren’t visible and that don’t have any running Services. There will generally be a large number of background processes that Android will kill using a last-seen-first-killed pattern in order to obtain resources for foreground processes.
  • 12. 5. Empty processes  To improve overall system performance, Android will often retain an application in memory after it has reached the end of its lifetime. Android maintains this cache to improve the start-up time of applications when they’re relaunched. These processes are routinely killed, as required.
  • 13.
  • 14. Manifest XML        It names the Java package for the application(unique identifier for the app.) It describes the components of the application It determines which processes will host application components. It declares which permissions the application must have permissions that others are required to have in order to interact with the application's components. It declares the minimum level of the Android API that the application requires. It lists the libraries that the application must be linked against.
  • 15. How Android features are reflected in the manifest file?  Intent Filters  Icons and Labels  Permissions  Libraries
  • 16. Intent Filters  The core components of an application (its activities, services, and broadcast receivers) are activated by intents.  An intent is a bundle of information (an Intent object) describing a desired action including the data to be acted upon, the category of component that should perform the action, and other pertinent instructions.
  • 19. Permission   A permission is a restriction limiting access to a part of the code or to data on the device. The limitation is imposed to protect critical data and code that could be misused to distort or damage the user experience. here are some permissions defined by Android:     android.permission.CALL_EMERGENCY_NUMBERS android.permission.READ_OWNER_DATA android.permission.SET_WALLPAPER android.permission.DEVICE_POWER
  • 20. Type of Permissions  <uses-permission>  <permission>  <permission-tree>(element declares a namespace for a group of permissions)  <permission-group>(defines a label for a set of permissions)  (tree-group)It affects only how the permissions are grouped when presented to the user.
  • 21. Libraries  <uses-library android:name="string" android:required=["true" | "false"] />  Specifies a shared library that the application must be linked against. This element tells the system to include the library's code in the class loader for the package.  Google Play uses the <uses-library> elements declared in your app manifest to filter your app from devices that do not meet it's library requirements.
  • 22.  All of the android packages such as  android.app (application components)  android.content(Content sharing, Resource,Package management)  android.view (basic user interface classes that handle screen layout and interaction with the user.)  android.widget (mostly visual UI elements) are in the default library that all applications are automatically linked against.  some packages (such as maps) are in separate libraries that are not automatically linked.

Hinweis der Redaktion

  1. The following components comprise the building blocks for all your Android applications: