copyWith method

DataRow copyWith({
  1. LocalKey? key,
  2. bool? selected,
  3. ValueChanged<bool?>? onSelectChanged,
  4. MaterialStateProperty<Color?>? color,
  5. List<DataCell>? cells,
})

Implementation

DataRow copyWith({
  LocalKey? key,
  bool? selected,
  ValueChanged<bool?>? onSelectChanged,
  MaterialStateProperty<Color?>? color,
  List<DataCell>? cells,
}) {
  return DataRow(
    key: key ?? this.key,
    selected: selected ?? this.selected,
    onSelectChanged: onSelectChanged ?? this.onSelectChanged,
    color: color ?? this.color,
    cells: cells ?? this.cells,
  );
}