Examples of Op


Examples of com.hp.hpl.jena.sparql.algebra.Op

            // Is last in OpSequence an BGP?
            OpSequence opSeq = (OpSequence)op ;
            List<Op> x = opSeq.getElements() ;
            if ( x.size() > 0 )
            {               
                Op opTop = x.get(x.size()-1) ;
                if ( opTop instanceof OpBGP )
                    return (OpBGP)opTop ;
                // Drop through
            }
        }
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

    }
   
    private static Op transformFilterQuadPattern(ExprList exprs, Set<Var> patternVarsScope, Node graphNode, BasicPattern pattern)
    {
        // Any filters that depend on no variables.
        Op op = insertAnyFilter(exprs, patternVarsScope, null) ;
        if ( Var.isVar(graphNode) )
        {
            // Add in the graph node of the quad block.
            // It's picked up after the first triple is processed.
            VarUtils.addVar(patternVarsScope, Var.alloc(graphNode)) ;
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

            // Is last in OpSequence an BGP?
            OpSequence opSeq = (OpSequence)op ;
            List<Op> x = opSeq.getElements() ;
            if ( x.size() > 0 )
            {               
                Op opTop = x.get(x.size()-1) ;
                if ( opTop instanceof OpQuadPattern )
                    return (OpQuadPattern)opTop ;
                // Drop through
            }
        }
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

    private static Op transformFilterSequence(ExprList exprs, Set<Var> varScope, OpSequence opSequence)
    {
        List<Op> ops = opSequence.getElements() ;
       
        // Any filters that depend on no variables.
        Op op = insertAnyFilter(exprs, varScope, null) ;
       
        for ( Iterator<Op> iter = ops.iterator() ; iter.hasNext() ; )
        {
            Op seqElt = iter.next() ;
            // Process the sequence element.  This may insert filters (sequence or BGP)
            seqElt = transform(exprs, varScope, seqElt) ;
            // Merge into sequence.
            op = OpSequence.create(op, seqElt) ;
            // Place any filters now ready.
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

   
    // Modularize.
    private static Op transformFilterConditional(ExprList exprs, Set<Var> varScope, OpConditional opConditional)
    {
        // Any filters that depend on no variables.
        Op op = insertAnyFilter(exprs, varScope, null) ;
        Op left = opConditional.getLeft();
        left = transform(exprs, varScope, left);
        Op right = opConditional.getRight();
        op = new OpConditional(left, right);
        op = insertAnyFilter(exprs, varScope, op);
        return op;
     }
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

                // e.g. variable bound to a literal or blank node.
                throw new ARQInternalErrorException("QueryIterGraphInner.buildIterator") ;
           
            // Think about avoiding substitution.
            // If the subpattern does not involve the vars from the binding, avoid the substitute. 
            Op op = QC.substitute(opGraph.getSubOp(), binding) ;
           
            // We can't just use DatasetGraph.getGraph because it may "auto-create" graphs.
            // Use the containsGraph function.
           
            boolean syntheticGraph = ( Quad.isDefaultGraph(graphNode) || Quad.isUnionGraph(graphNode) ) ;
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

    {
        QueryIterator qIter = input ;
       
        for ( Iterator<Op> iter = opSequence.iterator() ; iter.hasNext() ; )
        {
            Op sub = iter.next() ;
            qIter = executeOp(sub, qIter) ;
        }
       
        return qIter ;
    }
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

        return new QueryIterDiff(left, right, execCxt) ;
    }
   
    protected QueryIterator execute(OpMinus opMinus, QueryIterator input)
    {
      Op lhsOp = opMinus.getLeft();
      Op rhsOp = opMinus.getRight();
     
        QueryIterator left = executeOp(lhsOp, input) ;
        QueryIterator right = executeOp(rhsOp, root()) ;

        Set<Var> commonVars = OpVars.patternVars(lhsOp) ;
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

   
    protected QueryIterator execute(OpFilter opFilter, QueryIterator input)
    {
        ExprList exprs = opFilter.getExprs() ;
       
        Op base = opFilter.getSubOp() ;
        QueryIterator qIter = executeOp(base, input) ;

        for ( Expr expr : exprs )
            qIter = new QueryIterFilterExpr(qIter, expr, execCxt) ;
        return qIter ;
View Full Code Here

Examples of com.hp.hpl.jena.sparql.algebra.Op

    // Add all the operations from the list to the OpN
    final private void addOps(OpN op, ItemList list)
    {
        for ( int i = 1 ; i < list.size() ; i++ )
        {
            Op sub = build(list, i) ;
            op.add(sub) ;
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.