removeIf method
- bool test(
- T
Removes all elements for which test returns true.
Implementation
void removeIf(bool Function(T) test) {
_DoubleListNode<T>? current = _head;
while (current != null) {
_DoubleListNode<T>? nextNode = current.next;
if (test(current.value)) {
_unlink(current);
}
current = nextNode;
}
}