|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.rice.cs.plt.iter.AbstractIterable<T>
edu.rice.cs.plt.collect.ConsList<T>
edu.rice.cs.plt.collect.ConsList.Empty<T>
public static class ConsList.Empty<T>
The empty variant of a ConsList. Instances are made available via make().
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class edu.rice.cs.plt.collect.ConsList |
|---|
ConsList.Empty<T>, ConsList.Nonempty<T> |
| Method Summary | ||
|---|---|---|
|
apply(ConsVisitor<? super T,? extends Ret> visitor)
Invoke the forEmpty case of a visitor |
|
boolean |
isEmpty()
Return true. |
|
java.util.Iterator<T> |
iterator()
Return an empty iterator |
|
static
|
make()
Creates an empty list. |
|
int |
size()
Return 0 |
|
int |
size(int bound)
Return 0 |
|
| Methods inherited from class edu.rice.cs.plt.collect.ConsList |
|---|
append, compositeHeight, compositeSize, cons, empty, filter, first, hasFixedSize, isInfinite, isStatic, map, rest, reverse, singleton |
| Methods inherited from class edu.rice.cs.plt.iter.AbstractIterable |
|---|
equals, hashCode, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Method Detail |
|---|
public static <T> ConsList.Empty<T> make()
public <Ret> Ret apply(ConsVisitor<? super T,? extends Ret> visitor)
forEmpty case of a visitor
apply in class ConsList<T>public java.util.Iterator<T> iterator()
iterator in interface java.lang.Iterable<T>iterator in class ConsList<T>public boolean isEmpty()
true.
isEmpty in interface SizedIterable<T>isEmpty in class ConsList<T>public int size()
0
size in interface SizedIterable<T>size in class ConsList<T>public int size(int bound)
0
size in interface SizedIterable<T>size in class ConsList<T>bound - Maximum result. Assumed to be nonnegative.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||