copyWith method

BarChartRodStackItem copyWith({
  1. double? fromY,
  2. double? toY,
  3. Color? color,
  4. BorderSide? borderSide,
})

Copies current BarChartRodStackItem to a new BarChartRodStackItem, and replaces provided values.

Implementation

BarChartRodStackItem copyWith({
  double? fromY,
  double? toY,
  Color? color,
  BorderSide? borderSide,
}) {
  return BarChartRodStackItem(
    fromY ?? this.fromY,
    toY ?? this.toY,
    color ?? this.color,
    borderSide ?? this.borderSide,
  );
}