View Javadoc

1   // IRBoolean.java, created Jul 7, 2004 11:50:51 PM by joewhaley
2   // Copyright (C) 2004 John Whaley <jwhaley@alum.mit.edu>
3   // Licensed under the terms of the GNU LGPL; see COPYING for details.
4   package net.sf.bddbddb.ir.dynamic;
5   
6   /***
7    * IRBoolean
8    * 
9    * @author John Whaley
10   * @version $Id: IRBoolean.java 328 2004-10-16 02:45:30Z joewhaley $
11   */
12  public class IRBoolean {
13      boolean bool;
14      String name;
15  
16      public IRBoolean(String name, boolean bool) {
17          this.name = name;
18          this.bool = bool;
19      }
20  
21      /*
22       * (non-Javadoc)
23       * 
24       * @see java.lang.Object#toString()
25       */
26      public String toString() {
27          return name + "(" + Boolean.toString(bool) + ")";
28      }
29  
30      /***
31       * @return the value of this boolean
32       */
33      public boolean value() {
34          return bool;
35      }
36  
37      /***
38       * @param bool
39       */
40      public void set(boolean bool) {
41          this.bool = bool;
42      }
43  
44      /***
45       * @return the name of this boolean
46       */
47      public String getName() {
48          return name;
49      }
50  }