Stay organized with collections
Save and categorize content based on your preferences.
DevicePolicyManager.OnClearApplicationUserDataListener
public
static
interface
DevicePolicyManager.OnClearApplicationUserDataListener
android.app.admin.DevicePolicyManager.OnClearApplicationUserDataListener
|
Callback used in DevicePolicyManager.clearApplicationUserData(ComponentName, String, Executor, OnClearApplicationUserDataListener)
to indicate that the clearing of an application's user data is done.
Summary
Public methods
onApplicationUserDataCleared
public abstract void onApplicationUserDataCleared (String packageName,
boolean succeeded)
Method invoked when clearing the application user data has completed.
Parameters |
packageName |
String : The name of the package which had its user data cleared. |
succeeded |
boolean : Whether the clearing succeeded. Clearing fails for device administrator
apps and protected system packages. |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[null,null,["Last updated 2025-02-10 UTC."],[],[],null,["# DevicePolicyManager.OnClearApplicationUserDataListener\n\nAdded in [API level 28](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nDevicePolicyManager.OnClearApplicationUserDataListener\n======================================================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/app/admin/DevicePolicyManager.OnClearApplicationUserDataListener \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\nstatic\n\n\ninterface\nDevicePolicyManager.OnClearApplicationUserDataListener\n`\n\n\n`\n\n\n`\n\n|--------------------------------------------------------------------------|\n| android.app.admin.DevicePolicyManager.OnClearApplicationUserDataListener |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nCallback used in [DevicePolicyManager.clearApplicationUserData(ComponentName, String, Executor, OnClearApplicationUserDataListener)](/reference/android/app/admin/DevicePolicyManager#clearApplicationUserData(android.content.ComponentName,%20java.lang.String,%20java.util.concurrent.Executor,%20android.app.admin.DevicePolicyManager.OnClearApplicationUserDataListener))\nto indicate that the clearing of an application's user data is done.\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract void` | ` `[onApplicationUserDataCleared](/reference/android/app/admin/DevicePolicyManager.OnClearApplicationUserDataListener#onApplicationUserDataCleared(java.lang.String,%20boolean))`(`[String](/reference/java/lang/String)` packageName, boolean succeeded) ` Method invoked when clearing the application user data has completed. |\n\nPublic methods\n--------------\n\n### onApplicationUserDataCleared\n\nAdded in [API level 28](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void onApplicationUserDataCleared (String packageName, \n boolean succeeded)\n```\n\nMethod invoked when clearing the application user data has completed.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|---------------|-------------------------------------------------------------------------------------------------------------------------------|\n| `packageName` | `String`: The name of the package which had its user data cleared. \u003cbr /\u003e |\n| `succeeded` | `boolean`: Whether the clearing succeeded. Clearing fails for device administrator apps and protected system packages. \u003cbr /\u003e |"]]