createPayment method

Future<MobilePayResult> createPayment(
  1. {double productPrice,
  2. String orderId}
)

Implementation

Future<MobilePayResult> createPayment({double productPrice, String orderId}) {
  assert(productPrice != null);
  assert(orderId != null);
  final completer = new Completer<MobilePayResult>();
  _orders[orderId] = completer;
  _channel.invokeMethod('createPayment', {
    'productPrice': productPrice,
    'orderId': orderId
  }).catchError((e) => throw e);
  return completer.future;
}