removeAt method

E removeAt (
  1. int index
)
override

Removes the object at position index from this list.

This method reduces the length of this by one and moves all later objects down by one position.

Returns the removed value.

The index must be in the range 0 ≤ index < length.

The list must be growable.

Implementation

E removeAt(int index) {
  E result = this[index];
  _closeGap(index, index + 1);
  return result;
}

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dart.dev/stable/2.13.0/dart-collection/ListMixin/removeAt.html