handleMethodCall method
Handles method calls over the MethodChannel of this plugin. Note: Check the "federated" architecture for a new way of doing this: https://flutter.dev/go/federated-plugins
Implementation
Future<dynamic> handleMethodCall(MethodCall call) async {
switch (call.method) {
case _METHOD_INIT:
return _init(call.arguments);
case _METHOD_INITIALIZE:
return _initialize(call.arguments);
case _METHOD_START_PAYMENT:
return await _startProcess();
case _METHOD_RESET:
return _reset();
default:
throw PlatformException(
code: 'Unimplemented',
details:
'flutter_fawry_pay for web doesn\'t implement \'${call.method}\'',
);
}
}