copyWith method

ContactInfo copyWith({
  1. String? type,
  2. String? displayText,
  3. String? value,
  4. Optional<String?>? comment,
})

Implementation

ContactInfo copyWith({
  String? type,
  String? displayText,
  String? value,
  Optional<String?>? comment
}) {
  return ContactInfo(
    type: type ?? this.type,
    displayText: displayText ?? this.displayText,
    value: value ?? this.value,
    comment: comment != null ? comment.value : this.comment
  );
}