getPaymentProduct method
dynamic
getPaymentProduct({
- required String paymentProductId,
- required void onSuccess(
- PaymentProduct paymentProduct
- required void onApiError(
- ApiErrorResponse apiError
- required void onFailure(),
Retrieves the PaymentProduct as identified by the provided paymentProductId
from the Connect Gateway.
Implementation
getPaymentProduct({
required String paymentProductId,
required void Function(PaymentProduct paymentProduct) onSuccess,
required void Function(ApiErrorResponse apiError) onApiError,
required void Function(NativeException e) onFailure,
}) {
final request = PaymentProductRequest(productId: paymentProductId);
return _communicator
.getPaymentProduct(
request,
_NativeFutureListener(
success: onSuccess, apiError: onApiError, failure: onFailure))
.awaitJob();
}