SourceMandate.fromJson constructor
SourceMandate.fromJson(
- Object? json
Implementation
factory SourceMandate.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return SourceMandate(
acceptance: map['acceptance'] == null
? null
: SourceAcceptance.fromJson(map['acceptance']),
amount: map['amount'] == null ? null : (map['amount'] as num).toInt(),
currency: map['currency'] == null ? null : (map['currency'] as String),
interval: map['interval'] == null
? null
: SourceInterval.fromJson(map['interval']),
notificationMethod: map['notification_method'] == null
? null
: SourceNotificationMethod.fromJson(map['notification_method']),
);
}