copyWith method

ChipSelectionData<T> copyWith({
  1. T? value,
  2. String? label,
  3. String? tooltip,
  4. bool? disabled,
  5. bool? hidden,
  6. dynamic meta,
  7. ChipSelectionItemStyle? style,
  8. ChipSelectionItemStyle? activeStyle,
  9. dynamic select(
    1. bool selected
    )?,
  10. bool? selected,
})

Creates a copy of this ChipSelection but with the given fields replaced with the new values.

Implementation

ChipSelectionData<T> copyWith({
  T? value,
  String? label,
  String? tooltip,
  bool? disabled,
  bool? hidden,
  dynamic meta,
  ChipSelectionItemStyle? style,
  ChipSelectionItemStyle? activeStyle,
  Function(bool selected)? select,
  bool? selected,
}) {
  return ChipSelectionData<T>(
    value: value ?? this.value,
    label: label ?? this.label,
    tooltip: tooltip ?? this.tooltip,
    disabled: disabled ?? this.disabled,
    hidden: hidden ?? this.hidden,
    meta: meta ?? this.meta,
    style: style ?? this.style,
    activeStyle: activeStyle ?? this.activeStyle,
    select: select ?? this.select,
    selected: selected ?? this.selected,
  );
}