|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
ObjectCons
Partial support for cons, the basic data structure in
Lisp.
Defines equals(java.lang.Object) on conses to mean the corresponding
members are equal recursively, like Lisp's equal.
| Constructor Summary | |
Cons(Object car_,
Object cdr_)
|
|
| Method Summary | |
Object |
car()
Returns the first element of the cons. |
Object |
cdr()
Returns the second element of the cons. |
boolean |
equals(Object o)
Like Lisp's equal, this tests for equality of the
members. |
int |
hashCode()
Consistent with equals(java.lang.Object). |
void |
rplaca(Object newCar)
Resets the first element of the cons. |
void |
rplacd(Object newCdr)
Resets the second element of the cons. |
String |
toString()
|
| Methods inherited from class Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Cons(Object car_,
Object cdr_)
| Method Detail |
public final Object car()
public final Object cdr()
public void rplaca(Object newCar)
public void rplacd(Object newCdr)
public boolean equals(Object o)
equal, this tests for equality of the
members.
public int hashCode()
equals(java.lang.Object).
public String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||