copyWith method

PersonalDetails copyWith({
  1. String? firstName,
  2. String? middleName,
  3. String? lastName,
  4. String? nativeFirstName,
  5. String? nativeMiddleName,
  6. String? nativeLastName,
  7. Date? birthdate,
  8. String? gender,
  9. String? countryCode,
  10. String? residenceCountryCode,
})

Implementation

PersonalDetails copyWith({
  String? firstName,
  String? middleName,
  String? lastName,
  String? nativeFirstName,
  String? nativeMiddleName,
  String? nativeLastName,
  Date? birthdate,
  String? gender,
  String? countryCode,
  String? residenceCountryCode,
}) =>
    PersonalDetails(
      firstName: firstName ?? this.firstName,
      middleName: middleName ?? this.middleName,
      lastName: lastName ?? this.lastName,
      nativeFirstName: nativeFirstName ?? this.nativeFirstName,
      nativeMiddleName: nativeMiddleName ?? this.nativeMiddleName,
      nativeLastName: nativeLastName ?? this.nativeLastName,
      birthdate: birthdate ?? this.birthdate,
      gender: gender ?? this.gender,
      countryCode: countryCode ?? this.countryCode,
      residenceCountryCode: residenceCountryCode ?? this.residenceCountryCode,
    );