public class DefaultReferenceState<T> extends Object implements ReferenceState<T>
| Constructor and Description |
|---|
DefaultReferenceState() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
compareAndSet(T expect,
T update) |
T |
get() |
T |
getAndSet(T value) |
void |
init(net.kuujo.copycat.state.StateContext<ReferenceState<T>> context)
Initializes the state.
|
void |
set(T value) |
public void init(net.kuujo.copycat.state.StateContext<ReferenceState<T>> context)
ReferenceStateinit in interface ReferenceState<T>context - The state context.public T get()
get in interface ReferenceState<T>public void set(T value)
set in interface ReferenceState<T>public T getAndSet(T value)
getAndSet in interface ReferenceState<T>public boolean compareAndSet(T expect, T update)
compareAndSet in interface ReferenceState<T>Copyright © 2013-2015. All Rights Reserved.