Share via


UserManager.UserRestrictions Property

Definition

Caution

deprecated

Returns the user-wide restrictions imposed on the context user. -or- This will no longer work.

public virtual Android.OS.Bundle? UserRestrictions { [Android.Runtime.Register("getUserRestrictions", "()Landroid/os/Bundle;", "GetGetUserRestrictionsHandler")] get; [Android.Runtime.Register("setUserRestrictions", "(Landroid/os/Bundle;)V", "GetSetUserRestrictions_Landroid_os_Bundle_Handler")] [System.Obsolete("deprecated")] set; }
[<get: Android.Runtime.Register("getUserRestrictions", "()Landroid/os/Bundle;", "GetGetUserRestrictionsHandler")>]
[<set: Android.Runtime.Register("setUserRestrictions", "(Landroid/os/Bundle;)V", "GetSetUserRestrictions_Landroid_os_Bundle_Handler")>]
[<set: System.Obsolete("deprecated")>]
member this.UserRestrictions : Android.OS.Bundle with get, set

Property Value

a Bundle containing all the restrictions.

Attributes

Remarks

Property getter documentation:

Returns the user-wide restrictions imposed on the context user.

Java documentation for android.os.UserManager.getUserRestrictions().

Property setter documentation:

This will no longer work. Device owners and profile owners should use DevicePolicyManager#addUserRestriction(ComponentName, String) instead.

Java documentation for android.os.UserManager.setUserRestrictions(android.os.Bundle).

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