Android 2.3 Gingerbread

Package android.app

High-level classes encapsulating the overall Android application model.

See:
          Description

Interface Summary
DatePickerDialog.OnDateSetListener The callback used to indicate the user is done filling in the date.
IActivityManager System private API for talking with the activity manager service.
IApplicationThread System private API for communicating with the application.
KeyguardManager.OnKeyguardExitResult Callback passed to KeyguardManager.exitKeyguardSecurely(android.app.KeyguardManager.OnKeyguardExitResult) to notify caller of result.
PendingIntent.OnFinished Callback interface for discovering when a send operation has completed.
SearchManager.OnCancelListener See SearchManager.setOnCancelListener(android.app.SearchManager.OnCancelListener) for configuring your activity to monitor search UI state.
SearchManager.OnDismissListener See SearchManager.setOnDismissListener(android.app.SearchManager.OnDismissListener) for configuring your activity to monitor search UI state.
TimePickerDialog.OnTimeSetListener The callback interface used to indicate the user is done filling in the time (they clicked on the 'Set' button).
 

Class Summary
Activity An activity is a single, focused thing that the user can do.
ActivityGroup A screen that contains and runs multiple embedded activities.
ActivityManager Interact with the overall activities running in the system.
ActivityManager.MemoryInfo Information you can retrieve about the available memory through ActivityManager.getMemoryInfo(android.app.ActivityManager.MemoryInfo).
ActivityManager.ProcessErrorStateInfo Information you can retrieve about any processes that are in an error condition.
ActivityManager.RecentTaskInfo Information you can retrieve about tasks that the user has most recently started or visited.
ActivityManager.RunningAppProcessInfo Information you can retrieve about a running process.
ActivityManager.RunningServiceInfo Information you can retrieve about a particular Service that is currently running in the system.
ActivityManager.RunningTaskInfo Information you can retrieve about a particular task that is currently "running" in the system.
ActivityManagerNative
ActivityManagerProxy  
ActivityThread This manages the execution of the main thread in an application process, scheduling and executing activities, broadcasts, and other operations on it as the activity manager requests.
AlarmManager This class provides access to the system alarm services.
AlertDialog A subclass of Dialog that can display one, two or three buttons.
AlertDialog.Builder  
AliasActivity Stub activity that launches another activity (and then finishes itself) based on information in its component's manifest meta-data.
AppGlobals Special private access for certain globals related to a process.
Application Base class for those who need to maintain global application state.
ApplicationErrorReport Describes an application error.
ApplicationErrorReport.AnrInfo Describes an application not responding error.
ApplicationErrorReport.BatteryInfo Describes a battery usage report.
ApplicationErrorReport.CrashInfo Describes an application crash.
ApplicationErrorReport.RunningServiceInfo Describes a running service report.
ApplicationLoaders  
ApplicationThreadNative
ApplicationThreadProxy  
ContextImpl Common implementation of Context API, which provides the base context object for Activity and other application components.
ContextImpl.ApplicationPackageManager  
DatePickerDialog A simple dialog containing an DatePicker.
Dialog Base class for Dialogs.
DownloadManager The download manager is a system service that handles long-running HTTP downloads.
DownloadManager.Query This class may be used to filter download manager queries.
DownloadManager.Request This class contains all the information necessary to request a new download.
ExpandableListActivity An activity that displays an expandable list of items by binding to a data source implementing the ExpandableListAdapter, and exposes event handlers when the user selects an item.
FullBackupAgent Backs up an application's entire /data/data/<package>/...
IActivityManager.ContentProviderHolder Information you can retrieve about a particular application.
IActivityManager.WaitResult Information returned after waiting for an activity start.
Instrumentation Base class for implementing application instrumentation code.
Instrumentation.ActivityMonitor Information about a particular kind of Intent that is being monitored.
Instrumentation.ActivityResult Description of a Activity execution result to return to the original activity.
IntentService IntentService is a base class for Services that handle asynchronous requests (expressed as Intents) on demand.
KeyguardManager Class that can be used to lock and unlock the keyboard.
LauncherActivity Displays a list of all activities which can be performed for a given intent.
LauncherActivity.ListItem An item in the list
ListActivity An activity that displays a list of items by binding to a data source such as an array or Cursor, and exposes event handlers when the user selects an item.
LoadedApk Local state maintained about a currently loaded .apk.
LoadedApk.ReceiverDispatcher  
LoadedApk.ReceiverDispatcher.InnerReceiver  
LoadedApk.ServiceDispatcher  
LocalActivityManager Helper class for managing multiple running embedded activities in the same process.
NativeActivity Convenience for implementing an activity that will be implemented purely in native code.
NativeActivity.InputMethodCallback  
NativeActivity.NativeContentView  
Notification A class that represents how a persistent notification is to be presented to the user using the NotificationManager.
NotificationManager Class to notify the user of events that happen.
PendingIntent A description of an Intent and target action to perform with it.
ProgressDialog A dialog showing a progress indicator and an optional text message or view.
QueuedWork Internal utility class to keep track of process-global work that's outstanding and hasn't been finished yet.
ReceiverRestrictedContext  
ResultInfo
SearchableInfo Searchability meta-data for an activity.
SearchableInfo.ActionKeyInfo Information about an action key in searchability meta-data.
SearchDialog Search dialog.
SearchDialog.SearchAutoComplete Local subclass for AutoCompleteTextView.
SearchDialog.SearchBar The root element in the search bar layout.
SearchManager This class provides access to the system search services.
Service A Service is an application component representing either an application's desire to perform a longer-running operation while not interacting with the user or to supply functionality for other applications to use.
StatusBarManager Allows an app to control the status bar.
SuggestionsAdapter Provides the contents for the suggestion drop-down list.in SearchDialog.
TabActivity An activity that contains and runs multiple embedded activities or views.
TimePickerDialog A dialog that prompts the user for the time of day using a TimePicker.
UiModeManager This class provides access to the system uimode services.
WallpaperInfo This class is used to specify meta information of a wallpaper service.
WallpaperManager Provides access to the system wallpaper.
WallpaperManager.FastBitmapDrawable Special drawable that draws a wallpaper as fast as possible.
WallpaperManager.Globals  
 

