Examples of Construct


Examples of lupos.engine.operators.singleinput.Construct

  public LinkedList<Tuple<Construct, Item>> getGraphConstructs(final Node node) {
    final LinkedList<Tuple<Construct, Item>> graphConstructs = new LinkedList<Tuple<Construct, Item>>();
    final Collection<TriplePattern> operators = this.collectTriplePatternOfChildren(node);
    if(operators.size()>0){
      final Construct c = new Construct();
      c.setTemplates(operators);
      graphConstructs.add(new Tuple<Construct, Item>(c, null));
    }
    for(int i=0; i<node.jjtGetNumChildren();i++){
      final Node child = node.jjtGetChild(i);
      if(child instanceof ASTGraphConstraint){
        final Collection<TriplePattern> otp = this.collectTriplePatternOfChildren(child);
        if(otp.size()>0){
          final Construct c2 = new Construct();
          c2.setTemplates(otp);
          final Node childchild=child.jjtGetChild(0);
          Item item=null;
          if (childchild instanceof ASTQuotedURIRef) {
            try {
              item=LiteralFactory.createURILiteralWithoutLazyLiteral("<"+ childchild.toString() + ">");
View Full Code Here

Examples of lupos.engine.operators.singleinput.Construct

    // first determine those operations, which generate triples of the result (and delete the other ones (and their preceding operators...))
    // also replace Construct operators with Generate operators!
    final LinkedList<Generate> listOfConstructedTripel = new LinkedList<Generate>();
    for(final BasicOperator bo: new LinkedList<BasicOperator>(resultInference.getPrecedingOperators())){
      if(bo instanceof Construct){
        final Construct construct = (Construct)bo;
        // split construct and replace them with Generate operators!
        for(final TriplePattern tp: construct.getTemplates()){
          final Generate generate = new Generate(tp);
          for(final BasicOperator father: construct.getPrecedingOperators()){
            father.addSucceedingOperator(generate);
            generate.addPrecedingOperator(father);
          }
          listOfConstructedTripel.add(generate);
          // remove old construct
          for(final BasicOperator father: new HashSet<BasicOperator>(construct.getPrecedingOperators())){
            father.removeSucceedingOperator(construct);
            construct.removePrecedingOperator(father);
          }
        }
      } else if(bo instanceof ConstructPredicate){
        final ConstructPredicate cp = (ConstructPredicate) bo;
        boolean toDelete = true;
View Full Code Here

Examples of lupos.gui.operatorgraph.visualeditor.queryeditor.operators.Construct

      }
    }
  }

  public Object visit(final ASTConstructQuery node, final Object data) {
    final Construct c = new Construct(this.prefix);

    this.handleWhereClause(node, c);

    this.handleDatasetClause(node, c);
    this.handleSolutionModifier(node, c);

    final OperatorContainer constructTemplateOp = (OperatorContainer) node
    .jjtGetChild(0).jjtAccept(this, data);
    c.addSucceedingOperator(new OperatorIDTuple<Operator>(constructTemplateOp, 0));

    return c;
  }
View Full Code Here

Examples of org.yaml.snakeyaml.constructor.Construct

        class TimeStampConstruct extends Constructor.ConstructScalar {
            @Override
            public Object construct(Node nnode) {
                if (nnode.getTag().equals("tag:yaml.org,2002:timestamp")) {
                    Construct dateConstructor = yamlConstructors.get(Tag.TIMESTAMP);
                    Date date = (Date) dateConstructor.construct(nnode);
                    return new DateTime(date, DateTimeZone.UTC);
                } else {
                    return super.construct(nnode);
                }
            }
View Full Code Here

Examples of org.yaml.snakeyaml.constructor.Construct

        class TimeStampConstruct extends Constructor.ConstructScalar {
            @Override
            public Object construct(Node nnode) {
                if (nnode.getTag().equals("tag:yaml.org,2002:timestamp")) {
                    Construct dateConstructor = yamlConstructors.get(Tag.TIMESTAMP);
                    Date date = (Date) dateConstructor.construct(nnode);
                    return new DateTime(date, DateTimeZone.UTC);
                } else {
                    return super.construct(nnode);
                }
            }
View Full Code Here

Examples of org.yaml.snakeyaml.constructor.Construct

                    // today's temperature is high :)
                    cl = EntityLoadingProxy.class;
                }
                node.setType(cl);
                // call the constructor as if the runtime class is defined
                Construct constructor = yamlClassConstructors.get(node.getNodeId());
                return constructor;
            }
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.