|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.lang.Number net.lucidviews.util.VariableNumber net.lucidviews.util.VariableLong net.lucidviews.util.Counter
public class Counter
A number object used for counting.
VariableLong
,
Serialized FormConstructor Summary | |
---|---|
Counter()
Create a new counter. |
|
Counter(long value)
Create a new counter with a given initial value. |
|
Counter(Number value)
Create a new counter with a given initial value. |
Method Summary | |
---|---|
void |
decrement()
Decrement the value of this counter. |
void |
increment()
Increment the value of this counter. |
Methods inherited from class net.lucidviews.util.VariableLong |
---|
doubleValue, equals, floatValue, hashCode, intValue, longValue, setValueInternal, setValueInternal, setValueInternal, setValueInternal, toString |
Methods inherited from class net.lucidviews.util.VariableNumber |
---|
isSecure, secure, setValue, setValue, setValue, setValue, setValue, setValue, setValueInternal, setValueInternal, verifyNotSecure |
Methods inherited from class java.lang.Number |
---|
byteValue, shortValue |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Counter()
public Counter(long value)
value
- the initial valuepublic Counter(Number value)
value
- the initial value
NullPointerException
- if the initial value is null
Method Detail |
---|
public void increment()
IllegalStateException
- if this number is no longer in a variable
stateVariableNumber.secure
,
VariableNumber.secure()
public void decrement()
IllegalStateException
- if this number is no longer in a variable
stateVariableNumber.secure
,
VariableNumber.secure()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |