Package org.jgroups.protocols
Class COUNTER.VersionedValue
- java.lang.Object
-
- org.jgroups.protocols.COUNTER.VersionedValue
-
- Enclosing class:
- COUNTER
protected static class COUNTER.VersionedValue extends java.lang.Object
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
VersionedValue(long value)
protected
VersionedValue(long value, long version)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected long[]
addAndGet(long num)
num == 0 --> GETprotected long[]
compareAndSet(long expected, long update)
protected long[]
set(long value)
java.lang.String
toString()
protected void
updateIfBigger(long value, long version)
Sets the value only if the version argument is greater than the own version
-
-
-
Method Detail
-
addAndGet
protected long[] addAndGet(long num)
num == 0 --> GET
-
set
protected long[] set(long value)
-
compareAndSet
protected long[] compareAndSet(long expected, long update)
-
updateIfBigger
protected void updateIfBigger(long value, long version)
Sets the value only if the version argument is greater than the own version
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-