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

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

There is a newer version: 9.1.7.Final
Show newest version
package org.infinispan.commons.util;

import java.util.Spliterator;

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

A spliterator split from this is not closeable. Only the original {@link CloseableSpliterator} is * required to be closed

*

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

* @since 8.0 */ public interface CloseableSpliterator extends Spliterator, AutoCloseable { @Override void close(); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy