Package lupos.datastructures.items

Examples of lupos.datastructures.items.Variable


              : basicOperator.getIntersectionVariables().iterator();
      while (it_sortCriteriumJoin.hasNext()) {
        if (!it_sortCriteriumVars.hasNext()) {
          return false;
        }
        final Variable v1 = it_sortCriteriumJoin.next();
        final Variable v2 = it_sortCriteriumVars.next();
        if (!v1.equals(v2)) {
          return false;
        }
      }
      if (it_sortCriteriumVars.hasNext()) {
View Full Code Here


      while (it_sortCriteriumJoin.hasNext()) {
        if (!it_sortCriteriumVars.hasNext()) {
          flag = false;
          break;
        }
        final Variable v1 = it_sortCriteriumJoin.next();
        final Variable v2 = it_sortCriteriumVars.next();
        if (!v1.equals(v2)) {
          flag = false;
          break;
        }
      }
View Full Code Here

        final Node child = root.jjtGetChild(i);
        if(child instanceof ASTVars){
          for(int j=0; j<child.jjtGetNumChildren(); j++){
            final Node childchild = child.jjtGetChild(j);
            if(childchild instanceof ASTVar){
              vars.add(new Variable(((ASTVar)childchild).getName()));
            }
          }
        }
      }
      for(int i=0; i<root.jjtGetNumChildren(); i++){
        final Node child = root.jjtGetChild(i);
        if(child instanceof ASTOneResult){
          final Bindings bindings = bindingsFactory.createInstance();
          final Iterator<Variable> varIt = vars.iterator();
          for(int j=0; j<child.jjtGetNumChildren() && varIt.hasNext(); j++){
            final Variable var = varIt.next();
            final Node childchild = child.jjtGetChild(j);
            if(childchild instanceof ASTValue && childchild.jjtGetNumChildren()>0){
              bindings.add(var, TSVParser.getLiteral(childchild.jjtGetChild(0)));
            }
          }
View Full Code Here

    BasicOperator federatedQuery = this.getFederatedQuery(node);
    Node child0 = node.jjtGetChild(0);
    if(child0 instanceof ASTVar){
      Sort sort = new Sort();
      LinkedList<Variable> listOfVars = new LinkedList<Variable>();
      listOfVars.add(new Variable(((ASTVar)child0).getName()));
      ComparatorVariables comparator = new ComparatorVariables(listOfVars);
      sort.setComparator(comparator);
      Group group = new Group(comparator);
      sort.addSucceedingOperator(group);
      group.addSucceedingOperator(federatedQuery);
View Full Code Here

        final String variableName = attributes.getValue("name");
        if(variableName==null){
          throw new RuntimeException("There is no name element given in a bindings-tag!");
        } else {
          this.currentTargetType = TARGET_TYPE.var;
          this.currentVariable = new Variable(variableName);
        }
      } else if(qName.equalsIgnoreCase("uri")){
        this.currentType = TYPE.uri;
      } else if(qName.equalsIgnoreCase("bnode")){
        this.currentType = TYPE.blanknode;
View Full Code Here

      connection.connect(join);
      SeveralSucceedingOperators sso = new SeveralSucceedingOperators();
      sso.addSucceedingOperator(join, 0);
      FederatedQueryTrivialApproach federatedQuery = new FederatedQueryTrivialApproach(node);
      Projection projection = new Projection();
      projection.addProjectionElement(new Variable(((ASTVar)child0).getName()));
      Distinct distinct = new Distinct();
      projection.addSucceedingOperator(distinct);
      distinct.addSucceedingOperator(federatedQuery);
      sso.addSucceedingOperator(projection, 0);
      federatedQuery.addSucceedingOperator(join, 1);
View Full Code Here

    this.condensedViewViewer = operatorGraphViewer;
    this.drawNewCondensedView();
  }

  public Variable getVariable(final HyperNode hypernode) {
    Variable var = this.variableMap.get(hypernode);
    if (var == null) {
      var = new Variable("x" + this.variableCount++);
      this.variableMap.put(hypernode, var);
    }
    return var;
  }
View Full Code Here

            this.hypernodes[i].add(t.getPos(i));
          }
        }
      }
      if (this.hypernodes[2].size() > 1) {
        final Variable varO = CondensedViewToolBar.this.getVariable(this.hypernodes[2]);
        this.hypernodes[2].addFirst(varO);
      }
    }
View Full Code Here

            this.hypernodes[i].add(t.getPos(i));
          }
        }
      }
      if (this.hypernodes[0].size() > 1) {
        final Variable varS = CondensedViewToolBar.this.getVariable(this.hypernodes[0]);
        this.hypernodes[0].addFirst(varS);
      }
      if (this.hypernodes[2].size() > 1) {
        final Variable varO = CondensedViewToolBar.this.getVariable(this.hypernodes[2]);
        this.hypernodes[2].addFirst(varO);
      }
    }
View Full Code Here

            }
          }
        }
      }
      if (this.hypernodes[0].size() > 1) {
        final Variable varS = CondensedViewToolBar.this.getVariable(this.hypernodes[0]);
        this.hypernodes[0].addFirst(varS);
      }
      if (this.hypernodes[2].size() > 1) {
        final Variable varO = CondensedViewToolBar.this.getVariable(this.hypernodes[2]);
        this.hypernodes[2].addFirst(varO);
      }
    }
View Full Code Here

TOP

Related Classes of lupos.datastructures.items.Variable

Copyright © 2018 www.massapicom. 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.