All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.infinispan.commons.util.CloseableIterator Maven / Gradle / Ivy

There is a newer version: 15.1.0.Dev04
Show newest version
package org.infinispan.commons.util;

import java.util.Iterator;

/**
 * Interface that provides semantics of a {@link Iterator} and {@link AutoCloseable} interfaces.  This is
 * useful when you have data that must be iterated on and may hold resources in the underlying implementation that
 * must be closed.
 * 

Some implementations may close resources automatically when the iterator is finished being iterated on however * this is an implementation detail and all callers should call {@link AutoCloseable#close()} method to be * sure all resources are freed properly.

* * @author wburns * @since 7.0 */ public interface CloseableIterator extends AutoCloseable, Iterator { @Override void close(); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy