Other Android components
Android has several more components which can be used in your Android application.
Intents
Intents are asynchronous messages which allow the application to request functionality from other components of the Android system, e.g. from Services or Activities. An application can call a component directly (explicit Intent) or ask the Android system to evaluate registered components based on the Intent data (implicit Intents ). For example the application could implement sharing of data via an
Intent
and all components which allow sharing of data would be available for the user to select. Applications register themselves to an Intent via an IntentFilter.Intents allow to combine loosely coupled components to perform certain tasks.
Services
Services perform background tasks without providing a user interface. They can notify the user via the notification framework in Android.
ContentProvider
A ContentProvider provides a structured interface to application data. Via a ContentProvider your application can share data with other applications. Android contains an SQLite database which is frequently used in conjunction with a ContentProvider. The SQLite database would store the data, which would be accessed via the ContentProvider.
BroadcastReceiver
BroadcastReceiver can be registered to receive system messages and Intents. A BroadcastReceiver will get notified by the Android system, if the specified situation happens. For example a BroadcastReceiver could get called once the Android system completed the boot process or if a phone call is received.
(HomeScreen) Widgets
Widgets are interactive components which are primarily used on the Android homescreen. They typically display some kind of data and allow the user to perform actions via them. For example a Widget could display a short summary of new emails and if the user selects an email, it could start the email application with the selected email.
More Components
Android provide many more components but the list above describes the most important ones. Other Android components are Live Folders and Live Wallpapers . Live Folders display data on the homescreen without launching the corresponding application while Live Wallpapers allow to create animated backgrounds.
Related Topics : Android Development Tutorial (Based on Android 4.1) class-1
No comments:
Post a Comment