Op.java
Go to the documentation of this file.
00001 /*
00002  * Copyright Dept. of Mathematics & Computer Science Univ. Paris-Descartes
00003  *
00004  * This software is governed by the CeCILL  license under French law and
00005  * abiding by the rules of distribution of free software.  You can  use,
00006  * modify and/ or redistribute the software under the terms of the CeCILL
00007  * license as circulated by CEA, CNRS and INRIA at the following URL
00008  * "http://www.cecill.info".
00009  *
00010  * As a counterpart to the access to the source code and  rights to copy,
00011  * modify and redistribute granted by the license, users are provided only
00012  * with a limited warranty  and the software's author,  the holder of the
00013  * economic rights,  and the successive licensors  have only  limited
00014  * liability.
00015  *
00016  * In this respect, the user's attention is drawn to the risks associated
00017  * with loading,  using,  modifying and/or developing or reproducing the
00018  * software by the user in light of its specific status of free software,
00019  * that may mean  that it is complicated to manipulate,  and  that  also
00020  * therefore means  that it is reserved for developers  and  experienced
00021  * professionals having in-depth computer knowledge. Users are therefore
00022  * encouraged to load and test the software's suitability as regards their
00023  * requirements in conditions enabling the security of their systems and/or
00024  * data to be ensured and,  more generally, to use and operate it in the
00025  * same conditions as regards security.
00026  *
00027  * The fact that you are presently reading this means that you have had
00028  * knowledge of the CeCILL license and that you accept its terms.
00029  */
00030 
00031 //package pddl4j.graphplan;
00032 
00033 import java.util.BitSet;
00034 
00035 import pddl4j.exp.AtomicFormula;
00036 
00044 public final class Op {
00045 
00049     private AtomicFormula name;
00050 
00054     private BitSet pp;
00055 
00059     private BitSet np;
00060 
00064     private BitSet pe;
00065 
00069     private BitSet ne;
00070 
00074     private int id;
00075 
00080     private int level;
00081 
00092     public Op(AtomicFormula name, BitSet pp, BitSet np, BitSet pe, BitSet ne,
00093                 int id) {
00094         this.name = name;
00095         this.pp = pp;
00096         this.np = np;
00097         this.pe = pe;
00098         this.ne = ne;
00099         this.id = id;
00100         this.level = -1;
00101     }
00102 
00108     public int getLevel() {
00109         return level;
00110     }
00111 
00117     public void setLevel(int level) {
00118         this.level = level;
00119     }
00120 
00126     public int getId() {
00127         return id;
00128     }
00129 
00135     public BitSet getPositiveEffect() {
00136         return this.pe;
00137     }
00138 
00144     public BitSet getNegativeEffect() {
00145         return this.ne;
00146     }
00147 
00153     public BitSet getNegativePrecondition() {
00154         return this.np;
00155     }
00156 
00162     public BitSet getPositivePreconditon() {
00163         return this.pp;
00164     }
00165 
00171     public AtomicFormula getName() {
00172         return this.name;
00173     }
00174 
00184     public boolean equals(Object obj) {
00185         if (obj != null && this.getClass().equals(obj.getClass())) {
00186             Op other = (Op) obj;
00187             return this.name.equals(other.name);
00188         }
00189         return false;
00190     }
00191     
00199     public int hashCode() {
00200         return this.name.hashCode();
00201     }
00202 
00203 }


tug_ist_diagnosis_repair
Author(s): Safdar Zaman
autogenerated on Mon Jan 6 2014 11:51:12