Interface IteratorHandler.OnCloseIterator<E>

  • Type Parameters:
    E -
    All Superinterfaces:
    AutoCloseable, org.infinispan.commons.util.CloseableIterator<E>, Iterator<E>
    Enclosing class:

    public static interface IteratorHandler.OnCloseIterator<E>
    extends org.infinispan.commons.util.CloseableIterator<E>
    A CloseableIterator that also allows callers to attach Runnable instances to it, so that when this iterator is closed, those Runnables are also invoked.
    • Method Detail

      • onClose

        IteratorHandler.OnCloseIterator<E> onClose​(Runnable runnable)
        Register a runnable to be invoked when this iterator is closed
        runnable - the runnable to run
        this iterator again