DevicePolicyManager.GetApplicationRestrictionsManagingPackage Method

Definition

Called by a profile owner or device owner to retrieve the application restrictions managing package for the current user, or null if none is set.

[Android.Runtime.Register("getApplicationRestrictionsManagingPackage", "(Landroid/content/ComponentName;)Ljava/lang/String;", "GetGetApplicationRestrictionsManagingPackage_Landroid_content_ComponentName_Handler", ApiSince=24)]
public virtual string? GetApplicationRestrictionsManagingPackage (Android.Content.ComponentName admin);
[<Android.Runtime.Register("getApplicationRestrictionsManagingPackage", "(Landroid/content/ComponentName;)Ljava/lang/String;", "GetGetApplicationRestrictionsManagingPackage_Landroid_content_ComponentName_Handler", ApiSince=24)>]
abstract member GetApplicationRestrictionsManagingPackage : Android.Content.ComponentName -> string
override this.GetApplicationRestrictionsManagingPackage : Android.Content.ComponentName -> string

Parameters

admin
ComponentName

Which DeviceAdminReceiver this request is associated with.

Returns

The package name allowed to manage application restrictions on the current user, or null if none is set.

Attributes

Remarks

Called by a profile owner or device owner to retrieve the application restrictions managing package for the current user, or null if none is set. If there are multiple delegates this function will return one of them.

This member is deprecated. From android.os.Build.VERSION_CODES#O. Use #getDelegatePackages with the #DELEGATION_APP_RESTRICTIONS scope instead.

Java documentation for android.app.admin.DevicePolicyManager.getApplicationRestrictionsManagingPackage(android.content.ComponentName).

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.

Applies to