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

org.openrdf.rdf2go.StatementIterable Maven / Gradle / Ivy

/*
 * Copyright Aduna (http://www.aduna-software.com/) (c) 1997-2006.
 *
 * Licensed under the Aduna BSD-style license.
 */
package org.openrdf.rdf2go;

import org.ontoware.aifbcommons.collection.ClosableIterable;
import org.ontoware.aifbcommons.collection.ClosableIterator;
import org.ontoware.rdf2go.model.Statement;

import info.aduna.iteration.CloseableIteration;

import org.openrdf.OpenRDFException;

/**
 * Iterable over OpenRDF Statements that converts them to R2Go Statements on
 * demand.
 */
public class StatementIterable implements ClosableIterable {

	/**
     * 
     */
    private static final long serialVersionUID = -8172286299886107501L;

	private final CloseableIteration cit;

	private RepositoryModel model;

	public StatementIterable(
			CloseableIteration cit,
			RepositoryModel model)
	{
		this.cit = cit;
		this.model = model;
	}

	public ClosableIterator iterator() {
		return new StatementIterator(this.cit, this.model);
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy