RequestPermission class

Properties

hashCode int
The hash code for this object.
no setterinherited
isWaitingForResponse ValueListenable<bool>
Whether this app is currently waiting for a response from the user (true), or not (false).
no setter
results Stream<ResultingPermission>
After using requestAndroidPermission or requestMultipleAndroidPermissions, you can listen to this BroadcastStream, to detect when the user makes his choice, whether he wants to grant your app the requested permisson/s or not.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

hasAndroidPermission(String permission) Future<bool>
Check whether your app has a certain permission.
hasAndroidPermissions(Set<String> permissions) Future<Map<String, bool>>
Calls hasAndroidPermission for every permission in permissions.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
requestAndroidPermission(String permission, [int requestCode = defaultRequestCode]) Future<void>
Calls requestMultipleAndroidPermissions to request a single permission.
requestMultipleAndroidPermissions(Set<String> permissions, [int requestCode = defaultRequestCode]) Future<void>
Description
setLogLevel(LogLevel logLevel) Future<void>
The logLevel defaults to LogLevel.verbose.
shouldShowRequestPermissionRationale(String permission) Future<bool>
Description
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

instace RequestPermission
no setter

Constants

defaultRequestCode → const int
If you decide to omit the requestCode, when calling requestAndroidPermission or requestMultipleAndroidPermissions, then this one gets used.
permissionDenied → const int
permissionGranted → const int