IterableExtensions<T> extension
- on
-
- Iterable<
T>
- Iterable<
Properties
- firstOrNull → T?
-
Available on Iterable<
Returns the first element.T> , provided by the IterableExtensions extensionno setter - lastOrNull → T?
-
Available on Iterable<
Returns the last element.T> , provided by the IterableExtensions extensionno setter
Methods
-
containsAll(
Iterable< Object?> elements) → bool -
Available on Iterable<
ReturnsT> , provided by the IterableExtensions extensiontrueif all of the givenelementsis in the list. -
containsAny(
Iterable< Object?> elements) → bool -
Available on Iterable<
ReturnsT> , provided by the IterableExtensions extensiontrueif any of the givenelementsis in the list. -
distinct(
) → List< T> -
Available on Iterable<
Remove duplicate values from the list.T> , provided by the IterableExtensions extension -
expandAndRemoveEmpty<
TCast> (Iterable< TCast?> callback(T item)) → List<TCast> -
Available on Iterable<
After replacing the data in the list throughT> , provided by the IterableExtensions extensioncallback, delete the Null. -
firstWhereOrNull(
bool test(T item)) → T? -
Available on Iterable<
Returns the first value found by searching based on the condition specified inT> , provided by the IterableExtensions extensiontest. -
index(
T callback(T item, int index)) → Iterable< T> -
Available on Iterable<
Index and loop it throughT> , provided by the IterableExtensions extensioncallback. -
limit(
int start, int end) → List< T> -
Available on Iterable<
Extract an array with a given range betweenT> , provided by the IterableExtensions extensionstartandend. -
limitEnd(
int end) → List< T> -
Available on Iterable<
Extract an array with a given range atT> , provided by the IterableExtensions extensionend. -
limitStart(
int start) → List< T> -
Available on Iterable<
Extract an array with a given range atT> , provided by the IterableExtensions extensionstart. -
mapAndRemoveEmpty<
TCast> (TCast? callback(T item)) → List< TCast> -
Available on Iterable<
After replacing the data in the list, delete the null.T> , provided by the IterableExtensions extension -
setWhere<
K extends Object> (Iterable< T> others, {required bool test(T original, T other), required K? apply(T original, T other), K? orElse(T original)?}) → Iterable<K> -
Available on Iterable<
The data in the list ofT> , provided by the IterableExtensions extensionothersis conditionally given to the current list. -
split(
int length) → Iterable< Iterable< T> > -
Available on Iterable<
Divides the array by the specifiedT> , provided by the IterableExtensions extensionlengthinto an array. -
toMap<
K, V> ({K key(dynamic e)?, V value(dynamic e)?}) → Map< K, V> -
Available on Iterable<
Creates a Map instance in which the keys and values are computed from theT> , provided by the IterableExtensions extensioniterable.