Package org.apache.commons.io.function
Class IOSpliteratorAdapter<T>
- java.lang.Object
-
- org.apache.commons.io.function.IOSpliteratorAdapter<T>
-
- Type Parameters:
T
- the type of the stream elements.
- All Implemented Interfaces:
IOSpliterator<T>
final class IOSpliteratorAdapter<T> extends java.lang.Object implements IOSpliterator<T>
Adapts anSpliterator
as anIOSpliterator
.
-
-
Constructor Summary
Constructors Constructor Description IOSpliteratorAdapter(java.util.Spliterator<T> delegate)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) static <E> IOSpliteratorAdapter<E>
adapt(java.util.Spliterator<E> delegate)
Adapts the given Spliterator as an IOSpliterator.java.util.Spliterator<T>
unwrap()
Unwraps this instance and returns the underlyingSpliterator
.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.commons.io.function.IOSpliterator
asSpliterator, characteristics, estimateSize, forEachRemaining, getComparator, getExactSizeIfKnown, hasCharacteristics, tryAdvance, trySplit
-
-
-
-
Field Detail
-
delegate
private final java.util.Spliterator<T> delegate
-
-
Constructor Detail
-
IOSpliteratorAdapter
IOSpliteratorAdapter(java.util.Spliterator<T> delegate)
-
-
Method Detail
-
adapt
static <E> IOSpliteratorAdapter<E> adapt(java.util.Spliterator<E> delegate)
Description copied from interface:IOSpliterator
Adapts the given Spliterator as an IOSpliterator.- Type Parameters:
E
- the type of the stream elements.- Parameters:
delegate
- The iterator to adapt- Returns:
- A new IOSpliterator
-
unwrap
public java.util.Spliterator<T> unwrap()
Description copied from interface:IOSpliterator
Unwraps this instance and returns the underlyingSpliterator
.Implementations may not have anything to unwrap and that behavior is undefined for now.
- Specified by:
unwrap
in interfaceIOSpliterator<T>
- Returns:
- the underlying Spliterator.
-
-