AccessibilityService Class

Definition

Accessibility services should only be used to assist users with disabilities in using Android devices and apps.

[Android.Runtime.Register("android/accessibilityservice/AccessibilityService", DoNotGenerateAcw=true)]
public abstract class AccessibilityService : Android.App.Service
[<Android.Runtime.Register("android/accessibilityservice/AccessibilityService", DoNotGenerateAcw=true)>]
type AccessibilityService = class
    inherit Service
Inheritance
AccessibilityService
Attributes

Remarks

Accessibility services should only be used to assist users with disabilities in using Android devices and apps. They run in the background and receive callbacks by the system when AccessibilityEvents are fired. Such events denote some state transition in the user interface, for example, the focus has changed, a button has been clicked, etc. Such a service can optionally request the capability for querying the content of the active window. Development of an accessibility service requires extending this class and implementing its abstract methods.

<div class="special reference"> <h3>Developer Guides</h3>

For more information about creating AccessibilityServices, read the Accessibility developer guide.

</div>

<h3>Lifecycle</h3>

The lifecycle of an accessibility service is managed exclusively by the system and follows the established service life cycle. Starting an accessibility service is triggered exclusively by the user explicitly turning the service on in device settings. After the system binds to a service, it calls AccessibilityService#onServiceConnected(). This method can be overridden by clients that want to perform post binding setup.

An accessibility service stops either when the user turns it off in device settings or when it calls AccessibilityService#disableSelf().

<h3>Declaration</h3>

An accessibility is declared as any other service in an AndroidManifest.xml, but it must do two things: <ul> <li> Specify that it handles the "android.accessibilityservice.AccessibilityService" android.content.Intent. </li> <li> Request the android.Manifest.permission#BIND_ACCESSIBILITY_SERVICE permission to ensure that only the system can bind to it. </li> </ul> If either of these items is missing, the system will ignore the accessibility service. Following is an example declaration:

&lt;service android:name=".MyAccessibilityService"
                    android:permission="android.permission.BIND_ACCESSIBILITY_SERVICE"&gt;
                &lt;intent-filter&gt;
                    &lt;action android:name="android.accessibilityservice.AccessibilityService" /&gt;
                &lt;/intent-filter&gt;
                . . .
            &lt;/service&gt;

<h3>Configuration</h3>

An accessibility service can be configured to receive specific types of accessibility events, listen only to specific packages, get events from each type only once in a given time frame, retrieve window content, specify a settings activity, etc.

There are two approaches for configuring an accessibility service:

<ul> <li> Providing a #SERVICE_META_DATA meta-data entry in the manifest when declaring the service. A service declaration with a meta-data tag is presented below:

&lt;service android:name=".MyAccessibilityService"&gt;
                &lt;intent-filter&gt;
                    &lt;action android:name="android.accessibilityservice.AccessibilityService" /&gt;
                &lt;/intent-filter&gt;
                &lt;meta-data android:name="android.accessibilityservice" android:resource="@xml/accessibilityservice" /&gt;
            &lt;/service&gt;

<p class="note"> <strong>Note:</strong> This approach enables setting all properties. </p>

For more details refer to #SERVICE_META_DATA and &lt;{@link android.R.styleable#AccessibilityService accessibility-service}&gt;.

</li> <li> Calling AccessibilityService#setServiceInfo(AccessibilityServiceInfo). Note that this method can be called any time to dynamically change the service configuration. <p class="note"> <strong>Note:</strong> This approach enables setting only dynamically configurable properties: AccessibilityServiceInfo#eventTypes, AccessibilityServiceInfo#feedbackType, AccessibilityServiceInfo#flags, AccessibilityServiceInfo#notificationTimeout, AccessibilityServiceInfo#packageNames</p>

For more details refer to AccessibilityServiceInfo.

</li> </ul> <h3>Retrieving window content</h3>

A service can specify in its declaration that it can retrieve window content which is represented as a tree of AccessibilityWindowInfo and AccessibilityNodeInfo objects. Note that declaring this capability requires that the service declares its configuration via an XML resource referenced by #SERVICE_META_DATA.

Window content may be retrieved with AccessibilityEvent#getSource() AccessibilityEvent.getSource(), AccessibilityService#findFocus(int), AccessibilityService#getWindows(), or AccessibilityService#getRootInActiveWindow().

<p class="note"> <strong>Note</strong> An accessibility service may have requested to be notified for a subset of the event types, and thus be unaware when the node hierarchy has changed. It is also possible for a node to contain outdated information because the window content may change at any time. </p> <h3>Drawing Accessibility Overlays</h3>

Accessibility services can draw overlays on top of existing screen contents. Accessibility overlays can be used to visually highlight items on the screen e.g. indicate the current item with accessibility focus. Overlays can also offer the user a way to interact with the service directly and quickly customize the service's behavior.

Accessibility overlays can be attached to a particular window or to the display itself. Attaching an overlay to a window allows the overly to move, grow and shrink as the window does. The overlay will maintain the same relative position within the window bounds as the window moves. The overlay will also maintain the same relative position within the window bounds if the window is resized. To attach an overlay to a window, use #attachAccessibilityOverlayToWindow. Attaching an overlay to the display means that the overlay is independent of the active windows on that display. To attach an overlay to a display, use #attachAccessibilityOverlayToDisplay.

When positioning an overlay that is attached to a window, the service must use window coordinates. In order to position an overlay on top of an existing UI element it is necessary to know the bounds of that element in window coordinates. To find the bounds in window coordinates of an element, find the corresponding AccessibilityNodeInfo as discussed above and call AccessibilityNodeInfo#getBoundsInWindow.

<h3>Notification strategy</h3>

All accessibility services are notified of all events they have requested, regardless of their feedback type.

<p class="note"> <strong>Note:</strong> The event notification timeout is useful to avoid propagating events to the client too frequently since this is accomplished via an expensive interprocess call. One can think of the timeout as a criteria to determine when event generation has settled down.</p> <h3>Event types</h3> <ul> <li>AccessibilityEvent#TYPE_VIEW_CLICKED</li> <li>AccessibilityEvent#TYPE_VIEW_LONG_CLICKED</li> <li>AccessibilityEvent#TYPE_VIEW_FOCUSED</li> <li>AccessibilityEvent#TYPE_VIEW_SELECTED</li> <li>AccessibilityEvent#TYPE_VIEW_TEXT_CHANGED</li> <li>AccessibilityEvent#TYPE_WINDOW_STATE_CHANGED</li> <li>AccessibilityEvent#TYPE_NOTIFICATION_STATE_CHANGED</li> <li>AccessibilityEvent#TYPE_TOUCH_EXPLORATION_GESTURE_START</li> <li>AccessibilityEvent#TYPE_TOUCH_EXPLORATION_GESTURE_END</li> <li>AccessibilityEvent#TYPE_VIEW_HOVER_ENTER</li> <li>AccessibilityEvent#TYPE_VIEW_HOVER_EXIT</li> <li>AccessibilityEvent#TYPE_VIEW_SCROLLED</li> <li>AccessibilityEvent#TYPE_VIEW_TEXT_SELECTION_CHANGED</li> <li>AccessibilityEvent#TYPE_WINDOW_CONTENT_CHANGED</li> <li>AccessibilityEvent#TYPE_ANNOUNCEMENT</li> <li>AccessibilityEvent#TYPE_GESTURE_DETECTION_START</li> <li>AccessibilityEvent#TYPE_GESTURE_DETECTION_END</li> <li>AccessibilityEvent#TYPE_TOUCH_INTERACTION_START</li> <li>AccessibilityEvent#TYPE_TOUCH_INTERACTION_END</li> <li>AccessibilityEvent#TYPE_VIEW_ACCESSIBILITY_FOCUSED</li> <li>AccessibilityEvent#TYPE_WINDOWS_CHANGED</li> <li>AccessibilityEvent#TYPE_VIEW_ACCESSIBILITY_FOCUS_CLEARED</li> </ul> <h3>Feedback types</h3> <ul> <li>AccessibilityServiceInfo#FEEDBACK_AUDIBLE</li> <li>AccessibilityServiceInfo#FEEDBACK_HAPTIC</li> <li>AccessibilityServiceInfo#FEEDBACK_SPOKEN</li> <li>AccessibilityServiceInfo#FEEDBACK_VISUAL</li> <li>AccessibilityServiceInfo#FEEDBACK_GENERIC</li> <li>AccessibilityServiceInfo#FEEDBACK_BRAILLE</li> </ul>

