StreamListX<T> extension

Extension providing collection-oriented functional operations for Streams emitting Lists.

on

Properties

lengths Stream<int>

Available on Stream<List<T>>, provided by the StreamListX extension

Emits the length of each list rather than the list itself.
no setter
whereNotEmpty Stream<List<T>>

Available on Stream<List<T>>, provided by the StreamListX extension

Emits only non-empty lists.
no setter

Methods

filter(bool predicate(T)) Stream<List<T>>

Available on Stream<List<T>>, provided by the StreamListX extension

Filters each emitted list by predicate.
flatMapItems<R>(Iterable<R> transform(T)) Stream<List<R>>

Available on Stream<List<T>>, provided by the StreamListX extension

Flat-maps each emitted list.
flatten() Stream<T>

Available on Stream<List<T>>, provided by the StreamListX extension

Flattens each emitted list into individual items.
mapItems<R>(R transform(T)) Stream<List<R>>

Available on Stream<List<T>>, provided by the StreamListX extension

Maps each element within emitted lists.
sortedBy(Comparator<T> compare) Stream<List<T>>

Available on Stream<List<T>>, provided by the StreamListX extension

Sorts each emitted list by compare.