Package pddl4j.exp.term

Examples of pddl4j.exp.term.Constant


        PropositionImpl proposition = new PropositionImpl(!negated, p.getPredicate());
        Iterator variables = p.iterator();
       
        List<Term> terms = new ArrayList<Term>();
        while(variables.hasNext()){
          Constant var = (Constant) variables.next();
          Atom term = new Atom(var.getImage());
          terms.add(term);
         
          Set<String> setVar = this.types.get(var.getTypeSet().toString());
          setVar.add(var.getImage());
        }
       
        proposition.addTerms(terms);
        initialState.add(proposition);
      }
View Full Code Here


       
        Iterator constants = p.iterator();
       
        List<Term> terms = new ArrayList<Term>();
        while(constants.hasNext()){
          Constant con = (Constant) constants.next();
          Atom term = new Atom(con.getImage());
          terms.add(term);
         
          Set<String> setCon = this.types.get(con.getTypeSet().toString());
         
          for(Constant c: this.pddlObject.getTypedDomain(con.getTypeSet())){
            if(setCon == null){
              setCon = new HashSet<String>();
              setCon.add(c.toString());
              this.types.put(con.getTypeSet().toString(), setCon);
            } else setCon.add(c.toString());
          }
        }
       
        proposition.addTerms(terms);
View Full Code Here

TOP

Related Classes of pddl4j.exp.term.Constant

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.