| Constructor Summary |
|---|
|
Creates a new AtomicLong with the given initial value. |
|
Creates a new AtomicLong with initial value 0 . |
| Method Summary | |
|---|---|
| final long |
Atomically adds the given value to the current value. |
| final boolean |
Atomically sets the value to the given updated value if the current value == the expected value. |
| final long |
Atomically decrements by one the current value. |
| double |
No description provided. |
| float |
No description provided. |
| final long |
Gets the current value. |
| final long |
Atomically adds the given value to the current value. |
| final long |
Atomically decrements by one the current value. |
| final long |
Atomically increments by one the current value. |
| final long |
Atomically sets to the given value and returns the old value. |
| final long |
Atomically increments by one the current value. |
| int |
No description provided. |
| final void |
Eventually sets to the given value. |
| long |
No description provided. |
| final void |
Sets to the given value. |
| String |
Returns the String representation of the current value. |
| final boolean |
Atomically sets the value to the given updated value if the current value == the expected value. |
| Methods inherited from java.langNumber |
|---|
| Methods inherited from java.langObject |
|---|
public AtomicLong
(
long
initialValue
)
public AtomicLong
(
)
public final
long
addAndGet
(
long
delta
)
public final
boolean
compareAndSet
(
long
expect,
long
update
)
public final
long
decrementAndGet
(
)
public
double
doubleValue
(
)
public
float
floatValue
(
)
public final
long
getAndAdd
(
long
delta
)
public final
long
getAndDecrement
(
)
public final
long
getAndIncrement
(
)
public final
long
getAndSet
(
long
newValue
)
public final
long
incrementAndGet
(
)
public
int
intValue
(
)
public final
void
lazySet
(
long
newValue
)
public
long
longValue
(
)
public final
boolean
weakCompareAndSet
(
long
expect,
long
update
)
May fail spuriously and does not provide ordering guarantees, so is only rarely an appropriate alternative to compareAndSet .