Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3c9c96d8 authored by Lenka Trochtova's avatar Lenka Trochtova Committed by Android (Google) Code Review
Browse files

Merge "DevicePolicyManager: make 3 hidden provisioning methods system API."

parents 86c2f957 5291ee73
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -6280,6 +6280,8 @@ package android.app.admin {
    method public boolean isCallerApplicationRestrictionsManagingPackage();
    method public boolean isDeviceManaged();
    method public boolean isDeviceOwnerApp(java.lang.String);
    method public boolean isDeviceProvisioned();
    method public boolean isDeviceProvisioningConfigApplied();
    method public boolean isLockTaskPermitted(java.lang.String);
    method public boolean isManagedProfile(android.content.ComponentName);
    method public boolean isMasterVolumeMuted(android.content.ComponentName);
@@ -6315,6 +6317,7 @@ package android.app.admin {
    method public void setCrossProfileCallerIdDisabled(android.content.ComponentName, boolean);
    method public void setCrossProfileContactsSearchDisabled(android.content.ComponentName, boolean);
    method public void setDeviceOwnerLockScreenInfo(android.content.ComponentName, java.lang.CharSequence);
    method public void setDeviceProvisioningConfigApplied();
    method public void setGlobalSetting(android.content.ComponentName, java.lang.String, java.lang.String);
    method public boolean setKeyguardDisabled(android.content.ComponentName, boolean);
    method public void setKeyguardDisabledFeatures(android.content.ComponentName, int);
+24 −6
Original line number Diff line number Diff line
@@ -6827,10 +6827,13 @@ public class DevicePolicyManager {
    }

    /**
     * Returns whether the device has been provisioned.
     *
     * <p>Not for use by third-party applications.
     *
     * @hide
     * @return whether {@link android.provider.Settings.Global#DEVICE_PROVISIONED} has ever been set
     * to 1.
     */
    @SystemApi
    public boolean isDeviceProvisioned() {
        try {
            return mService.isDeviceProvisioned();
@@ -6840,9 +6843,16 @@ public class DevicePolicyManager {
    }

    /**
     * @hide
      * Writes that the provisioning configuration has been applied.
      *
      * <p>The caller must hold the {@link android.Manifest.permission#MANAGE_USERS}
      * permission.
      *
      * <p>Not for use by third-party applications.
      *
      * @hide
      */
    @SystemApi
    public void setDeviceProvisioningConfigApplied() {
        try {
            mService.setDeviceProvisioningConfigApplied();
@@ -6852,9 +6862,17 @@ public class DevicePolicyManager {
    }

    /**
     * @hide
     * Returns whether the provisioning configuration has been applied.
     *
     * <p>The caller must hold the {@link android.Manifest.permission#MANAGE_USERS} permission.
     *
     * <p>Not for use by third-party applications.
     *
     * @return whether the provisioning configuration has been applied.
     *
     * @hide
     */
    @SystemApi
    public boolean isDeviceProvisioningConfigApplied() {
        try {
            return mService.isDeviceProvisioningConfigApplied();