|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object learner.RankedSymbol
public class RankedSymbol
The class RankedSymbol mimics the abstact data type ranked symbol, which consists of a symbol and a natural number. The number indicats how many subtrees a node labelled this symbol is expected to have.
Field Summary | |
---|---|
int |
rank
the rank, a natural number indicating the symbols arity |
java.lang.String |
symbol
the symbol itself |
Constructor Summary | |
---|---|
RankedSymbol(java.lang.String symbol,
int rank)
Constructs a ranked symbol, given an symbol and a rank. |
Method Summary | |
---|---|
java.lang.Object |
clone()
|
int |
compareTo(java.lang.Object o)
Comparasion function |
boolean |
equals(java.lang.Object object)
|
int |
hashCode()
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public java.lang.String symbol
public int rank
Constructor Detail |
---|
public RankedSymbol(java.lang.String symbol, int rank)
symbol
- Any String will due.rank
- a natural numberMethod Detail |
---|
public java.lang.Object clone()
clone
in class java.lang.Object
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public boolean equals(java.lang.Object object)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |