PermissionState class

The state of a permission.

Use the predefined constants (granted, denied, prompt) or construct with a raw string for forward-compatibility with future spec values.

See: https://developer.mozilla.org/en-US/docs/Web/API/PermissionStatus/state

Constructors

PermissionState(String value)
Creates a state from a raw string value.
const

Properties

hashCode int
The hash code for this object.
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value String
The underlying string value (e.g. 'granted', 'denied', 'prompt').
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override

Constants

denied → const PermissionState
The user has denied the permission.
granted → const PermissionState
The user has granted the permission.
prompt → const PermissionState
The user has not yet granted or denied the permission.