fillRange method

void fillRange(
  1. int start,
  2. int end, [
  3. T? fillValue
])

Overwrites a range of elements with fillValue.

Sets the positions greater than or equal to start and less than end, to fillValue.

The provided range, given by start and end, must be valid. A range from start to end is valid if 0 ≤ startendlength. An empty range (with end == start) is valid.

Implementation

void fillRange(int start, int end, [T? fillValue]) {
  var oldLength = _list.length;
  _list.fillRange(start, end, fillValue);
  if (_list.length != oldLength) _fireWatchers();
}