Package nbbrd.io
Interface IOIterator<E>
- Type Parameters:
E-
- All Known Implementing Classes:
AbstractIOIterator
public interface IOIterator<E>
- Author:
- Philippe Charles
-
Method Summary
Modifier and TypeMethodDescriptionasStream()static <E> @NonNull IOIterator<E> static <E> @NonNull IOIterator<E> empty()default voidforEachRemainingWithIO(@NonNull IOConsumer<? super E> action) static <E> @NonNull IOIterator<E> generateWhile(@NonNull IOSupplier<E> supplier, @NonNull IOPredicate<? super E> predicate) booleanstatic <E> @NonNull IOIterator<E> iterate(@NonNull IOSupplier<E> seed, @NonNull IOPredicate<? super E> hasNext, @NonNull IOUnaryOperator<E> next) @Nullable Edefault voidstatic <E> @NonNull IOIterator<E> singleton(E element) static <E> @NonNull Iterator<E> unchecked(@NonNull IOIterator<E> iterator)
-
Method Details
-
hasNextWithIO
- Throws:
IOException
-
nextWithIO
- Throws:
IOExceptionNoSuchElementException
-
removeWithIO
- Throws:
IOException
-
forEachRemainingWithIO
@JdkWithIO default void forEachRemainingWithIO(@NonNull @NonNull IOConsumer<? super E> action) throws IOException - Throws:
IOException
-
asStream
-
asUnchecked
-
empty
-
singleton
-
checked
-
unchecked
-
iterate
@NonNull static <E> @NonNull IOIterator<E> iterate(@NonNull @NonNull IOSupplier<E> seed, @NonNull @NonNull IOPredicate<? super E> hasNext, @NonNull @NonNull IOUnaryOperator<E> next) -
generateWhile
@NonNull static <E> @NonNull IOIterator<E> generateWhile(@NonNull @NonNull IOSupplier<E> supplier, @NonNull @NonNull IOPredicate<? super E> predicate)
-