Merge "Remove @Deprecated && @removed methods from DevicePolicyManager."
diff --git a/api/removed.txt b/api/removed.txt
index 7630262..7b1d241 100644
--- a/api/removed.txt
+++ b/api/removed.txt
@@ -23,15 +23,6 @@
}
-package android.app.admin {
-
- public class DevicePolicyManager {
- method @Deprecated @Nullable public android.os.UserHandle createAndInitializeUser(@NonNull android.content.ComponentName, String, String, @NonNull android.content.ComponentName, android.os.Bundle);
- method @Deprecated @Nullable public android.os.UserHandle createUser(@NonNull android.content.ComponentName, String);
- }
-
-}
-
package android.app.slice {
public final class Slice implements android.os.Parcelable {
diff --git a/api/system-removed.txt b/api/system-removed.txt
index 3e26a9b..07b8969 100644
--- a/api/system-removed.txt
+++ b/api/system-removed.txt
@@ -23,15 +23,6 @@
}
-package android.app.admin {
-
- public class DevicePolicyManager {
- method @Deprecated @Nullable public String getDeviceInitializerApp();
- method @Deprecated @Nullable public android.content.ComponentName getDeviceInitializerComponent();
- }
-
-}
-
package android.app.backup {
public class RestoreSession {
diff --git a/core/java/android/app/admin/DevicePolicyManager.java b/core/java/android/app/admin/DevicePolicyManager.java
index 441ff6b..5624ba5 100644
--- a/core/java/android/app/admin/DevicePolicyManager.java
+++ b/core/java/android/app/admin/DevicePolicyManager.java
@@ -6066,30 +6066,6 @@
/**
* @hide
- * @deprecated Do not use
- * @removed
- */
- @Deprecated
- @SystemApi
- @SuppressLint("Doclava125")
- public @Nullable String getDeviceInitializerApp() {
- return null;
- }
-
- /**
- * @hide
- * @deprecated Do not use
- * @removed
- */
- @Deprecated
- @SystemApi
- @SuppressLint("Doclava125")
- public @Nullable ComponentName getDeviceInitializerComponent() {
- return null;
- }
-
- /**
- * @hide
* @deprecated Use #ACTION_SET_PROFILE_OWNER
* Sets the given component as an active admin and registers the package as the profile
* owner for this user. The package must already be installed and there shouldn't be
@@ -7394,60 +7370,6 @@
}
/**
- * Called by a device owner to create a user with the specified name. The UserHandle returned
- * by this method should not be persisted as user handles are recycled as users are removed and
- * created. If you need to persist an identifier for this user, use
- * {@link UserManager#getSerialNumberForUser}.
- *
- * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
- * @param name the user's name
- * @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#M}
- * @removed From {@link android.os.Build.VERSION_CODES#N}
- */
- @Deprecated
- public @Nullable UserHandle createUser(@NonNull ComponentName admin, String name) {
- return null;
- }
-
- /**
- * Called by a device owner to create a user with the specified name. The UserHandle returned
- * by this method should not be persisted as user handles are recycled as users are removed and
- * created. If you need to persist an identifier for this user, use
- * {@link UserManager#getSerialNumberForUser}. The new user will be started in the background
- * immediately.
- *
- * <p> profileOwnerComponent is the {@link DeviceAdminReceiver} to be the profile owner as well
- * as registered as an active admin on the new user. The profile owner package will be
- * installed on the new user if it already is installed on the device.
- *
- * <p>If the optionalInitializeData is not null, then the extras will be passed to the
- * profileOwnerComponent when onEnable is called.
- *
- * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
- * @param name the user's name
- * @param ownerName the human readable name of the organisation associated with this DPM.
- * @param profileOwnerComponent The {@link DeviceAdminReceiver} that will be an active admin on
- * the user.
- * @param adminExtras Extras that will be passed to onEnable of the admin receiver
- * on the new user.
- * @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#M}
- * @removed From {@link android.os.Build.VERSION_CODES#N}
- */
- @Deprecated
- public @Nullable UserHandle createAndInitializeUser(@NonNull ComponentName admin, String name,
- String ownerName, @NonNull ComponentName profileOwnerComponent, Bundle adminExtras) {
- return null;
- }
-
- /**
* Flag used by {@link #createAndManageUser} to skip setup wizard after creating a new user.
*/
public static final int SKIP_SETUP_WIZARD = 0x0001;