forEachIndexedWhile method

*<Null safety>*

void forEachIndexedWhile (bool action(int index, E element))

Implementation

void forEachIndexedWhile(bool Function(int index, E element) action) {
  for (var index = 0; index < length; index++) {
    if (!action(index, this[index])) break;
  }
}