/** * Is there another possibility? */ public boolean hasNext() { if ( queryExecutionIter == null ) return false ; boolean r = queryExecutionIter.hasNext() ; return r; }
@Override protected boolean hasNextBinding() { return output.hasNext() ; }
@Override protected boolean hasNextBinding() { return iterator.hasNext() ; } }
@Override public boolean hasNextBinding() { return getInput().hasNext() ; }
@Override protected NodeValue eval(Binding binding, QueryIterator qIter, FunctionEnv env) { boolean b = qIter.hasNext() ; return NodeValue.booleanReturn(b) ; }
@Override protected boolean hasNextBinding() { init() ; return procIter.hasNext() ; }
public LinearIndex(Set<Var> commonVars, QueryIterator data) { this.commonVars = commonVars ; while ( data.hasNext() ) table.add(data.next()) ; data.close() ; }
public LinearIndex(Set<Var> commonVars, QueryIterator data, Set<HashIndexTable.Key> loadedData, Map<Var,Integer> mappings) { this.commonVars = commonVars ; for ( HashIndexTable.Key key: loadedData ) table.add(toBinding(key, mappings)) ; while ( data.hasNext() ) table.add(data.next()) ; data.close() ; }
@Override protected boolean hasNextBinding() { if ( isFinished() ) return false; if ( ! getInput().hasNext() ) return false ; if ( count >= limit ) return false ; return true ; }
public QueryIteratorCopy(QueryIterator qIter) { for ( ; qIter.hasNext() ; ) elements.add(qIter.nextBinding()) ; qIter.close() ; iterator = copy() ; original = qIter ; }
public QueryIteratorCopy(QueryIterator qIter) { for ( ; qIter.hasNext() ; ) elements.add(qIter.nextBinding()) ; qIter.close() ; iterator = copy() ; original = qIter ; }
public void materialize(QueryIterator qIter) { while ( qIter.hasNext() ) { Binding binding = qIter.nextBinding() ; addBinding(binding) ; } qIter.close() ; }
private static List<Binding> toList(QueryIterator qIter) { List<Binding> x = new ArrayList<Binding>() ; for ( ; qIter.hasNext() ; ) x.add(qIter.nextBinding()) ; return x ; } }
@Override protected boolean hasNextBinding() { if ( binding != null ) return true ; if ( ! getInput().hasNext() ) return false ; binding = getInput().nextBinding() ; return true ; }
public boolean execAsk() { if ( ! query.isAskType() ) throw new QueryExecException("Attempt to have boolean from a "+labelForQuery(query)+" query") ; startQueryIterator() ; boolean r = queryIterator.hasNext() ; this.close() ; return r ; }
@Override public boolean execAsk() { if ( ! query.isAskType() ) throw new QueryExecException("Attempt to have boolean from a "+labelForQuery(query)+" query") ; startQueryIterator() ; boolean r = queryIterator.hasNext() ; this.close() ; return r ; }
public static void outputPlain(IndentedWriter out, Table table, SerializationContext sCxt) { QueryIterator qIter = table.iterator(null) ; for ( ; qIter.hasNext(); ) { Binding b = qIter.nextBinding() ; output(out, b, sCxt) ; out.println() ; } qIter.close() ; }
protected QueryIterator leftJoinWorker() { if ( !getLeft().hasNext() ) return null ; Binding b = getLeft().nextBinding() ; QueryIterator x = tableRight.matchRightLeft(b, true, exprs, getExecContext()) ; return x ; }
public static void outputPlain(IndentedWriter out, Table table, SerializationContext sCxt) { QueryIterator qIter = table.iterator(null) ; for ( ; qIter.hasNext(); ) { Binding b = qIter.nextBinding() ; output(out, b, sCxt) ; out.println() ; } qIter.close() ; }
protected QueryIterator equiJoinWorker() { if ( !getLeft().hasNext() ) return null ; if ( exprs != null ) throw new ARQInternalErrorException("QueryIterJoinBase: expression not empty for equiJoin") ; Binding b = getLeft().nextBinding() ; QueryIterator x = tableRight.matchRightLeft(b, false, null, getExecContext()) ; return x ; } }