Class TransformStreamable<S,T>
java.lang.Object
org.javimmutable.collections.iterators.TransformStreamable<S,T>
- All Implemented Interfaces:
Iterable<T>,IStreamable<T>,SplitableIterable<T>
-
Method Summary
Modifier and TypeMethodDescriptionintiterator()Overridden here to require implementations to return a SplitableIterator rather than a basic Iterator.static <S,T> IStreamable <T> of(IStreamable<S> source, java.util.function.Function<S, T> transforminator) static <K,V> IStreamable <K> ofKeys(IStreamable<IMapEntry<K, V>> source) static <K,V> IStreamable <V> ofValues(IStreamable<IMapEntry<K, V>> source) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.javimmutable.collections.IStreamable
parallelStream, spliterator, streamMethods inherited from interface org.javimmutable.collections.SplitableIterable
forEachThrows, indexedForEach, indexedForEachThrows, reduce, reduceThrows
-
Method Details
-
of
public static <S,T> IStreamable<T> of(@Nonnull IStreamable<S> source, @Nonnull java.util.function.Function<S, T> transforminator) -
ofKeys
-
ofValues
-
iterator
Description copied from interface:IStreamableOverridden here to require implementations to return a SplitableIterator rather than a basic Iterator. This is necessary to allow composition of new objects from methods like keys() and values().- Specified by:
iteratorin interfaceIStreamable<S>- Specified by:
iteratorin interfaceIterable<S>- Specified by:
iteratorin interfaceSplitableIterable<S>
-
getSpliteratorCharacteristics
public int getSpliteratorCharacteristics()- Specified by:
getSpliteratorCharacteristicsin interfaceIStreamable<S>- Returns:
- characteristics value used when creating Spliterators
-