copyWith method

OrderedValues copyWith({
  1. List<OrderedValue>? values,
  2. Optional<int?>? currentMinIndex,
  3. Optional<int?>? currentMaxIndex,
})

Implementation

OrderedValues copyWith({
  List<OrderedValue>? values,
  Optional<int?>? currentMinIndex,
  Optional<int?>? currentMaxIndex
}) {
  return OrderedValues(
    values: values ?? this.values,
    currentMinIndex: currentMinIndex != null ? currentMinIndex.value : this.currentMinIndex,
    currentMaxIndex: currentMaxIndex != null ? currentMaxIndex.value : this.currentMaxIndex
  );
}