copyWith method
MessagePaymentSuccessfulBot
copyWith({
- String? currency,
- int? totalAmount,
- bool? isRecurring,
- bool? isFirstRecurring,
- String? invoicePayload,
- String? shippingOptionId,
- OrderInfo? orderInfo()?,
- String? telegramPaymentChargeId,
- String? providerPaymentChargeId,
override
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
@override
MessagePaymentSuccessfulBot copyWith({
String? currency,
int? totalAmount,
bool? isRecurring,
bool? isFirstRecurring,
String? invoicePayload,
String? shippingOptionId,
OrderInfo? Function()? orderInfo,
String? telegramPaymentChargeId,
String? providerPaymentChargeId,
}) =>
MessagePaymentSuccessfulBot(
currency: currency ?? this.currency,
totalAmount: totalAmount ?? this.totalAmount,
isRecurring: isRecurring ?? this.isRecurring,
isFirstRecurring: isFirstRecurring ?? this.isFirstRecurring,
invoicePayload: invoicePayload ?? this.invoicePayload,
shippingOptionId: shippingOptionId ?? this.shippingOptionId,
orderInfo: orderInfo != null ? orderInfo() : this.orderInfo,
telegramPaymentChargeId:
telegramPaymentChargeId ?? this.telegramPaymentChargeId,
providerPaymentChargeId:
providerPaymentChargeId ?? this.providerPaymentChargeId,
);