copyWith method

PopulationTypeLocalised copyWith({
  1. NameLocalised? name,
  2. PopulationType? type,
})

Returns a copy of this instance with the given fields replaced by new values.

If a field is not provided, the existing value is retained.

Implementation

PopulationTypeLocalised copyWith({
  NameLocalised? name,
  PopulationType? type,
}) =>
    PopulationTypeLocalised(name: name ?? this.name, type: type ?? this.type);