diff options
| author | Kenny Guy <kennyguy@google.com> | 2015-06-29 15:12:36 +0100 |
|---|---|---|
| committer | Kenny Guy <kennyguy@google.com> | 2015-06-29 15:11:25 +0000 |
| commit | 14f48e5a937b07c83f7e7a37d0319f84171b692d (patch) | |
| tree | 7c0bc07dcfd6087fbfb001333adb7c3d0f85d12b | |
| parent | e3fc5415ed65ee7ad451069022b5405361aeb2e7 (diff) | |
| download | frameworks_base-14f48e5a937b07c83f7e7a37d0319f84171b692d.zip frameworks_base-14f48e5a937b07c83f7e7a37d0319f84171b692d.tar.gz frameworks_base-14f48e5a937b07c83f7e7a37d0319f84171b692d.tar.bz2 | |
Deprecate APIs for admin to create users.
Bug: 21921868
Change-Id: I0a59c85f6a87928de3df72278d4b65355ff7270f
| -rw-r--r-- | api/current.txt | 4 | ||||
| -rw-r--r-- | api/system-current.txt | 4 | ||||
| -rw-r--r-- | core/java/android/app/admin/DevicePolicyManager.java | 6 |
3 files changed, 10 insertions, 4 deletions
diff --git a/api/current.txt b/api/current.txt index 1f10695..8d6b3b3 100644 --- a/api/current.txt +++ b/api/current.txt @@ -5615,8 +5615,8 @@ package android.app.admin { method public void clearDeviceOwnerApp(java.lang.String); method public void clearPackagePersistentPreferredActivities(android.content.ComponentName, java.lang.String); method public void clearUserRestriction(android.content.ComponentName, java.lang.String); - method public android.os.UserHandle createAndInitializeUser(android.content.ComponentName, java.lang.String, java.lang.String, android.content.ComponentName, android.os.Bundle); - method public android.os.UserHandle createUser(android.content.ComponentName, java.lang.String); + method public deprecated android.os.UserHandle createAndInitializeUser(android.content.ComponentName, java.lang.String, java.lang.String, android.content.ComponentName, android.os.Bundle); + method public deprecated android.os.UserHandle createUser(android.content.ComponentName, java.lang.String); method public void enableSystemApp(android.content.ComponentName, java.lang.String); method public int enableSystemApp(android.content.ComponentName, android.content.Intent); method public java.lang.String[] getAccountTypesWithManagementDisabled(); diff --git a/api/system-current.txt b/api/system-current.txt index 4592370..9784dcb 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -5736,8 +5736,8 @@ package android.app.admin { method public void clearPackagePersistentPreferredActivities(android.content.ComponentName, java.lang.String); method public void clearProfileOwner(android.content.ComponentName); method public void clearUserRestriction(android.content.ComponentName, java.lang.String); - method public android.os.UserHandle createAndInitializeUser(android.content.ComponentName, java.lang.String, java.lang.String, android.content.ComponentName, android.os.Bundle); - method public android.os.UserHandle createUser(android.content.ComponentName, java.lang.String); + method public deprecated android.os.UserHandle createAndInitializeUser(android.content.ComponentName, java.lang.String, java.lang.String, android.content.ComponentName, android.os.Bundle); + method public deprecated android.os.UserHandle createUser(android.content.ComponentName, java.lang.String); method public void enableSystemApp(android.content.ComponentName, java.lang.String); method public int enableSystemApp(android.content.ComponentName, android.content.Intent); method public java.lang.String[] getAccountTypesWithManagementDisabled(); diff --git a/core/java/android/app/admin/DevicePolicyManager.java b/core/java/android/app/admin/DevicePolicyManager.java index d53157b..05fcbbc 100644 --- a/core/java/android/app/admin/DevicePolicyManager.java +++ b/core/java/android/app/admin/DevicePolicyManager.java @@ -3612,7 +3612,10 @@ public class DevicePolicyManager { * @see UserHandle * @return the {@link android.os.UserHandle} object for the created user, or {@code null} if the * user could not be created. + * + * @deprecated From {@link android.os.Build.VERSION_CODES#MNC} */ + @Deprecated public UserHandle createUser(@NonNull ComponentName admin, String name) { try { return mService.createUser(admin, name); @@ -3646,7 +3649,10 @@ public class DevicePolicyManager { * @see UserHandle * @return the {@link android.os.UserHandle} object for the created user, or {@code null} if the * user could not be created. + * + * @deprecated From {@link android.os.Build.VERSION_CODES#MNC} */ + @Deprecated public UserHandle createAndInitializeUser(@NonNull ComponentName admin, String name, String ownerName, @NonNull ComponentName profileOwnerComponent, Bundle adminExtras) { try { |
