copyWith method

RadarDataPoint copyWith({
  1. String? label,
  2. double? value,
  3. bool? showValue,
})

Creates a copy of this radar data point with the given fields replaced.

Returns a new RadarDataPoint with the same values as this one, except for the fields that are explicitly provided.

Implementation

RadarDataPoint copyWith({String? label, double? value, bool? showValue}) {
  return RadarDataPoint(
    label: label ?? this.label,
    value: value ?? this.value,
    showValue: showValue ?? this.showValue,
  );
}