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

com.tinkerpop.blueprints.oupls.sail.IteratorCloseableIterable Maven / Gradle / Ivy

package com.tinkerpop.blueprints.oupls.sail;

import com.tinkerpop.blueprints.CloseableIterable;

import java.util.Iterator;

/**
 * A CloseableIterable which wraps a simple iterator.
 *
 * @author Joshua Shinavier (http://fortytwo.net)
 */
public class IteratorCloseableIterable implements CloseableIterable {
    private final Iterator iterator;

    public IteratorCloseableIterable(Iterator iterator) {
        this.iterator = iterator;
    }

    @Override
    public void close() {
        // Do nothing.
    }

    @Override
    public Iterator iterator() {
        return iterator;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy