private static class LongCounter.Wrapper extends LongCounter
| Modifier and Type | Field and Description |
|---|---|
protected LongCounter |
counter
The wrapped counter
|
private static long |
serialVersionUID
The serialVersionUID
|
| Constructor and Description |
|---|
Wrapper(LongCounter counter) |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Return a cloned copy of this object.
|
long |
decrement()
Decrement the counter.
|
boolean |
equals(java.lang.Object obj)
Check if the given object is equal to this.
|
long |
getCount()
Return the current value of the counter.
|
long |
increment()
Increment the counter.
|
void |
reset()
Reset the counter to zero.
|
java.lang.String |
toString()
Return a string representation of this.
|
makeDirectional, makeSynchronizedprivate static final long serialVersionUID
protected final LongCounter counter
public Wrapper(LongCounter counter)
public long increment()
LongCounterincrement in class LongCounterpublic long decrement()
LongCounterdecrement in class LongCounterpublic long getCount()
LongCountergetCount in class LongCounterpublic void reset()
LongCounterreset in class LongCounterpublic boolean equals(java.lang.Object obj)
LongCounterequals in class LongCounterobj - Object to test equality with.public java.lang.String toString()
LongCountertoString in class LongCounterpublic java.lang.Object clone()
LongCounterclone in class LongCounter