ApplePayData.fromJson constructor

ApplePayData.fromJson(
  1. dynamic data
)

Implementation

factory ApplePayData.fromJson(dynamic data) {
  var json = DynamicJsonExtension.getJsonMap(data);
  return ApplePayData(
    countryCode: json['country_code'],
    merchantId: json['merchant_id'],
    currencyCode: json['currency_code'],
    amount: json['amount']?.toDouble(),
    supportedNetworks: List<String>.from(json['supported_networks'] ?? []),
  );
}