@Override public void close() throws SailException { if (closed) { return; } closed = true; parentIterator.close(); }
@Override public void close() throws SailException { if (parentIterator != null) { parentIterator.close(); } }
@Override public void close() throws SailException { if (closed) { return; } closed = true; parentIterator.close(); }
@Override protected void handleClose() throws QueryEvaluationException { try { super.handleClose(); } finally { resultIteration.close(); } } }
@Override public void close() throws SailException { try { bindingSet.close(); } finally { if (repositoryConnection != null) { repositoryConnection.close(); } } }
@Override protected void handleClose() throws QueryEvaluationException { try { super.handleClose(); } finally { resultIteration.close(); } } }
@Override public void handleClose() throws QueryEvaluationException { try { super.handleClose(); } finally { iter.close(); } } };
@Override public void close() throws SailException { try { bindingSet.close(); } finally { if (repositoryConnection != null) { repositoryConnection.close(); } } }
@Override protected void handleClose() throws QueryEvaluationException { try { super.handleClose(); } finally { iter.close(); } } };
@Override public void handleClose() throws QueryEvaluationException { try { super.handleClose(); } finally { iter.close(); } } };
public Statement next() { try { last = stmts.next(); if (last == null) { stmts.close(); } return last; } catch (SailException e) { throw new ModelException(e); } }
@Override public void closeIterator(Iterator<?> iter) { super.closeIterator(iter); if (iter instanceof StatementIterator) { try { ((StatementIterator)iter).stmts.close(); } catch (SailException e) { throw new ModelException(e); } } }
public boolean hasNext() { try { if (stmts.hasNext()) return true; stmts.close(); return false; } catch (SailException e) { throw new ModelException(e); } }
public boolean hasNext() { try { if (stmts.hasNext()) return true; stmts.close(); return false; } catch (SailException e) { throw new ModelException(e); } }
public Statement next() { try { last = stmts.next(); if (last == null) { stmts.close(); } return last; } catch (SailException e) { throw new ModelException(e); } }
@Override protected void handleClose() throws QueryEvaluationException { try { super.handleClose(); leftIter.close(); // rightIter.close(); } catch (Exception e) { throw new QueryEvaluationException(e); } }
@Override public void closeIterator(Iterator<?> iter) { super.closeIterator(iter); if (iter instanceof StatementIterator) { try { ((StatementIterator)iter).stmts.close(); } catch (SailException e) { throw new ModelException(e); } } }
public Value evaluate(Exists node, BindingSet bindings) throws ValueExprEvaluationException, QueryEvaluationException { CloseableIteration<BindingSet, QueryEvaluationException> iter = evaluate(node.getSubQuery(), bindings); try { return BooleanLiteral.valueOf(iter.hasNext()); } finally { iter.close(); } }