InElementT
- the element type of the input spliteratorOutElementT
- the element type of the output spliteratorsstatic final class CollectSpliterators.FlatMapSpliteratorOfObject<InElementT,OutElementT> extends CollectSpliterators.FlatMapSpliterator<InElementT,OutElementT,java.util.Spliterator<OutElementT>>
Stream#flatMap
with an object spliterator output type.
To avoid having this type, we could use FlatMapSpliterator
directly. The main
advantages to having the type are the ability to use its constructor reference below and the
parallelism with the primitive version. In short, it makes its caller (flatMap
)
simpler.
CollectSpliterators.FlatMapSpliterator.Factory<InElementT,OutSpliteratorT extends java.util.Spliterator<?>>
characteristics, estimatedSize, factory, from, function, prefix
Constructor and Description |
---|
FlatMapSpliteratorOfObject(java.util.Spliterator<OutElementT> prefix,
java.util.Spliterator<InElementT> from,
java.util.function.Function<? super InElementT,java.util.Spliterator<OutElementT>> function,
int characteristics,
long estimatedSize) |
characteristics, estimateSize, forEachRemaining, tryAdvance, trySplit
FlatMapSpliteratorOfObject(@CheckForNull java.util.Spliterator<OutElementT> prefix, java.util.Spliterator<InElementT> from, java.util.function.Function<? super InElementT,java.util.Spliterator<OutElementT>> function, int characteristics, long estimatedSize)