Examples of Var


Examples of org.openrdf.query.algebra.Var

  @Override
  public Object visit(ASTGraphGraphPattern node, Object data)
    throws VisitorException
  {
    Var oldContext = graphPattern.getContextVar();
    Scope oldScope = graphPattern.getStatementPatternScope();

    ValueExpr newContext = (ValueExpr)node.jjtGetChild(0).jjtAccept(this, null);

    graphPattern.setContextVar(valueExpr2Var(newContext));
View Full Code Here

Examples of org.openrdf.query.algebra.Var

    ValueExpr subject = (ValueExpr)data;
    ValueExpr predicate = (ValueExpr)propListNode.getVerb().jjtAccept(this, null);
    @SuppressWarnings("unchecked")
    List<ValueExpr> objectList = (List<ValueExpr>)propListNode.getObjectList().jjtAccept(this, null);

    Var subjVar = valueExpr2Var(subject);
    Var predVar = valueExpr2Var(predicate);

    for (ValueExpr object : objectList) {
      Var objVar = valueExpr2Var(object);
      graphPattern.addRequiredSP(subjVar, predVar, objVar);
    }

    ASTPropertyList nextPropList = propListNode.getNextPropertyList();
    if (nextPropList != null) {
View Full Code Here

Examples of org.openrdf.query.algebra.Var

  @Override
  public Var visit(ASTBlankNodePropertyList node, Object data)
    throws VisitorException
  {
    Var bnodeVar = createAnonVar(node.getVarName());
    super.visit(node, bnodeVar);
    return bnodeVar;
  }
View Full Code Here

Examples of org.openrdf.query.algebra.Var

  @Override
  public Var visit(ASTCollection node, Object data)
    throws VisitorException
  {
    String listVarName = node.getVarName();
    Var rootListVar = createAnonVar(listVarName);

    Var listVar = rootListVar;

    int childCount = node.jjtGetNumChildren();
    for (int i = 0; i < childCount; i++) {
      ValueExpr childValue = (ValueExpr)node.jjtGetChild(i).jjtAccept(this, null);

      Var childVar = valueExpr2Var(childValue);
      graphPattern.addRequiredSP(listVar, createConstVar(RDF.FIRST), childVar);

      Var nextListVar;
      if (i == childCount - 1) {
        nextListVar = createConstVar(RDF.NIL);
      }
      else {
        nextListVar = createAnonVar(listVarName + "-" + (i + 1));
View Full Code Here

Examples of org.openrdf.query.algebra.Var

  @Override
  public ValueExpr visit(ASTBound node, Object data)
    throws VisitorException
  {
    Var var = (Var)node.getArg().jjtAccept(this, null);
    return new Bound(var);
  }
View Full Code Here

Examples of org.openrdf.query.algebra.Var

  @Override
  public Var visit(ASTVar node, Object data)
    throws VisitorException
  {
    Var var = new Var(node.getName());
    var.setAnonymous(node.isAnonymous());
    return var;
  }
View Full Code Here

Examples of org.openrdf.query.algebra.Var

  @Override
  public void meet(StatementPattern sp)
    throws RdbmsException
  {
    super.meet(sp);
    Var subjVar = sp.getSubjectVar();
    Var predVar = sp.getPredicateVar();
    Var objVar = sp.getObjectVar();
    Var ctxVar = sp.getContextVar();

    Value subjValue = getVarValue(subjVar, bindings);
    Value predValue = getVarValue(predVar, bindings);
    Value objValue = getVarValue(objVar, bindings);
    Value ctxValue = getVarValue(ctxVar, bindings);
View Full Code Here

Examples of prolog.logic.Var

    }
    else if(order==0) {
      return new Integer(1);
    }
    else if(B.compareTo(NVARS2)<0) {
      return new Var(B.intValue()-2);
    }
    else {
      BigInteger[] tuple=bigint2tuple(getArity(),B);
      Object[] args=new Object[getArity()];
      for(int i=0;i<tuple.length;i++) {
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.