filterWithIndex method
Returns the list of those elements that satisfy test
.
Implementation
Iterable<T> filterWithIndex(bool Function(T t, int index) test) sync* {
var index = 0;
for (var value in this) {
if (test(value, index)) {
yield value;
}
index += 1;
}
}