|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object | +--ru.novosoft.dc.core.util.Toggles
The class contains an array of multistate toggles of the byte
type. The array length is specifed while constructing.
Two primitive operations, namely set and get,
are provided. The class allows the deep copy and deep compare operations.
| Constructor Summary | |
Toggles(byte[] toggles)
Construct an object as a wrapper of the specified array of toggles. |
|
Toggles(int size)
Construct an array of toggles of the specified size. |
|
| Method Summary | |
java.lang.Object |
clone()
Create a deep copy of this object. |
boolean |
equals(java.lang.Object obj)
Compare this object with another vector of toggles and return true if they coinside. |
int |
get(int index)
Return the toggle of the specified index. |
int |
set(int index,
int value)
Set a toggle of the specified index and return the original value (non-truncated to the byte type). |
int |
size()
Return a length of the array. |
byte[] |
toggles()
Return the array of toggles wrapped by this object. |
| Methods inherited from class java.lang.Object |
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Constructor Detail |
public Toggles(int size)
public Toggles(byte[] toggles)
| Method Detail |
public final int size()
public final byte[] toggles()
public final int get(int index)
public final int set(int index,
int value)
public java.lang.Object clone()
public boolean equals(java.lang.Object obj)
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||