orc.runtime.values
Class ListValue
java.lang.Object
orc.runtime.values.Value
orc.runtime.values.ListValue
- All Implemented Interfaces:
- java.lang.Iterable, Future
- Direct Known Subclasses:
- ConsValue, NilValue
public abstract class ListValue
- extends Value
- implements java.lang.Iterable
Common ancestor for ConsValue and NilValue. Unlike scheme, the Cons
constructor does not allow you to create a degenerate cons where
the tail is not a list, so we can guarantee that all Conses actually
have a list structure. (If you want a degenerate cons, just use a
tuples.)
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ListValue
public ListValue()
enlist
public abstract java.util.List<Value> enlist()
make
public static ListValue make(java.util.List<Value> vs)
iterator
public java.util.Iterator iterator()
- Specified by:
iterator
in interface java.lang.Iterable
accept
public <E> E accept(Visitor<E> visitor)
- Specified by:
accept
in class Value