T
- The type of node.public class Walker<T> extends Spliterators.AbstractSpliterator<T>
Spliterator.OfDouble, Spliterator.OfInt, Spliterator.OfLong, Spliterator.OfPrimitive<T,T_CONS,T_SPLITR extends Spliterator.OfPrimitive<T,T_CONS,T_SPLITR>>
CONCURRENT, DISTINCT, IMMUTABLE, NONNULL, ORDERED, SIZED, SORTED, SUBSIZED
Modifier and Type | Method and Description |
---|---|
boolean |
tryAdvance(Consumer<? super T> consumer) |
Spliterator<T> |
trySplit() |
static <T> Stream<T> |
walk(Collection<? extends T> roots,
Function<? super T,Collection<? extends T>> childrenOf)
Entry-point to create a
Stream for traversing a tree of type
<T> nodes. |
static <T> Stream<T> |
walk(T root,
Function<? super T,Collection<? extends T>> childrenOf)
Entry-point to create a
Stream for traversing a tree of type
<T> nodes. |
characteristics, estimateSize
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEachRemaining, getComparator, getExactSizeIfKnown, hasCharacteristics
public Spliterator<T> trySplit()
trySplit
in interface Spliterator<T>
trySplit
in class Spliterators.AbstractSpliterator<T>
public boolean tryAdvance(Consumer<? super T> consumer)
public static <T> Stream<T> walk(T root, Function<? super T,Collection<? extends T>> childrenOf)
public static <T> Stream<T> walk(Collection<? extends T> roots, Function<? super T,Collection<? extends T>> childrenOf)
Copyright © 2015–2020 Allen D. Ball. All rights reserved.