BetterIterableNotifications<T> extension

Extension to provide additional methods for VN<Iterable<T>>.

on

Properties

first → T

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the first element in the iterable.
no setter
firstOrNull → T?

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the first element in the iterable, or null if the iterable is empty.
no setter
isEmpty bool

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns true if the iterable has no elements.
no setter
isNotEmpty bool

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns true if the iterable has one or more elements.
no setter
last → T

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the last element in the iterable.
no setter
lastOrNull → T?

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the last element in the iterable, or null if the iterable is empty.
no setter
length int

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the number of elements in the iterable.
no setter

Methods

firstWhere(bool function(T)) → T

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the first element that satisfies the given predicate function.
lastWhere(bool function(T)) → T

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns the last element that satisfies the given predicate function.
toList() List<T>

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns a new list containing all elements of the iterable.
where(bool function(T)) Iterable<T>

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Returns a new lazy Iterable with all elements that satisfy the predicate function.

Operators

operator [](int index) → T

Available on VN<Iterable<T>>, provided by the BetterIterableNotifications extension

Gets the element at the specified index in the iterable.