invoke method

Future invoke(
  1. String method, [
  2. dynamic arguments
])

Invoke a method on the native bridge.

Implementation

Future<dynamic> invoke(String method, [dynamic arguments]) async {
  try {
    return await _channel.invokeMethod(method, arguments);
  } on PlatformException catch (e) {
    throw Exception('Failed to invoke bridge method: ${e.message}');
  }
}