Examples of Op


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

    }

    private void outputAlgebraOptQuads(ServletOutputStream outStream, final Query query, boolean lineNumbers) throws IOException
    {
        outStream.println("<p>Alebgra, with general quads optimizations:</p>") ;
        final Op op = Algebra.optimize(Algebra.toQuadForm(Algebra.compile(query))) ;
        output(outStream, query, op, lineNumbers) ;
    }
View Full Code Here

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

        }
           
        String pattern = args[0] ;
        String statsFile = args[1] ;
       
        Op op = SSE.readOp(pattern) ;

        BasicPattern bgp ;
        if ( op instanceof OpQuadPattern ) {
            bgp = ((OpQuadPattern)op).getBasicPattern() ;
        } else if ( op instanceof OpBGP ) {
View Full Code Here

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

        Var var_x = Var.alloc("x") ;
        Var var_z = Var.alloc("z") ;
       
        // ---- Build expression
        bp.add(new Triple(var_x, NodeFactory.createURI(BASE+"p"), var_z)) ;
        Op op = new OpBGP(bp) ;
        //Expr expr = ExprUtils.parse("?z < 2 ") ;
        Expr expr = new E_LessThan(new ExprVar(var_z), NodeValue.makeNodeInteger(2)) ;
        op = OpFilter.filter(expr, op) ;

        // ---- Example setup
View Full Code Here

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

            divider() ;
            query.serialize(System.out, Syntax.syntaxARQ) ;
        }
       
        QueryEngineSDB qe = new QueryEngineSDB(store, query) ;
        Op op = qe.getOp() ;

        if ( printOp )
        {
            divider() ;
            PrintSDB.print(op) ;
View Full Code Here

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

        // Parse
        Query query = QueryFactory.create(s) ;
        System.out.println(query) ;
       
        // Generate algebra
        Op op = Algebra.compile(query) ;
        op = Algebra.optimize(op) ;
        System.out.println(op) ;
       
        // Execute it.
        QueryIterator qIter = Algebra.exec(op, ExQuerySelect1.createModel()) ;
View Full Code Here

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

                pattern = reorder(pattern, peek, transform) ;
            }
        }
        // -- Filter placement
           
        Op op = null ;
        if ( exprs != null )
            op = TransformFilterPlacement.transform(exprs, pattern) ;
        else
            op = new OpBGP(pattern) ;
       
View Full Code Here

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

                input = peek ; // Original input now invalid.
                bgp = reorder(bgp, peek, transform) ;
            }
        }
        // -- Filter placement
        Op op = null ;
        if ( exprs != null )
            op = TransformFilterPlacement.transform(exprs, gn, bgp) ;
        else
            op = new OpQuadPattern(gn, bgp) ;
View Full Code Here

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

        return op ;
    }
   
    public static Op apply(Transform transform, Op op)
    {
        Op op2 = Transformer.transformSkipService(transform, op) ;
        if ( op2 != op )
            return op2 ;
        return op ;
    }
View Full Code Here

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

        // Transform transform2 = new TransformApplyInsideExprFunctionOp(transform) ;
        // Remember there is an outer substitue to the NOT EXISTS operation.

        //Transform transform2 = new TransformApplyInsideExprFunctionOp(transform) ;
       
        Op op2 = Transformer.transformSkipService(transform, op) ;
       
        final boolean debug = false ;
       
        if ( debug )
        {
            if ( label != null && log.isInfoEnabled() )
                    log.info("Transform: "+label) ;
            if ( op == op2 )
            {
                if ( log.isInfoEnabled() )
                    log.info("No change (==)") ;
                return op2 ;
            }

            if ( op.equals(op2) )
            {
                if ( log.isInfoEnabled() )
                    log.info("No change (equals)") ;
                return op2 ;
            }
            if ( log.isInfoEnabled() )
            {
                log.info("\n"+op.toString()) ;
                log.info("\n"+op2.toString()) ;
            }
        }
        if ( op2 != op )
            return op2 ;
        return op ;
View Full Code Here

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

    }

    @Override
    public Expr copySubstitute(Binding binding)
    {
        Op op2 = Substitute.substitute(getGraphPattern(), binding) ;
        return new E_NotExists(getElement(), op2) ;
    }
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.