|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.google.common.util.concurrent.Atomics
@Beta public final class Atomics
Static utility methods pertaining to classes in the
java.util.concurrent.atomic
package.
Method Summary | ||
---|---|---|
static
|
newReference()
Creates an AtomicReference instance with no initial value. |
|
static
|
newReference(V initialValue)
Creates an AtomicReference instance with the given initial value. |
|
static
|
newReferenceArray(E[] array)
Creates an AtomicReferenceArray instance with the same length as,
and all elements copied from, the given array. |
|
static
|
newReferenceArray(int length)
Creates an AtomicReferenceArray instance of given length. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static <V> AtomicReference<V> newReference()
AtomicReference
instance with no initial value.
AtomicReference
with no initial valuepublic static <V> AtomicReference<V> newReference(@Nullable V initialValue)
AtomicReference
instance with the given initial value.
initialValue
- the initial value
AtomicReference
with the given initial valuepublic static <E> AtomicReferenceArray<E> newReferenceArray(int length)
AtomicReferenceArray
instance of given length.
length
- the length of the array
AtomicReferenceArray
with the given lengthpublic static <E> AtomicReferenceArray<E> newReferenceArray(E[] array)
AtomicReferenceArray
instance with the same length as,
and all elements copied from, the given array.
array
- the array to copy elements from
AtomicReferenceArray
copied from the given array
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |