MandatePaymentMethodDetails.fromJson constructor
MandatePaymentMethodDetails.fromJson(
- Object? json
Implementation
factory MandatePaymentMethodDetails.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return MandatePaymentMethodDetails(
acssDebit: map['acss_debit'] == null
? null
: MandateAcssDebit.fromJson(map['acss_debit']),
auBecsDebit: map['au_becs_debit'] == null
? null
: MandateAuBecsDebit.fromJson(map['au_becs_debit']),
bacsDebit: map['bacs_debit'] == null
? null
: MandateBacsDebit.fromJson(map['bacs_debit']),
card: map['card'] == null
? null
: CardMandatePaymentMethodDetails.fromJson(map['card']),
cashapp: map['cashapp'] == null
? null
: MandateCashapp.fromJson(map['cashapp']),
link: map['link'] == null ? null : MandateLink.fromJson(map['link']),
paypal:
map['paypal'] == null ? null : MandatePaypal.fromJson(map['paypal']),
sepaDebit: map['sepa_debit'] == null
? null
: MandateSepaDebit.fromJson(map['sepa_debit']),
type: (map['type'] as String),
usBankAccount: map['us_bank_account'] == null
? null
: MandateUsBankAccount.fromJson(map['us_bank_account']),
);
}