toJson method

Map<String, Object?> toJson()

Implementation

Map<String, Object?> toJson() {
  final Map<String, dynamic> data = new Map<String, dynamic>();
  if (this.card != null) {
    data['card'] = card!.toJson();
  }
  if (this.token != null) {
    data['token'] = token!.toJson();
  }
  if (this.billingAddress != null) {
    data['billingAddress'] = this.billingAddress!.toJson();
  }
  if (this.metadata != null) {
    if (this.metadata != null) data['metadata'] = this.metadata;
  }
  return data;
}