FreezableAtomicReference

Native
1.3
class FreezableAtomicReference<T>
(source)
Deprecated: Use kotlin.concurrent.AtomicReference instead.

This class was useful only with legacy memory manager. Please use AtomicReference instead.

Constructors

Native
1.3

<init>

This class was useful only with legacy memory manager. Please use AtomicReference instead.

FreezableAtomicReference(value: T)

Properties

Native
1.3

value

var value: T

Functions

Native
1.3

compareAndSet

Atomically sets the value to the given new value if the current value equals the expected value and returns true if operation was successful.

fun compareAndSet(expected: T, newValue: T): Boolean
Native
1.3

compareAndSwap

Atomically sets the value to the given new value if the current value equals the expected value and returns the old value in any case.

fun compareAndSwap(expected: T, newValue: T): T
Native
1.3

toString

Returns the string representation of this object.

fun toString(): String