use of org.apache.rya.api.utils.CloseableIterableIteration in project incubator-rya by apache.
the class AccumuloRyaQueryEngine method query.
@Override
public CloseableIteration<RyaStatement, RyaDAOException> query(RyaStatement stmt, AccumuloRdfConfiguration conf) throws RyaDAOException {
if (conf == null) {
conf = configuration;
}
RyaQuery ryaQuery = RyaQuery.builder(stmt).load(conf).build();
CloseableIterable<RyaStatement> results = query(ryaQuery);
return new CloseableIterableIteration<RyaStatement, RyaDAOException>(results);
}
use of org.apache.rya.api.utils.CloseableIterableIteration in project incubator-rya by apache.
the class AccumuloRyaQueryEngine method batchQuery.
@Override
public CloseableIteration<RyaStatement, RyaDAOException> batchQuery(Collection<RyaStatement> stmts, AccumuloRdfConfiguration conf) throws RyaDAOException {
if (conf == null) {
conf = configuration;
}
BatchRyaQuery batchRyaQuery = BatchRyaQuery.builder(stmts).load(conf).build();
CloseableIterable<RyaStatement> results = query(batchRyaQuery);
return new CloseableIterableIteration<RyaStatement, RyaDAOException>(results);
}
Aggregations