|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.util.MuBoolean
A mutable boolean class.
Constructor Summary | |
MuBoolean()
Construct a new mutable boolean. |
|
MuBoolean(boolean b)
Construct a new mutable boolean. |
|
MuBoolean(Object obj)
Construct a new mutable boolean. |
|
MuBoolean(String value)
Construct a new mutable boolean. |
Method Summary | |
boolean |
and(boolean b)
ANDs the current value with the specified value. |
boolean |
booleanValue()
Return the value of this mutable boolean. |
Object |
clone()
Clone this mutable boolean. |
boolean |
commit(boolean assumed,
boolean b)
Set the value to value only if the current value is equal to the assumed value. |
int |
compareTo(boolean bool)
Compares this object with the specified boolean for order. |
int |
compareTo(Object obj)
Compares this object with the specified object for order. |
boolean |
complement()
Set the value to its complement. |
boolean |
equals(Object obj)
Test the equality of another object. |
boolean |
get()
Get the current value. |
Object |
getValue()
Get the boolean value of this mutable boolean. |
int |
hashCode()
Return the hash code for this mutable boolean. |
boolean |
or(boolean b)
ORs the current value with the specified value. |
boolean |
set(boolean b)
Set the value. |
boolean |
set(Boolean b)
Set the value. |
boolean |
set(MuBoolean b)
Set the value. |
void |
setValue(Object obj)
Set the value of this mutable boolean. |
boolean |
swap(MuBoolean b)
Swap values with another mutable boolean. |
String |
toString()
Convert to a string. |
boolean |
xor(boolean b)
XORs the current value with the specified value. |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public MuBoolean()
public MuBoolean(boolean b)
b
- Boolean value.public MuBoolean(Object obj)
obj
- Object to convert to a boolean value.public MuBoolean(String value)
value
- String to convert to a boolean value.Method Detail |
public boolean booleanValue()
public boolean set(boolean b)
b
- Boolean value.
public boolean set(Boolean b)
b
- Boolean value.
public boolean set(MuBoolean b)
b
- Boolean value.
public boolean get()
public boolean commit(boolean assumed, boolean b)
assumed
- The assumed value.b
- The new value.
public boolean swap(MuBoolean b)
b
- Mutable boolean to swap values with.
public boolean complement()
public boolean and(boolean b)
b
- Value to and with.
public boolean or(boolean b)
b
- Value to or with.
public boolean xor(boolean b)
b
- Value to xor with.
public int compareTo(boolean bool)
bool
- Boolean to compare with.
public int compareTo(Object obj) throws ClassCastException
compareTo
in interface Comparable
ClassCastException
- Object is not a MuBoolean.public String toString()
public int hashCode()
public boolean equals(Object obj)
obj
- Object to test equality with.
public Object clone()
public void setValue(Object obj)
If value is a java.lang.Boolean
, then use
Boolean.booleanValue()
to determin value, if
the object is non-null then the value is true, else
it is false.
obj
- Object to convert to a boolean value.public Object getValue()
java.lang.Boolean
value.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |