| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | add(int
the delta to apply to the hi value deltaHi, int the delta to apply to the lo value deltaLo)Atomically adds the given deltas to the current hi and lo values. |
| public int | Returns: the updated hi valuethe delta to apply delta)Atomically adds the given delta to the current hi value, returning the updated hi value. |
| public int | Returns: the updated lo valuethe delta to apply delta)Atomically adds the given delta to the current lo value, returning the updated lo value. |
| public boolean | Returns: true if successful. False return indicates that
the actual encoded value was not equal to the expected encoded value.the expected encoded value encoded, int the new hi value hi, int the new lo value lo)Atomically sets the values to the given updated values only if
the current encoded value |
| public boolean | Returns: true if successful. False return indicates that
the actual hi and lo values were not equal to the expected hi and lo value.the expected hi value expectHi, int the new hi value hi, int the expected lo value expectLo, int the new lo value lo)Atomically sets the hi and lo values to the given updated values only if
the current hi and lo values |
| public boolean | Returns: true if successful. False return indicates that
the actual hi value was not equal to the expected hi value.the expected hi value expectHi, int the new hi value hi)Atomically sets the hi value to the given updated value
only if the current value |
| public boolean | Returns: true if successful. False return indicates that
the actual lo value was not equal to the expected lo value.the expected lo value expectLo, int the new lo value lo)Atomically sets the lo value to the given updated value
only if the current value |
| public static long | Returns: the encoded valuethe hi value hi, int the lo value lo)Encodes hi and lo values into a long. |
| public static long | Returns: the new encoded valuethe encoded value encoded, int the hi value hi)Sets the hi value into the given encoded value. |
| public static long | Returns: the new encoded valuethe encoded value encoded, int the lo value lo)Sets the lo value into the given encoded value. |
| public int | Returns: the previous hi valuethe new hi value hi)Atomically sets the hi value without changing the lo value. |
| public int | Returns: the previous lo valuethe new lo value lo)Atomically sets the lo value without changing the hi value. |
| public int | |
| public static int | Returns: the hi valuethe encoded value encoded)Gets a hi value from the given encoded value. |
| public int | |
| public static int | Returns: the lo valuethe encoded value encoded)Gets a lo value from the given encoded value. |
| public void | |
| public String | toString()
Overrides java. Returns the String representation of the current value. |
| AtomicBiInteger | back to summary |
|---|---|
| public AtomicBiInteger() | |
| AtomicBiInteger | back to summary |
|---|---|
| public AtomicBiInteger(long encoded) | |
| AtomicBiInteger | back to summary |
|---|---|
| public AtomicBiInteger(int hi, int lo) | |
| add | back to summary |
|---|---|
| public void add(int deltaHi, int deltaLo) Atomically adds the given deltas to the current hi and lo values.
| |
| addAndGetHi | back to summary |
|---|---|
| public int addAndGetHi(int delta) Atomically adds the given delta to the current hi value, returning the updated hi value.
| |
| addAndGetLo | back to summary |
|---|---|
| public int addAndGetLo(int delta) Atomically adds the given delta to the current lo value, returning the updated lo value.
| |
| compareAndSet | back to summary |
|---|---|
| public boolean compareAndSet(long encoded, int hi, int lo) Atomically sets the values to the given updated values only if
the current encoded value
| |
| compareAndSet | back to summary |
|---|---|
| public boolean compareAndSet(int expectHi, int hi, int expectLo, int lo) Atomically sets the hi and lo values to the given updated values only if
the current hi and lo values
| |
| compareAndSetHi | back to summary |
|---|---|
| public boolean compareAndSetHi(int expectHi, int hi) Atomically sets the hi value to the given updated value
only if the current value Concurrent changes to the lo value result in a retry.
| |
| compareAndSetLo | back to summary |
|---|---|
| public boolean compareAndSetLo(int expectLo, int lo) Atomically sets the lo value to the given updated value
only if the current value Concurrent changes to the hi value result in a retry.
| |
| encode | back to summary |
|---|---|
| public static long encode(int hi, int lo) Encodes hi and lo values into a long.
| |
| encodeHi | back to summary |
|---|---|
| public static long encodeHi(long encoded, int hi) Sets the hi value into the given encoded value.
| |
| encodeLo | back to summary |
|---|---|
| public static long encodeLo(long encoded, int lo) Sets the lo value into the given encoded value.
| |
| getAndSetHi | back to summary |
|---|---|
| public int getAndSetHi(int hi) Atomically sets the hi value without changing the lo value.
| |
| getAndSetLo | back to summary |
|---|---|
| public int getAndSetLo(int lo) Atomically sets the lo value without changing the hi value.
| |
| getHi | back to summary |
|---|---|
| public int getHi() Get the hi value.
| |
| getHi | back to summary |
|---|---|
| public static int getHi(long encoded) Gets a hi value from the given encoded value.
| |
| getLo | back to summary |
|---|---|
| public int getLo() Get the lo value.
| |
| getLo | back to summary |
|---|---|
| public static int getLo(long encoded) Gets a lo value from the given encoded value.
| |
| set | back to summary |
|---|---|
| public void set(int hi, int lo) Sets the hi and lo values.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns the String representation of the current value. | |