Atomically sets the field of the given object managed by this updater
to the given updated value if the current value == the
expected value. This method is guaranteed to be atomic with respect to
other calls to compareAndSet and set, but not
necessarily with respect to other changes in the field.
obj | An object whose field to conditionally set | |
expect | the expected value | |
update | the new value |
true if successful
Diagram: AtomicFieldUpdater