Java documentation for android.accessibilityservice.AccessibilityService.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Constructors

AccessibilityService()
AccessibilityService(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

Fields

AccessibilityService

Use with #getSystemService(String) to retrieve a android.view.accessibility.AccessibilityManager for giving the user feedback for UI events through the registered event listeners.

(Inherited from Context)
AccountService

Use with #getSystemService(String) to retrieve a android.accounts.AccountManager for receiving intents at a time of your choosing.

(Inherited from Context)
ActivityService

Use with #getSystemService(String) to retrieve a android.app.ActivityManager for interacting with the global system state.

(Inherited from Context)
AlarmService

Use with #getSystemService(String) to retrieve a android.app.AlarmManager for receiving intents at a time of your choosing.

(Inherited from Context)
AppOpsService

Use with #getSystemService(String) to retrieve a android.app.AppOpsManager for tracking application operations on the device.

(Inherited from Context)
AppSearchService

Use with #getSystemService(String) to retrieve an android.app.appsearch.AppSearchManager for indexing and querying app data managed by the system.

(Inherited from Context)
AppwidgetService

Use with #getSystemService(String) to retrieve a android.appwidget.AppWidgetManager for accessing AppWidgets.

(Inherited from Context)
AudioService

Use with #getSystemService(String) to retrieve a android.media.AudioManager for handling management of volume, ringer modes and audio routing.

(Inherited from Context)
BatteryService

Use with #getSystemService(String) to retrieve a android.os.BatteryManager for managing battery state.

(Inherited from Context)
BindAllowActivityStarts
Obsolete.

Flag for #bindService: If binding from an app that is visible, the bound service is allowed to start an activity from background.

(Inherited from Context)
BindExternalServiceLong

Works in the same way as #BIND_EXTERNAL_SERVICE, but it's defined as a (

(Inherited from Context)
BindNotPerceptible
Obsolete.

Flag for #bindService: If binding from an app that is visible or user-perceptible, lower the target service's importance to below the perceptible level.

(Inherited from Context)
BindSharedIsolatedProcess
Obsolete.

Flag for #bindIsolatedService: Bind the service into a shared isolated process.

(Inherited from Context)
BiometricService

Use with #getSystemService(String) to retrieve a android.hardware.biometrics.BiometricManager for handling biometric and PIN/pattern/password authentication.

(Inherited from Context)
BlobStoreService

Use with #getSystemService(String) to retrieve a android.app.blob.BlobStoreManager for contributing and accessing data blobs from the blob store maintained by the system.

(Inherited from Context)
BluetoothService

Use with #getSystemService(String) to retrieve a android.bluetooth.BluetoothManager for using Bluetooth.

(Inherited from Context)
BugreportService

Service to capture a bugreport.

(Inherited from Context)
CameraService

Use with #getSystemService(String) to retrieve a android.hardware.camera2.CameraManager for interacting with camera devices.

(Inherited from Context)
CaptioningService

Use with #getSystemService(String) to retrieve a android.view.accessibility.CaptioningManager for obtaining captioning properties and listening for changes in captioning preferences.

(Inherited from Context)
CarrierConfigService

Use with #getSystemService(String) to retrieve a android.telephony.CarrierConfigManager for reading carrier configuration values.

(Inherited from Context)
ClipboardService

Use with #getSystemService(String) to retrieve a android.content.ClipboardManager for accessing and modifying the contents of the global clipboard.

(Inherited from Context)
CompanionDeviceService

Use with #getSystemService(String) to retrieve a android.companion.CompanionDeviceManager for managing companion devices

(Inherited from Context)
ConnectivityDiagnosticsService

Use with #getSystemService(String) to retrieve a android.net.ConnectivityDiagnosticsManager for performing network connectivity diagnostics as well as receiving network connectivity information from the system.

(Inherited from Context)
ConnectivityService

Use with #getSystemService(String) to retrieve a android.net.ConnectivityManager for handling management of network connections.

(Inherited from Context)
ConsumerIrService

Use with #getSystemService(String) to retrieve a android.hardware.ConsumerIrManager for transmitting infrared signals from the device.

(Inherited from Context)
CredentialService

Use with #getSystemService(String) to retrieve a android.credentials.CredentialManager to authenticate a user to your app.

(Inherited from Context)
CrossProfileAppsService

Use with #getSystemService(String) to retrieve a android.content.pm.CrossProfileApps for cross profile operations.

(Inherited from Context)
DeviceIdDefault

The default device ID, which is the ID of the primary (non-virtual) device.

(Inherited from Context)
DeviceIdInvalid

Invalid device ID.

(Inherited from Context)
DeviceLockService

Use with #getSystemService(String) to retrieve a android.devicelock.DeviceLockManager.

(Inherited from Context)
DevicePolicyService

Use with #getSystemService(String) to retrieve a android.app.admin.DevicePolicyManager for working with global device policy management.

(Inherited from Context)
DisplayHashService

Use with #getSystemService(String) to access android.view.displayhash.DisplayHashManager to handle display hashes.

(Inherited from Context)
DisplayService

Use with #getSystemService(String) to retrieve a android.hardware.display.DisplayManager for interacting with display devices.

(Inherited from Context)
DomainVerificationService

Use with #getSystemService(String) to access android.content.pm.verify.domain.DomainVerificationManager to retrieve approval and user state for declared web domains.

(Inherited from Context)
DownloadService

Use with #getSystemService(String) to retrieve a android.app.DownloadManager for requesting HTTP downloads.

(Inherited from Context)
DropboxService

Use with #getSystemService(String) to retrieve a android.os.DropBoxManager instance for recording diagnostic logs.

(Inherited from Context)
ErrorTakeScreenshotInternalError
Obsolete.

The status of taking screenshot is failure and the reason is internal error.

ErrorTakeScreenshotIntervalTimeShort
Obsolete.

The status of taking screenshot is failure and the reason is that too little time has elapsed since the last screenshot.

ErrorTakeScreenshotInvalidDisplay
Obsolete.

The status of taking screenshot is failure and the reason is invalid display Id.

ErrorTakeScreenshotInvalidWindow
Obsolete.

The status of taking screenshot is failure and the reason is invalid accessibility window Id.

ErrorTakeScreenshotNoAccessibilityAccess
Obsolete.

The status of taking screenshot is failure and the reason is no accessibility access.

ErrorTakeScreenshotSecureWindow
Obsolete.

The status of taking screenshot is failure and the reason is the window contains secure content.

EuiccService

Use with #getSystemService(String) to retrieve a android.telephony.euicc.EuiccManager to manage the device eUICC (embedded SIM).

(Inherited from Context)
FileIntegrityService

Use with #getSystemService(String) to retrieve an android.security.FileIntegrityManager.

(Inherited from Context)
FingerprintService

Use with #getSystemService(String) to retrieve a android.hardware.fingerprint.FingerprintManager for handling management of fingerprints.

(Inherited from Context)
GameService

Use with #getSystemService(String) to retrieve a GameManager.

(Inherited from Context)
Gesture2FingerDoubleTap
Obsolete.

The user has performed a two-finger double tap gesture on the touch screen.

Gesture2FingerDoubleTapAndHold
Obsolete.

The user has performed a two-finger double tap and hold gesture on the touch screen.

Gesture2FingerSingleTap
Obsolete.

The user has performed a two-finger single tap gesture on the touch screen.

Gesture2FingerSwipeDown
Obsolete.

The user has performed a two-finger swipe down gesture on the touch screen.

Gesture2FingerSwipeLeft
Obsolete.

The user has performed a two-finger swipe left gesture on the touch screen.

Gesture2FingerSwipeRight
Obsolete.

The user has performed a two-finger swipe right gesture on the touch screen.

Gesture2FingerSwipeUp
Obsolete.

The user has performed a two-finger swipe up gesture on the touch screen.

Gesture2FingerTripleTap
Obsolete.

The user has performed a two-finger triple tap gesture on the touch screen.

Gesture2FingerTripleTapAndHold
Obsolete.

The user has performed a two-finger triple-tap and hold gesture on the touch screen.

Gesture3FingerDoubleTap
Obsolete.

The user has performed a three-finger double tap gesture on the touch screen.

Gesture3FingerDoubleTapAndHold
Obsolete.

The user has performed a three-finger double tap and hold gesture on the touch screen.

Gesture3FingerSingleTap
Obsolete.

The user has performed a three-finger single tap gesture on the touch screen.

Gesture3FingerSingleTapAndHold
Obsolete.

The user has performed a three-finger single-tap and hold gesture on the touch screen.

Gesture3FingerSwipeDown
Obsolete.

The user has performed a three-finger swipe down gesture on the touch screen.

Gesture3FingerSwipeLeft
Obsolete.

The user has performed a three-finger swipe left gesture on the touch screen.

Gesture3FingerSwipeRight
Obsolete.

The user has performed a three-finger swipe right gesture on the touch screen.

Gesture3FingerSwipeUp
Obsolete.

The user has performed a three-finger swipe up gesture on the touch screen.

Gesture3FingerTripleTap
Obsolete.

The user has performed a three-finger triple tap gesture on the touch screen.

Gesture3FingerTripleTapAndHold
Obsolete.

The user has performed a three-finger triple-tap and hold gesture on the touch screen.

Gesture4FingerDoubleTap
Obsolete.

The user has performed a four-finger double tap gesture on the touch screen.

Gesture4FingerDoubleTapAndHold
Obsolete.

The user has performed a two-finger double tap and hold gesture on the touch screen.

Gesture4FingerSingleTap
Obsolete.

The user has performed a four-finger single tap gesture on the touch screen.

Gesture4FingerSwipeDown
Obsolete.

The user has performed a four-finger swipe down gesture on the touch screen.

Gesture4FingerSwipeLeft
Obsolete.

The user has performed a four-finger swipe left gesture on the touch screen.

Gesture4FingerSwipeRight
Obsolete.

The user has performed a four-finger swipe right gesture on the touch screen.

Gesture4FingerSwipeUp
Obsolete.

The user has performed a four-finger swipe up gesture on the touch screen.

Gesture4FingerTripleTap
Obsolete.

The user has performed a four-finger triple tap gesture on the touch screen.

GestureDoubleTap
Obsolete.

The user has performed a double tap gesture on the touch screen.

GestureDoubleTapAndHold
Obsolete.

The user has performed a double tap and hold gesture on the touch screen.

GestureSwipeDown
Obsolete.

The user has performed a swipe down gesture on the touch screen.

GestureSwipeDownAndLeft
Obsolete.

The user has performed an down and left gesture on the touch screen.

GestureSwipeDownAndRight
Obsolete.

The user has performed an down and right gesture on the touch screen.

GestureSwipeDownAndUp
Obsolete.

The user has performed a swipe down and up gesture on the touch screen.

GestureSwipeLeft
Obsolete.

The user has performed a swipe left gesture on the touch screen.

GestureSwipeLeftAndDown
Obsolete.

The user has performed a left and down gesture on the touch screen.

GestureSwipeLeftAndRight
Obsolete.

The user has performed a swipe left and right gesture on the touch screen.

GestureSwipeLeftAndUp
Obsolete.

The user has performed a left and up gesture on the touch screen.

GestureSwipeRight
Obsolete.

The user has performed a swipe right gesture on the touch screen.

GestureSwipeRightAndDown
Obsolete.

The user has performed a right and down gesture on the touch screen.

GestureSwipeRightAndLeft
Obsolete.

The user has performed a swipe right and left gesture on the touch screen.

GestureSwipeRightAndUp
Obsolete.

The user has performed a right and up gesture on the touch screen.

GestureSwipeUp
Obsolete.

The user has performed a swipe up gesture on the touch screen.

GestureSwipeUpAndDown
Obsolete.

The user has performed a swipe up and down gesture on the touch screen.

GestureSwipeUpAndLeft
Obsolete.

The user has performed an up and left gesture on the touch screen.

GestureSwipeUpAndRight
Obsolete.

The user has performed an up and right gesture on the touch screen.

GestureUnknown
Obsolete.

The user has performed an unrecognized gesture on the touch screen.

GlobalActionAccessibilityAllApps
Obsolete.

Action to show Launcher's all apps.

GlobalActionAccessibilityButton
Obsolete.

Action to trigger the Accessibility Button

GlobalActionAccessibilityButtonChooser
Obsolete.

Action to bring up the Accessibility Button's chooser menu

GlobalActionAccessibilityShortcut
Obsolete.

Action to trigger the Accessibility Shortcut.

GlobalActionBack
Obsolete.

Action to go back.

GlobalActionDismissNotificationShade
Obsolete.

Action to dismiss the notification shade

GlobalActionDpadCenter
Obsolete.

Action to trigger dpad center keyevent.

GlobalActionDpadDown
Obsolete.

Action to trigger dpad down keyevent.

GlobalActionDpadLeft
Obsolete.

Action to trigger dpad left keyevent.

GlobalActionDpadRight
Obsolete.

Action to trigger dpad right keyevent.

GlobalActionDpadUp
Obsolete.

Action to trigger dpad up keyevent.

GlobalActionHome
Obsolete.

Action to go home.

GlobalActionKeycodeHeadsethook
Obsolete.

Action to send the KEYCODE_HEADSETHOOK KeyEvent, which is used to answer/hang up calls and play/stop media

GlobalActionLockScreen
Obsolete.

Action to lock the screen

GlobalActionNotifications
Obsolete.

Action to open the notifications.

GlobalActionPowerDialog
Obsolete.

Action to open the power long-press dialog.

GlobalActionQuickSettings
Obsolete.

Action to open the quick settings.

GlobalActionRecents
Obsolete.

Action to toggle showing the overview of recent apps.

GlobalActionTakeScreenshot
Obsolete.

Action to take a screenshot

GlobalActionToggleSplitScreen
Obsolete.

Action to toggle docking the current app's window.

GrammaticalInflectionService

Use with #getSystemService(String) to retrieve a GrammaticalInflectionManager.

(Inherited from Context)
HardwarePropertiesService

Use with #getSystemService(String) to retrieve a android.os.HardwarePropertiesManager for accessing the hardware properties service.

(Inherited from Context)
HealthconnectService

Use with #getSystemService(String) to retrieve a android.health.connect.HealthConnectManager.

(Inherited from Context)
InputMethodService

Use with #getSystemService(String) to retrieve a android.view.inputmethod.InputMethodManager for accessing input methods.

(Inherited from Context)
InputService

Use with #getSystemService(String) to retrieve a android.hardware.input.InputManager for interacting with input devices.

(Inherited from Context)
IpsecService

Use with #getSystemService(String) to retrieve a android.net.IpSecManager for encrypting Sockets or Networks with IPSec.

(Inherited from Context)
JobSchedulerService

Use with #getSystemService(String) to retrieve a android.app.job.JobScheduler instance for managing occasional background tasks.

(Inherited from Context)
KeyguardService

Use with #getSystemService(String) to retrieve a android.app.KeyguardManager for controlling keyguard.

(Inherited from Context)
LauncherAppsService

Use with #getSystemService(String) to retrieve a android.content.pm.LauncherApps for querying and monitoring launchable apps across profiles of a user.

(Inherited from Context)
LayoutInflaterService

Use with #getSystemService(String) to retrieve a android.view.LayoutInflater for inflating layout resources in this context.

(Inherited from Context)
LocaleService

Use with #getSystemService(String) to retrieve a android.app.LocaleManager.

(Inherited from Context)
LocationService

Use with #getSystemService(String) to retrieve a android.location.LocationManager for controlling location updates.

(Inherited from Context)
MediaCommunicationService

Use with #getSystemService(String) to retrieve a android.media.MediaCommunicationManager for managing android.media.MediaSession2.

(Inherited from Context)
MediaMetricsService

Use with #getSystemService(String) to retrieve a android.media.metrics.MediaMetricsManager for interacting with media metrics on the device.

(Inherited from Context)
MediaProjectionService

Use with #getSystemService(String) to retrieve a android.media.projection.MediaProjectionManager instance for managing media projection sessions.

(Inherited from Context)
MediaRouterService

Use with #getSystemService to retrieve a android.media.MediaRouter for controlling and managing routing of media.

(Inherited from Context)
MediaSessionService

Use with #getSystemService(String) to retrieve a android.media.session.MediaSessionManager for managing media Sessions.

(Inherited from Context)
MidiService

Use with #getSystemService(String) to retrieve a android.media.midi.MidiManager for accessing the MIDI service.

(Inherited from Context)
NetworkStatsService

Use with #getSystemService(String) to retrieve a android.app.usage.NetworkStatsManager for querying network usage stats.

(Inherited from Context)
NfcService

Use with #getSystemService(String) to retrieve a android.nfc.NfcManager for using NFC.

(Inherited from Context)
NotificationService

Use with #getSystemService(String) to retrieve a android.app.NotificationManager for informing the user of background events.

(Inherited from Context)
NsdService

Use with #getSystemService(String) to retrieve a android.net.nsd.NsdManager for handling management of network service discovery

(Inherited from Context)
OverlayService

Use with #getSystemService(String) to retrieve a android.content.om.OverlayManager for managing overlay packages.

(Inherited from Context)
PeopleService

Use with #getSystemService(String) to access a PeopleManager to interact with your published conversations.

(Inherited from Context)
PerformanceHintService

Use with #getSystemService(String) to retrieve a android.os.PerformanceHintManager for accessing the performance hinting service.

(Inherited from Context)
PowerService

Use with #getSystemService(String) to retrieve a android.os.PowerManager for controlling power management, including "wake locks," which let you keep the device on while you're running long tasks.

(Inherited from Context)
PrintService

android.print.PrintManager for printing and managing printers and print tasks.

(Inherited from Context)
ReceiverExported
Obsolete.

Flag for #registerReceiver: The receiver can receive broadcasts from other Apps.

(Inherited from Context)
ReceiverNotExported
Obsolete.

Flag for #registerReceiver: The receiver cannot receive broadcasts from other Apps.

(Inherited from Context)
ReceiverVisibleToInstantApps
Obsolete.

Flag for #registerReceiver: The receiver can receive broadcasts from Instant Apps.

(Inherited from Context)
RestrictionsService

Use with #getSystemService(String) to retrieve a android.content.RestrictionsManager for retrieving application restrictions and requesting permissions for restricted operations.

(Inherited from Context)
RoleService

Use with #getSystemService(String) to retrieve a android.app.role.RoleManager for managing roles.

(Inherited from Context)
SearchService

Use with #getSystemService(String) to retrieve a android.app.SearchManager for handling searches.

(Inherited from Context)
SensorService

Use with #getSystemService(String) to retrieve a android.hardware.SensorManager for accessing sensors.

(Inherited from Context)
ServiceInterface

The Intent that must be declared as handled by the service.

ServiceMetaData

Name under which an AccessibilityService component publishes information about itself.

ShortcutService

Use with #getSystemService(String) to retrieve a android.content.pm.ShortcutManager for accessing the launcher shortcut service.

(Inherited from Context)
ShowModeAuto
Obsolete.

Allow the system to control when the soft keyboard is shown.

ShowModeHidden
Obsolete.

Never show the soft keyboard.

ShowModeIgnoreHardKeyboard
Obsolete.

Allow the soft keyboard to be shown, even if a hard keyboard is connected

StatusBarService

Use with #getSystemService(String) to retrieve a android.app.StatusBarManager for interacting with the status bar and quick settings.

(Inherited from Context)
StopForegroundDetach
Obsolete.

Selector for #stopForeground(int): if set, the notification previously supplied to #startForeground will be detached from the service's lifecycle.

(Inherited from Service)
StopForegroundLegacy

Selector for #stopForeground(int): equivalent to passing false to the legacy API #stopForeground(boolean).

(Inherited from Service)
StopForegroundRemove
Obsolete.

Selector for #stopForeground(int): if supplied, the notification previously supplied to #startForeground will be cancelled and removed from display.

(Inherited from Service)
StorageService

Use with #getSystemService(String) to retrieve a android.os.storage.StorageManager for accessing system storage functions.

(Inherited from Context)
StorageStatsService

Use with #getSystemService(String) to retrieve a android.app.usage.StorageStatsManager for accessing system storage statistics.

(Inherited from Context)
SystemHealthService

Use with #getSystemService(String) to retrieve a android.os.health.SystemHealthManager for accessing system health (battery, power, memory, etc) metrics.

(Inherited from Context)
TelecomService

Use with #getSystemService(String) to retrieve a android.telecom.TelecomManager to manage telecom-related features of the device.

(Inherited from Context)
TelephonyImsService

Use with #getSystemService(String) to retrieve an android.telephony.ims.ImsManager.

(Inherited from Context)
TelephonyService

Use with #getSystemService(String) to retrieve a android.telephony.TelephonyManager for handling management the telephony features of the device.

(Inherited from Context)
TelephonySubscriptionService

Use with #getSystemService(String) to retrieve a android.telephony.SubscriptionManager for handling management the telephony subscriptions of the device.

(Inherited from Context)
TextClassificationService

Use with #getSystemService(String) to retrieve a TextClassificationManager for text classification services.

(Inherited from Context)
TextServicesManagerService

Use with #getSystemService(String) to retrieve a android.view.textservice.TextServicesManager for accessing text services.

(Inherited from Context)
TvInputService

Use with #getSystemService(String) to retrieve a android.media.tv.TvInputManager for interacting with TV inputs on the device.

(Inherited from Context)
TvInteractiveAppService

Use with #getSystemService(String) to retrieve a android.media.tv.interactive.TvInteractiveAppManager for interacting with TV interactive applications on the device.

(Inherited from Context)
UiModeService

Use with #getSystemService(String) to retrieve a android.app.UiModeManager for controlling UI modes.

(Inherited from Context)
UsageStatsService

Use with #getSystemService(String) to retrieve a android.app.usage.UsageStatsManager for querying device usage stats.

(Inherited from Context)
UsbService

Use with #getSystemService(String) to retrieve a android.hardware.usb.UsbManager for access to USB devices (as a USB host) and for controlling this device's behavior as a USB device.

(Inherited from Context)
UserService

Use with #getSystemService(String) to retrieve a android.os.UserManager for managing users on devices that support multiple users.

(Inherited from Context)
VibratorManagerService

Use with #getSystemService(String) to retrieve a android.os.VibratorManager for accessing the device vibrators, interacting with individual ones and playing synchronized effects on multiple vibrators.

(Inherited from Context)
VibratorService

Use with #getSystemService(String) to retrieve a android.os.Vibrator for interacting with the vibration hardware.

(Inherited from Context)
VirtualDeviceService

Use with #getSystemService(String) to retrieve a android.companion.virtual.VirtualDeviceManager for managing virtual devices.

(Inherited from Context)
VpnManagementService

Use with #getSystemService(String) to retrieve a android.net.VpnManager to manage profiles for the platform built-in VPN.

(Inherited from Context)
WallpaperService

Use with #getSystemService(String) to retrieve a com.

(Inherited from Context)
WifiAwareService

Use with #getSystemService(String) to retrieve a android.net.wifi.aware.WifiAwareManager for handling management of Wi-Fi Aware.

(Inherited from Context)
WifiP2pService

Use with #getSystemService(String) to retrieve a android.net.wifi.p2p.WifiP2pManager for handling management of Wi-Fi peer-to-peer connections.

(Inherited from Context)
WifiRttRangingService

Use with #getSystemService(String) to retrieve a android.net.wifi.rtt.WifiRttManager for ranging devices with wifi.

(Inherited from Context)
WifiService

Use with #getSystemService(String) to retrieve a android.net.wifi.WifiManager for handling management of Wi-Fi access.

(Inherited from Context)
WindowService

Use with #getSystemService(String) to retrieve a android.view.WindowManager for accessing the system's window manager.

(Inherited from Context)

Properties

AccessibilityButtonController

Returns the controller for the accessibility button within the system's navigation area.

Application

Return the application that owns this service.

(Inherited from Service)
ApplicationContext

Return the context of the single, global Application object of the current process.

(Inherited from ContextWrapper)
ApplicationInfo

Return the full application info for this context's package.

(Inherited from ContextWrapper)
Assets

Return an AssetManager instance for your application's package.

(Inherited from ContextWrapper)
AttributionSource (Inherited from Context)
AttributionTag

Attribution can be used in complex apps to logically separate parts of the app.

(Inherited from Context)
BaseContext (Inherited from ContextWrapper)
CacheDir

Returns the absolute path to the application specific cache directory on the filesystem.

(Inherited from ContextWrapper)
Class

Returns the runtime class of this Object.

(Inherited from Object)
ClassLoader

Return a class loader you can use to retrieve classes in this package.

(Inherited from ContextWrapper)
CodeCacheDir

Returns the absolute path to the application specific cache directory on the filesystem designed for storing cached code.

(Inherited from ContextWrapper)
ContentResolver

Return a ContentResolver instance for your application's package.

(Inherited from ContextWrapper)
DataDir (Inherited from ContextWrapper)
DeviceId

Gets the device ID this context is associated with.

(Inherited from Context)
Display

Get the display this context is associated with.

(Inherited from Context)
ExternalCacheDir

Returns the absolute path to the directory on the primary external filesystem (that is somewhere on ExternalStorageDirectory where the application can place cache files it owns.

(Inherited from ContextWrapper)
FilesDir

Returns the absolute path to the directory on the filesystem where files created with OpenFileOutput(String, FileCreationMode) are stored.

(Inherited from ContextWrapper)
FingerprintGestureController

Get the controller for fingerprint gestures.

ForegroundServiceType

If the service has become a foreground service by calling #startForeground(int, Notification) or #startForeground(int, Notification, int), #getForegroundServiceType() returns the current foreground service type.

(Inherited from Service)
Handle

The handle to the underlying Android instance.

(Inherited from Object)
InputMethod

Returns the InputMethod instance after the system calls #onCreateInputMethod(), which may be used to input text or get editable text selection change notifications.

IsCacheEnabled

Returns true if the cache is enabled.

IsDeviceProtectedStorage (Inherited from ContextWrapper)
IsRestricted

Indicates whether this Context is restricted.

(Inherited from Context)
IsUiContext

Returns true if the context is a UI context which can access UI components such as WindowManager, android.view.LayoutInflater LayoutInflater or android.app.WallpaperManager WallpaperManager.

(Inherited from Context)
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
MainExecutor

Return an Executor that will run enqueued tasks on the main thread associated with this context.

(Inherited from Context)
MainLooper

Return the Looper for the main thread of the current process.

(Inherited from ContextWrapper)
NoBackupFilesDir

Returns the absolute path to the directory on the filesystem similar to FilesDir.

(Inherited from ContextWrapper)
ObbDir

Return the primary external storage directory where this application's OBB files (if there are any) can be found.

(Inherited from ContextWrapper)
OpPackageName

Return the package name that should be used for android.app.AppOpsManager calls from this context, so that app ops manager's uid verification will work with the name.

(Inherited from Context)
PackageCodePath

Return the full path to this context's primary Android package.

(Inherited from ContextWrapper)
PackageManager

Return PackageManager instance to find global package information.

(Inherited from ContextWrapper)
PackageName

Return the name of this application's package.

(Inherited from ContextWrapper)
PackageResourcePath

Return the full path to this context's primary Android package.

(Inherited from ContextWrapper)
Params

Return the set of parameters which this Context was created with, if it was created via #createContext(ContextParams).

(Inherited from Context)
PeerReference (Inherited from Object)
Resources

Return a Resources instance for your application's package.

(Inherited from ContextWrapper)
RootInActiveWindow

Gets the root node in the currently active window if this service can retrieve window content.

ServiceInfo

Gets the an AccessibilityServiceInfo describing this AccessibilityService.

SystemActions

Returns a list of system actions available in the system right now.

Theme

Return the Theme object associated with this Context.

(Inherited from ContextWrapper)
ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

Wallpaper (Inherited from ContextWrapper)
WallpaperDesiredMinimumHeight (Inherited from ContextWrapper)
WallpaperDesiredMinimumWidth (Inherited from ContextWrapper)
Windows

Gets the windows on the screen of the default display.

WindowsOnAllDisplays

Gets the windows on the screen of all displays.

Methods

AttachAccessibilityOverlayToDisplay(Int32, SurfaceControl)

Attaches a android.view.SurfaceControl containing an accessibility overlay to the specified display.

AttachAccessibilityOverlayToWindow(Int32, SurfaceControl)

Attaches an accessibility overlay android.view.SurfaceControl to the specified window.

AttachBaseContext(Context)

Set the base context for this ContextWrapper.

(Inherited from ContextWrapper)
BindService(Intent, Bind, IExecutor, IServiceConnection)

Same as #bindService(Intent, ServiceConnection, int) bindService(Intent, ServiceConnection, int) with executor to control ServiceConnection callbacks.

(Inherited from Context)
BindService(Intent, Context+BindServiceFlags, IExecutor, IServiceConnection) (Inherited from Context)
BindService(Intent, IServiceConnection, Bind)

Connect to an application service, creating it if needed.

(Inherited from ContextWrapper)
BindService(Intent, IServiceConnection, Context+BindServiceFlags) (Inherited from Context)
BindServiceAsUser(Intent, IServiceConnection, Context+BindServiceFlags, UserHandle) (Inherited from Context)
BindServiceAsUser(Intent, IServiceConnection, Int32, UserHandle)

Binds to a service in the given user in the same manner as #bindService.

(Inherited from Context)
CheckCallingOrSelfPermission(String)

Determine whether the calling process of an IPC or you have been granted a particular permission.

(Inherited from ContextWrapper)
CheckCallingOrSelfUriPermission(Uri, ActivityFlags)

Determine whether the calling process of an IPC or you has been granted permission to access a specific URI.

(Inherited from ContextWrapper)
CheckCallingOrSelfUriPermissions(IList<Uri>, Int32)

Determine whether the calling process of an IPC <em>or you</em> has been granted permission to access a list of URIs.

(Inherited from Context)
CheckCallingPermission(String)

Determine whether the calling process of an IPC you are handling has been granted a particular permission.

(Inherited from ContextWrapper)
CheckCallingUriPermission(Uri, ActivityFlags)

Determine whether the calling process and user ID has been granted permission to access a specific URI.

(Inherited from ContextWrapper)
CheckCallingUriPermissions(IList<Uri>, Int32)

Determine whether the calling process and user ID has been granted permission to access a list of URIs.

(Inherited from Context)
CheckPermission(String, Int32, Int32)

Determine whether the given permission is allowed for a particular process and user ID running in the system.

(Inherited from ContextWrapper)
CheckSelfPermission(String) (Inherited from ContextWrapper)
CheckUriPermission(Uri, Int32, Int32, ActivityFlags)

Determine whether a particular process and user ID has been granted permission to access a specific URI.

(Inherited from ContextWrapper)
CheckUriPermission(Uri, String, String, Int32, Int32, ActivityFlags)

Check both a Uri and normal permission.

(Inherited from ContextWrapper)
CheckUriPermissions(IList<Uri>, Int32, Int32, Int32)

Determine whether a particular process and user ID has been granted permission to access a list of URIs.

(Inherited from Context)
ClearCache()

Clears the cache.

ClearCachedSubtree(AccessibilityNodeInfo)

Invalidates node and its subtree in the cache.

ClearWallpaper()
Obsolete.
(Inherited from ContextWrapper)
Clone()

Creates and returns a copy of this object.

(Inherited from Object)
CreateAttributionContext(String)

Return a new Context object for the current Context but attribute to a different tag.

(Inherited from Context)
CreateConfigurationContext(Configuration)

Return a new Context object for the current Context but whose resources are adjusted to match the given Configuration.

(Inherited from ContextWrapper)
CreateContext(ContextParams)

Creates a context with specific properties and behaviors.

(Inherited from Context)
CreateContextForSplit(String) (Inherited from ContextWrapper)
CreateDeviceContext(Int32)

Returns a new Context object from the current context but with device association given by the deviceId.

(Inherited from Context)
CreateDeviceProtectedStorageContext() (Inherited from ContextWrapper)
CreateDisplayContext(Display)

Return a new Context object for the current Context but whose resources are adjusted to match the metrics of the given Display.

(Inherited from ContextWrapper)
CreatePackageContext(String, PackageContextFlags)

Return a new Context object for the given application name.

(Inherited from ContextWrapper)
CreateWindowContext(Display, Int32, Bundle)

Creates a Context for a non-android.app.Activity activity window on the given Display.

(Inherited from Context)
CreateWindowContext(Int32, Bundle)

Creates a Context for a non-activity window.

(Inherited from Context)
DatabaseList()

Returns an array of strings naming the private databases associated with this Context's application package.

(Inherited from ContextWrapper)
DeleteDatabase(String)

Delete an existing private SQLiteDatabase associated with this Context's application package.

(Inherited from ContextWrapper)
DeleteFile(String)

Delete the given private file associated with this Context's application package.

(Inherited from ContextWrapper)
DeleteSharedPreferences(String) (Inherited from ContextWrapper)
DisableSelf()

Disables the service.

DispatchGesture(GestureDescription, AccessibilityService+GestureResultCallback, Handler)

Dispatch a gesture to the touch screen.

Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
Dump(FileDescriptor, PrintWriter, String[])

Print the Service's state into the given stream.

(Inherited from Service)
EnforceCallingOrSelfPermission(String, String)

If neither you nor the calling process of an IPC you are handling has been granted a particular permission, throw a SecurityException.

(Inherited from ContextWrapper)
EnforceCallingOrSelfUriPermission(Uri, ActivityFlags, String)

If the calling process of an IPC or you has not been granted permission to access a specific URI, throw SecurityException.

(Inherited from ContextWrapper)
EnforceCallingPermission(String, String)

If the calling process of an IPC you are handling has not been granted a particular permission, throw a SecurityException.

(Inherited from ContextWrapper)
EnforceCallingUriPermission(Uri, ActivityFlags, String)

If the calling process and user ID has not been granted permission to access a specific URI, throw SecurityException.

(Inherited from ContextWrapper)
EnforcePermission(String, Int32, Int32, String)

If the given permission is not allowed for a particular process and user ID running in the system, throw a SecurityException.

(Inherited from ContextWrapper)
EnforceUriPermission(Uri, Int32, Int32, ActivityFlags, String)

If a particular process and user ID has not been granted permission to access a specific URI, throw SecurityException.

(Inherited from ContextWrapper)
EnforceUriPermission(Uri, String, String, Int32, Int32, ActivityFlags, String)

Enforce both a Uri and normal permission.

(Inherited from ContextWrapper)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
FileList()

Returns an array of strings naming the private files associated with this Context's application package.

(Inherited from ContextWrapper)
FindFocus(NodeFocus)

Find the view that has the specified focus type.

GetAccessibilityButtonController(Int32)

Returns the controller of specified logical display for the accessibility button within the system's navigation area.

GetColor(Int32)

Returns a color associated with a particular resource ID and styled for the current theme.

(Inherited from Context)
GetColorStateList(Int32)

Returns a color state list associated with a particular resource ID and styled for the current theme.

(Inherited from Context)
GetDatabasePath(String) (Inherited from ContextWrapper)
GetDir(String, FileCreationMode)

Retrieve, creating if needed, a new directory in which the application can place its own custom data files.

(Inherited from ContextWrapper)
GetDrawable(Int32)

Returns a drawable object associated with a particular resource ID and styled for the current theme.

(Inherited from Context)
GetExternalCacheDirs()

Returns absolute paths to application-specific directories on all external storage devices where the application can place cache files it owns.

(Inherited from ContextWrapper)
GetExternalFilesDir(String)

Returns the absolute path to the directory on the primary external filesystem (that is somewhere on ExternalStorageDirectory) where the application can place persistent files it owns.

(Inherited from ContextWrapper)
GetExternalFilesDirs(String)

Returns absolute paths to application-specific directories on all external storage devices where the application can place persistent files it owns.

(Inherited from ContextWrapper)
GetExternalMediaDirs()
Obsolete.

Returns absolute paths to application-specific directories on all external storage devices where the application can place media files.

(Inherited from ContextWrapper)
GetFileStreamPath(String)

Returns the absolute path on the filesystem where a file created with OpenFileOutput(String, FileCreationMode) is stored.

(Inherited from ContextWrapper)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
GetMagnificationController()

Returns the magnification controller, which may be used to query and modify the state of display magnification.

GetObbDirs()

Returns absolute paths to application-specific directories on all external storage devices where the application's OBB files (if there are any) can be found.

(Inherited from ContextWrapper)
GetRootInActiveWindow(Int32)

Gets the root node in the currently active window if this service can retrieve window content.

GetSharedPreferences(String, FileCreationMode)

Retrieve and hold the contents of the preferences file 'name', returning a SharedPreferences through which you can retrieve and modify its values.

(Inherited from ContextWrapper)
GetSoftKeyboardController()

Returns the soft keyboard controller, which may be used to query and modify the soft keyboard show mode.

GetString(Int32, Object[])

Returns a localized string from the application's package's default string table.

(Inherited from Context)
GetString(Int32)

Returns a localized string from the application's package's default string table.

(Inherited from Context)
GetSystemService(Class)

Return the handle to a system-level service by class.

(Inherited from Context)
GetSystemService(String)

Return the handle to a system-level service by name.

(Inherited from ContextWrapper)
GetSystemServiceName(Class) (Inherited from ContextWrapper)
GetText(Int32)

Return a localized, styled CharSequence from the application's package's default string table.

(Inherited from Context)
GetTextFormatted(Int32)

Return a localized, styled CharSequence from the application's package's default string table.

(Inherited from Context)
GetTouchInteractionController(Int32)

Returns the touch interaction controller for the specified logical display, which may be used to detect gestures and otherwise control touch interactions.

GrantUriPermission(String, Uri, ActivityFlags)

Grant permission to access a specific Uri to another package, regardless of whether that package has general permission to access the Uri's content provider.

(Inherited from ContextWrapper)
IsNodeInCache(AccessibilityNodeInfo)

Checks if node is in the cache.

JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
MoveDatabaseFrom(Context, String) (Inherited from ContextWrapper)
MoveSharedPreferencesFrom(Context, String) (Inherited from ContextWrapper)
Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
ObtainStyledAttributes(IAttributeSet, Int32[], Int32, Int32)

Retrieve styled attribute information in this Context's theme.

(Inherited from Context)
ObtainStyledAttributes(IAttributeSet, Int32[])

Retrieve styled attribute information in this Context's theme.

(Inherited from Context)
ObtainStyledAttributes(Int32, Int32[])

Retrieve styled attribute information in this Context's theme.

(Inherited from Context)
ObtainStyledAttributes(Int32[])

Retrieve styled attribute information in this Context's theme.

(Inherited from Context)
OnAccessibilityEvent(AccessibilityEvent)

Callback for android.view.accessibility.AccessibilityEvents.

OnBind(Intent)

Implement to return the implementation of the internal accessibility service interface.

OnConfigurationChanged(Configuration)

Called by the system when the device configuration changes while your component is running.

(Inherited from Service)
OnCreate()

Called by the system when the service is first created.

(Inherited from Service)
OnCreateInputMethod()

The default implementation returns our default InputMethod.

OnDestroy()

Called by the system to notify a Service that it is no longer used and is being removed.

(Inherited from Service)
OnGesture(AccessibilityGestureEvent)

Called by the system when the user performs a specific gesture on the specific touch screen.

OnGesture(Int32)

Called by #onGesture(AccessibilityGestureEvent) when the user performs a specific gesture on the default display.

OnInterrupt()

Callback for interrupting the accessibility feedback.

OnKeyEvent(KeyEvent)

Callback that allows an accessibility service to observe the key events before they are passed to the rest of the system.

OnLowMemory()

This is called when the overall system is running low on memory, and actively running processes should trim their memory usage.

(Inherited from Service)
OnMotionEvent(MotionEvent)

Callback that allows an accessibility service to observe generic MotionEvents.

OnRebind(Intent)

Called when new clients have connected to the service, after it had previously been notified that all had disconnected in its #onUnbind.

(Inherited from Service)
OnServiceConnected()

This method is a part of the AccessibilityService lifecycle and is called after the system has successfully bound to the service.

OnStart(Intent, Int32)
Obsolete.

This member is deprecated.

(Inherited from Service)
OnStartCommand(Intent, StartCommandFlags, Int32)

Called by the system every time a client explicitly starts the service by calling android.content.Context#startService, providing the arguments it supplied and a unique integer token representing the start request.

(Inherited from Service)
OnSystemActionsChanged()

This is called when the system action list is changed.

OnTaskRemoved(Intent)

This is called if the service is currently running and the user has removed a task that comes from the service's application.

(Inherited from Service)
OnTimeout(Int32)

Callback called on timeout for ServiceInfo#FOREGROUND_SERVICE_TYPE_SHORT_SERVICE.

(Inherited from Service)
OnTrimMemory(TrimMemory)

Called when the operating system has determined that it is a good time for a process to trim unneeded memory from its process.

(Inherited from Service)
OnUnbind(Intent)

Called when all clients have disconnected from a particular interface published by the service.

(Inherited from Service)
OpenFileInput(String)

Open a private file associated with this Context's application package for reading.

(Inherited from ContextWrapper)
OpenFileOutput(String, FileCreationMode)

Open a private file associated with this Context's application package for writing.

(Inherited from ContextWrapper)
OpenOrCreateDatabase(String, FileCreationMode, SQLiteDatabase+ICursorFactory, IDatabaseErrorHandler)

Open a new private SQLiteDatabase associated with this Context's application package.

(Inherited from ContextWrapper)
OpenOrCreateDatabase(String, FileCreationMode, SQLiteDatabase+ICursorFactory)

Open a new private SQLiteDatabase associated with this Context's application package.

(Inherited from ContextWrapper)
PeekWallpaper()
Obsolete.
(Inherited from ContextWrapper)
PerformGlobalAction(GlobalAction)

Performs a global action.

RegisterComponentCallbacks(IComponentCallbacks)

Add a new ComponentCallbacks to the base application of the Context, which will be called at the same times as the ComponentCallbacks methods of activities and other components are called.

(Inherited from Context)
RegisterDeviceIdChangeListener(IExecutor, IIntConsumer)

Adds a new device ID changed listener to the Context, which will be called when the device association is changed by the system.

(Inherited from Context)
RegisterReceiver(BroadcastReceiver, IntentFilter, ActivityFlags)
Obsolete.
(Inherited from ContextWrapper)
RegisterReceiver(BroadcastReceiver, IntentFilter, ReceiverFlags) (Inherited from Context)
RegisterReceiver(BroadcastReceiver, IntentFilter, String, Handler, ActivityFlags)
Obsolete.
(Inherited from ContextWrapper)
RegisterReceiver(BroadcastReceiver, IntentFilter, String, Handler, ReceiverFlags) (Inherited from Context)
RegisterReceiver(BroadcastReceiver, IntentFilter, String, Handler)

Register to receive intent broadcasts, to run in the context of scheduler.

(Inherited from ContextWrapper)
RegisterReceiver(BroadcastReceiver, IntentFilter)

Register a BroadcastReceiver to be run in the main activity thread.

(Inherited from ContextWrapper)
RemoveStickyBroadcast(Intent)
Obsolete.
(Inherited from ContextWrapper)
RemoveStickyBroadcastAsUser(Intent, UserHandle)
Obsolete.
(Inherited from ContextWrapper)
RevokeSelfPermissionOnKill(String)

Triggers the asynchronous revocation of a runtime permission.

(Inherited from Context)
RevokeSelfPermissionsOnKill(ICollection<String>)

Triggers the revocation of one or more permissions for the calling package.

(Inherited from Context)
RevokeUriPermission(String, Uri, ActivityFlags) (Inherited from ContextWrapper)
RevokeUriPermission(Uri, ActivityFlags)

Remove all permissions to access a particular content provider Uri that were previously added with M:Android.Content.Context.GrantUriPermission(System.String,Android.Net.Uri,Android.Net.Uri).

(Inherited from ContextWrapper)
SendBroadcast(Intent, String, Bundle)

Broadcast the given intent to all interested BroadcastReceivers, allowing an optional required permission to be enforced.

(Inherited from Context)
SendBroadcast(Intent, String)

Broadcast the given intent to all interested BroadcastReceivers, allowing an optional required permission to be enforced.

(Inherited from ContextWrapper)
SendBroadcast(Intent)

Broadcast the given intent to all interested BroadcastReceivers.

(Inherited from ContextWrapper)
SendBroadcastAsUser(Intent, UserHandle, String)

Version of SendBroadcast(Intent, String) that allows you to specify the user the broadcast will be sent to.

(Inherited from ContextWrapper)
SendBroadcastAsUser(Intent, UserHandle)

Version of SendBroadcast(Intent) that allows you to specify the user the broadcast will be sent to.

(Inherited from ContextWrapper)
SendBroadcastWithMultiplePermissions(Intent, String[])

Broadcast the given intent to all interested BroadcastReceivers, allowing an array of required permissions to be enforced.

(Inherited from Context)
SendOrderedBroadcast(Intent, Int32, String, String, BroadcastReceiver, Handler, String, Bundle, Bundle) (Inherited from ContextWrapper)
SendOrderedBroadcast(Intent, String, BroadcastReceiver, Handler, Result, String, Bundle)

Version of SendBroadcast(Intent) that allows you to receive data back from the broadcast.

(Inherited from ContextWrapper)
SendOrderedBroadcast(Intent, String, Bundle, BroadcastReceiver, Handler, Result, String, Bundle)

Version of #sendBroadcast(Intent) that allows you to receive data back from the broadcast.

(Inherited from Context)
SendOrderedBroadcast(Intent, String, Bundle)

Broadcast the given intent to all interested BroadcastReceivers, delivering them one at a time to allow more preferred receivers to consume the broadcast before it is delivered to less preferred receivers.

(Inherited from Context)
SendOrderedBroadcast(Intent, String, String, BroadcastReceiver, Handler, Result, String, Bundle)

Version of #sendOrderedBroadcast(Intent, String, BroadcastReceiver, Handler, int, String, Bundle) that allows you to specify the App Op to enforce restrictions on which receivers the broadcast will be sent to.

(Inherited from Context)
SendOrderedBroadcast(Intent, String) (Inherited from ContextWrapper)
SendOrderedBroadcastAsUser(Intent, UserHandle, String, BroadcastReceiver, Handler, Result, String, Bundle) (Inherited from ContextWrapper)
SendStickyBroadcast(Intent, Bundle)

Perform a #sendBroadcast(Intent) that is "sticky," meaning the Intent you are sending stays around after the broadcast is complete, so that others can quickly retrieve that data through the return value of #registerReceiver(BroadcastReceiver, IntentFilter).

(Inherited from Context)
SendStickyBroadcast(Intent)
Obsolete.

Perform a #sendBroadcast(Intent) that is "sticky," meaning the Intent you are sending stays around after the broadcast is complete, so that others can quickly retrieve that data through the return value of #registerReceiver(BroadcastReceiver, IntentFilter).

(Inherited from ContextWrapper)
SendStickyBroadcastAsUser(Intent, UserHandle)
Obsolete.
(Inherited from ContextWrapper)
SendStickyOrderedBroadcast(Intent, BroadcastReceiver, Handler, Result, String, Bundle)
Obsolete.
(Inherited from ContextWrapper)
SendStickyOrderedBroadcastAsUser(Intent, UserHandle, BroadcastReceiver, Handler, Result, String, Bundle)
Obsolete.
(Inherited from ContextWrapper)
SetAccessibilityFocusAppearance(Int32, Color)

Sets the strokeWidth and color of the accessibility focus rectangle.

SetAnimationScale(Single)

Sets the system settings values that control the scaling factor for animations.

SetCacheEnabled(Boolean)

Sets the cache status.

SetForeground(Boolean)

This member is deprecated.

(Inherited from Service)
SetGestureDetectionPassthroughRegion(Int32, Region)

When AccessibilityServiceInfo#FLAG_REQUEST_TOUCH_EXPLORATION_MODE is enabled, this function requests that touch interactions starting in the specified region of the screen bypass the gesture detector.

SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetServiceInfo(AccessibilityServiceInfo)

Sets the AccessibilityServiceInfo that describes this service.

SetTheme(Int32)

Set the base theme for this context.

(Inherited from ContextWrapper)
SetTouchExplorationPassthroughRegion(Int32, Region)

When AccessibilityServiceInfo#FLAG_REQUEST_TOUCH_EXPLORATION_MODE is enabled, this function requests that touch interactions starting in the specified region of the screen bypass the touch explorer and go straight to the view hierarchy.

SetWallpaper(Bitmap)
Obsolete.
(Inherited from ContextWrapper)
SetWallpaper(Stream)
Obsolete.
(Inherited from ContextWrapper)
StartActivities(Intent[], Bundle)

Launch multiple new activities.

(Inherited from ContextWrapper)
StartActivities(Intent[])

Same as StartActivities(Intent[], Bundle) with no options specified.

(Inherited from ContextWrapper)
StartActivity(Intent, Bundle)

Launch a new activity.

(Inherited from ContextWrapper)
StartActivity(Intent)

Same as StartActivity(Intent, Bundle) with no options specified.

(Inherited from ContextWrapper)
StartActivity(Type) (Inherited from Context)
StartForeground(Int32, Notification, ForegroundService)

An overloaded version of #startForeground(int, Notification) with additional foregroundServiceType parameter.

(Inherited from Service)
StartForeground(Int32, Notification)

If your service is started (running through Context#startService(Intent)), then also make this service run in the foreground, supplying the ongoing notification to be shown to the user while in this state.

(Inherited from Service)
StartForegroundService(Intent) (Inherited from ContextWrapper)
StartInstrumentation(ComponentName, String, Bundle)

Start executing an Instrumentation class.

(Inherited from ContextWrapper)
StartIntentSender(IntentSender, Intent, ActivityFlags, ActivityFlags, Int32, Bundle)

Like StartActivity(Intent, Bundle), but taking a IntentSender to start.

(Inherited from ContextWrapper)
StartIntentSender(IntentSender, Intent, ActivityFlags, ActivityFlags, Int32) (Inherited from ContextWrapper)
StartService(Intent)

Request that a given application service be started.

(Inherited from ContextWrapper)
StopForeground(Boolean)

Legacy version of #stopForeground(int).

(Inherited from Service)
StopForeground(StopForegroundFlags)

Remove this service from foreground state, allowing it to be killed if more memory is needed.

(Inherited from Service)
StopSelf()

Stop the service, if it was previously started.

(Inherited from Service)
StopSelf(Int32)

Old version of #stopSelfResult that doesn't return a result.

(Inherited from Service)
StopSelfResult(Int32)

Stop the service if the most recent time it was started was <var>startId</var>.

(Inherited from Service)
StopService(Intent)

Request that a given application service be stopped.

(Inherited from ContextWrapper)
TakeScreenshot(Int32, IExecutor, AccessibilityService+ITakeScreenshotCallback)

Takes a screenshot of the specified display and returns it via an AccessibilityService.ScreenshotResult.

TakeScreenshotOfWindow(Int32, IExecutor, AccessibilityService+ITakeScreenshotCallback)
ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
UnbindService(IServiceConnection)

Disconnect from an application service.

(Inherited from ContextWrapper)
UnregisterComponentCallbacks(IComponentCallbacks)

Remove a ComponentCallbacks object that was previously registered with #registerComponentCallbacks(ComponentCallbacks).

(Inherited from Context)
UnregisterDeviceIdChangeListener(IIntConsumer)

Removes a device ID changed listener from the Context.

(Inherited from Context)
UnregisterFromRuntime() (Inherited from Object)
UnregisterReceiver(BroadcastReceiver)

Unregister a previously registered BroadcastReceiver.

(Inherited from ContextWrapper)
UpdateServiceGroup(IServiceConnection, Int32, Int32)

For a service previously bound with #bindService or a related method, change how the system manages that service's process in relation to other processes.

(Inherited from Context)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to