|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object orc.runtime.values.Value
public abstract class Value
A fully evaluated Orc value. This includes sites, tuples, lists, and so on. However, it does not include unbound or partially-bound values, which are instead in the broader category of Futures.
Field Summary | |
---|---|
static Callable |
futureNotReady
Distinguished value used to indicate that a forced value is not ready. |
Constructor Summary | |
---|---|
Value()
|
Method Summary | ||
---|---|---|
|
accept(Visitor<E> visitor)
|
|
static java.lang.Object |
forceArg(java.lang.Object f,
Token t)
Force a value (which may be a future) in argument position. |
|
static Callable |
forceCall(java.lang.Object f,
Token t)
Force a value (which may be a future) in call position. |
|
static Value |
signal()
Static function to access the canonical 'unit' value; currently, the signal value is an empty tuple. |
|
static java.lang.String |
write(java.lang.Object v)
Convert any object to its string representation; the inverse of Read . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final Callable futureNotReady
Constructor Detail |
---|
public Value()
Method Detail |
---|
public static Callable forceCall(java.lang.Object f, Token t) throws UncallableValueException
futureNotReady
and place the token on a
waiting list to be reactivated when the future is ready.
The primary reason to distinguish call and argument values is that a closure is allowed to have unforced free values in call position, but not in argument position (lest those unforced free values escape their lexical context).
UncallableValueException
public static java.lang.Object forceArg(java.lang.Object f, Token t)
futureNotReady
and place the token on
a waiting list to be reactivated when the future is ready.
public static Value signal()
public <E> E accept(Visitor<E> visitor)
public static java.lang.String write(java.lang.Object v)
Read
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |