|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Ref<E>
The Ref is responsible for storing a value while providing transactional guarantees (failure atomicity, isolation)
Timed versions of the getOrAwait methods will be added in the near future.
| Method Summary | |
|---|---|
E |
clear()
Clears the value and returns the old value (could be null). |
E |
get()
Gets the current value stored in this reference. |
E |
getOrAwait()
Gets the current non null value, or waits until a non null value comes available. |
E |
getOrAwaitInterruptibly()
Gets the current non null value, or waits until a non null value becomes available or until it is is Interrupted. |
boolean |
isNull()
Checks if the value is null. |
E |
set(E newValue)
Sets the new value value. |
| Method Detail |
|---|
E get()
E getOrAwait()
E getOrAwaitInterruptibly()
throws java.lang.InterruptedException
java.lang.InterruptedException - if the thread is interrupted while waiting on a reference to come available.E set(E newValue)
newValue - the new value
E clear()
boolean isNull()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||