AndroidPayPaymentRequest.fromJson constructor

AndroidPayPaymentRequest.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory AndroidPayPaymentRequest.fromJson(Map<String, dynamic> json) {
  return AndroidPayPaymentRequest(
    billingAddressRequired: json['billing_address_required'],
    currencyCode: json['currency_code'],
    lineItems: json['line_items'] != null
        ? (json['line_items'] as List)
            .map((i) => LineItem.fromJson(i))
            .toList()
        : null,
    shippingAddressRequired: json['shipping_address_required'],
    shippingCountries: json['shipping_countries'] != null
        ? new List<String>.from(json['shipping_countries'])
        : null,
    totalPrice: json['total_price'],
  );
}