public static final class FastStream.OfSingle<T> extends java.lang.Object implements FastStream<T>
FastStream for a single element.FastStream.Concatenated<T>, FastStream.ConcatenatedN<T>, FastStream.Distinct<T>, FastStream.Filtered<T>, FastStream.FlatMapped<T,R>, FastStream.Group<K,V>, FastStream.Grouped<T,K,V>, FastStream.Internal, FastStream.Mapped<T,R>, FastStream.OfN<T>, FastStream.OfSingle<T>, FastStream.Peeked<T>, FastStream.Sliced<T>, FastStream.Sorted<T>, FastStream.TypeCheck<T,S>, FastStream.Wrapped<T>EMPTY| Modifier and Type | Method and Description |
|---|---|
void |
forEach(java.util.function.Consumer<? super T> action) |
java.util.Iterator<T> |
iterator() |
int |
knownLength(boolean consumeToCalculate)
Returns the known length for the stream.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitallMatch, anyMatch, concat, concat, concatMany, count, distinct, doubleSum, empty, filter, filterNot, findFirst, findLast, first, firstOrDefault, firstOrDefault, flatMap, fold, fold, groupBy, groupBy, infer, intSum, isEmpty, join, knownLength, last, lastOrDefault, lastOrDefault, limit, longSum, map, maxBy, maxByOrDefault, maxByOrDefault, noneMatch, of, of, of, of, of, ofNullable, only, onlyOrDefault, onlyOrDefault, peek, skip, sorted, sorted, toArray, toArray, toImmutableList, toImmutableList, toImmutableMap, toImmutableMap, toImmutableSet, toImmutableSet, toLinkedHashMap, toLinkedHashMap, toLinkedHashSet, toLinkedHashSet, toLinkedList, toLinkedList, toList, toList, toMap, toMap, toMap, toMap, toSet, toSetpublic java.util.Iterator<T> iterator()
iterator in interface java.lang.Iterable<T>public void forEach(java.util.function.Consumer<? super T> action)
forEach in interface java.lang.Iterable<T>public int knownLength(boolean consumeToCalculate)
FastStream
If true is specified to consumeToCalculate causes
operations which would not normally know their length prior to a
terminal operation being applied, to cache their result under the assumption
that the stream is about to be fully consumed.
knownLength in interface FastStream<T>consumeToCalculate - If the stream should eagerly resolve its length.