Exception Summary
IntentReceiverLeaked  
PendingIntent.CanceledException Exception thrown when trying to send through a PendingIntent that has been canceled or is otherwise no longer able to execute the request.
RemoteServiceException  
ServiceConnectionLeaked  
SuperNotCalledException  
 

Package android.app Description

High-level classes encapsulating the overall Android application model. The central class is Activity, with other top-level application components being defined by Service and, from the android.content package, BroadcastReceiver and ContentProvider. It also includes application tools, such as dialogs and notifications.

This package builds on top of the lower-level Android packages android.widget, android.view, android.content, android.text, android.graphics, android.os, and android.util.

An Activity is a specific operation the user can perform, generally corresponding to one screen in the user interface. It is the basic building block of an Android application. Examples of activities are "view the list of people," "view the details of a person," "edit information about a person," "view an image," etc. Switching from one activity to another generally implies adding a new entry on the navigation history; that is, going "back" means moving to the previous activity you were doing.

A set of related activities can be grouped together as a "task". Until a new task is explicitly specified, all activites you start are considered to be part of the current task. While the only way to navigate between individual activities is by going "back" in the history stack, the group of activities in a task can be moved in relation to other tasks: for example to the front or the back of the history stack. This mechanism can be used to present to the user a list of things they have been doing, moving between them without disrupting previous work.

A complete "application" is a set of activities that allow the user to do a cohesive group of operations -- such as working with contacts, working with a calendar, messaging, etc. Though there can be a custom application object associated with a set of activities, in many cases this is not needed -- each activity provides a particular path into one of the various kinds of functionality inside of the application, serving as its on self-contained "mini application".

This approach allows an application to be broken into pieces, which can be reused and replaced in a variety of ways. Consider, for example, a "camera application." There are a number of things this application must do, each of which is provided by a separate activity: take a picture (creating a new image), browse through the existing images, display a specific image, etc. If the "contacts application" then wants to let the user associate an image with a person, it can simply launch the existing "take a picture" or "select an image" activity that is part of the camera application and attach the picture it gets back.

Note that there is no hard relationship between tasks the user sees and applications the developer writes. A task can be composed of activities from multiple applications (such as the contact application using an activity in the camera application to get a picture for a person), and multiple active tasks may be running for the same application (such as editing e-mail messages to two different people). The way tasks are organized is purely a UI policy decided by the system; for example, typically a new task is started when the user goes to the application launcher and selects an application.


Android 2.3 Gingerbread