copyWith method

PaymentInitiationPayment copyWith({
  1. String? paymentId,
  2. PaymentAmount? amount,
  3. PaymentInitiationPaymentStatus? status,
  4. String? recipientId,
  5. String? reference,
  6. String? adjustedReference,
  7. DateTime? lastStatusUpdate,
  8. ExternalPaymentScheduleGet? schedule,
  9. ExternalPaymentRefundDetails? refundDetails,
  10. SenderBACSNullable? bacs,
  11. String? iban,
  12. List<String>? refundIds,
  13. PaymentAmountRefunded? amountRefunded,
  14. String? walletId,
  15. PaymentScheme? scheme,
  16. PaymentScheme? adjustedScheme,
  17. String? consentId,
  18. String? transactionId,
})

Implementation

PaymentInitiationPayment copyWith(
    {String? paymentId,
    PaymentAmount? amount,
    enums.PaymentInitiationPaymentStatus? status,
    String? recipientId,
    String? reference,
    String? adjustedReference,
    DateTime? lastStatusUpdate,
    ExternalPaymentScheduleGet? schedule,
    ExternalPaymentRefundDetails? refundDetails,
    SenderBACSNullable? bacs,
    String? iban,
    List<String>? refundIds,
    PaymentAmountRefunded? amountRefunded,
    String? walletId,
    enums.PaymentScheme? scheme,
    enums.PaymentScheme? adjustedScheme,
    String? consentId,
    String? transactionId}) {
  return PaymentInitiationPayment(
      paymentId: paymentId ?? this.paymentId,
      amount: amount ?? this.amount,
      status: status ?? this.status,
      recipientId: recipientId ?? this.recipientId,
      reference: reference ?? this.reference,
      adjustedReference: adjustedReference ?? this.adjustedReference,
      lastStatusUpdate: lastStatusUpdate ?? this.lastStatusUpdate,
      schedule: schedule ?? this.schedule,
      refundDetails: refundDetails ?? this.refundDetails,
      bacs: bacs ?? this.bacs,
      iban: iban ?? this.iban,
      refundIds: refundIds ?? this.refundIds,
      amountRefunded: amountRefunded ?? this.amountRefunded,
      walletId: walletId ?? this.walletId,
      scheme: scheme ?? this.scheme,
      adjustedScheme: adjustedScheme ?? this.adjustedScheme,
      consentId: consentId ?? this.consentId,
      transactionId: transactionId ?? this.transactionId);
}