T - type of values returned by this Iteratorpublic interface ResourceIterator<T> extends Iterator<T>, Resource
The associated resources are always released when the owning transaction is committed or rolled back.
The resource may also be released eagerly by explicitly calling close()
or by exhausting the iterator.
ResourceIterable| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the iterator early, freeing associated resources
|
default <R> ResourceIterator<R> |
map(Function<T,R> map) |
default Stream<T> |
stream() |
forEachRemaining, hasNext, next, removevoid close()
It is an error to use the iterator after this has been called.
close in interface AutoCloseableclose in interface Resourcedefault <R> ResourceIterator<R> map(Function<T,R> map)
Copyright © 2016–2021 MWARE SOLUTIONS. All rights reserved.