copyWith method
ImportedContact
copyWith({
- String? phoneNumber,
- String? firstName,
- String? lastName,
- FormattedText? note()?,
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
ImportedContact copyWith({
String? phoneNumber,
String? firstName,
String? lastName,
FormattedText? Function()? note,
}) => ImportedContact(
phoneNumber: phoneNumber ?? this.phoneNumber,
firstName: firstName ?? this.firstName,
lastName: lastName ?? this.lastName,
note: note != null ? note() : this.note,
);