Compartir a través de


NotificationManager.IsNotificationPolicyAccessGranted Property

Definition

Checks the ability to modify notification do not disturb policy for the calling package.

public virtual bool IsNotificationPolicyAccessGranted { [Android.Runtime.Register("isNotificationPolicyAccessGranted", "()Z", "GetIsNotificationPolicyAccessGrantedHandler", ApiSince=23)] get; }
[<get: Android.Runtime.Register("isNotificationPolicyAccessGranted", "()Z", "GetIsNotificationPolicyAccessGrantedHandler", ApiSince=23)>]
member this.IsNotificationPolicyAccessGranted : bool

Property Value

Attributes

Remarks

Checks the ability to modify notification do not disturb policy for the calling package.

Returns true if the calling package can modify notification policy.

Apps can request policy access by sending the user to the activity that matches the system intent action android.provider.Settings#ACTION_NOTIFICATION_POLICY_ACCESS_SETTINGS.

Use #ACTION_NOTIFICATION_POLICY_ACCESS_GRANTED_CHANGED to listen for user grant or denial of this access.

Java documentation for android.app.NotificationManager.isNotificationPolicyAccessGranted().

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