AtomicReference<(Of <(<'T>)>)>..::..CompareAndSet Method

If Value equals [expected], then set the Value to [newValue]. Returns true if [newValue] was set, false otherise.

Namespace:  Akka.Util
Assembly:  Akka (in Akka.dll)

Syntax


public bool CompareAndSet(
	T expected,
	T newValue
)
Public Function CompareAndSet ( _
	expected As T, _
	newValue As T _
) As Boolean
public:
bool^ CompareAndSet(
	T expected, 
	T newValue
)

Parameters

expected
Type: T
newValue
Type: T