requestPermission static method
Implementation
static Future<bool> requestPermission(Permission permission) async {
var status = await checkPermission(permission);
if (status == PermissionStatus.granted) {
return true;
}
var result =
await _channel.invokeMethod<int>('requestPermission', <String, dynamic>{
'permission': permission.toString(),
});
return result == 0;
}