Permissions class Null safety

Experimental This is an experimental technologyCheck the Browser compatibility table carefully before using this in production. The Permissions interface of the Permissions API provides the core Permission API functionality, such as methods for querying and revoking permissions

Annotations

Constructors

Permissions()
factory

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
query(dynamic permissionDesc) Promise<PermissionStatus>
Returns the user permission status for a given API. navigator.permissions.query(PermissionDescriptor).then(function(permissionStatus) { ... }) navigator.permissions.query({name:'geolocation'}).then(function(result) { if (result.state == 'granted') { showLocalNewsWithGeolocation(); } else if (result.state == 'prompt') { showButtonToEnableLocalNews(); } // Don't do anything if the permission was denied. });
request(dynamic permissionDesc) Promise<PermissionStatus>
revoke(dynamic permissionDesc) Promise<PermissionStatus>
toString() String
A string representation of this object. [...]
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited