copyWith method

CreditCard copyWith({
  1. int? number,
  2. int? verificationValue,
  3. String? firstName,
  4. String? lastName,
  5. int? month,
  6. int? year,
})

Implementation

CreditCard copyWith({
  int? number,
  int? verificationValue,
  String? firstName,
  String? lastName,
  int? month,
  int? year,
}) {
  return CreditCard(
    number: number ?? this.number,
    verificationValue: verificationValue ?? this.verificationValue,
    firstName: firstName ?? this.firstName,
    lastName: lastName ?? this.lastName,
    month: month ?? this.month,
    year: year ?? this.year,
  );
}