|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectJet.Parser.Edge
Jet.Parser.ParseTreeNode
a node of a parse tree.
| Field Summary | |
Annotation |
ann
for leaf nodes, the (token or constit) annotation matched by this node. |
int |
head
for non-leaf nodes, the number of the child (starting at 1) which is the head of this node. |
java.lang.String |
word
for leaf nodes, the word matched by this node. |
| Fields inherited from class Jet.Parser.Edge |
category, children, end, start |
| Constructor Summary | |
ParseTreeNode(java.lang.Object category,
ParseTreeNode[] children,
int start,
int end,
Annotation ann,
java.lang.String word)
|
|
ParseTreeNode(java.lang.Object category,
ParseTreeNode[] children,
int start,
int end,
int head)
|
|
| Method Summary | |
static Annotation[] |
children(Annotation node)
returns an array containing the children of 'node', or null if the node has no children. |
static Annotation |
makeParseAnnotations(Document doc,
ParseTreeNode n)
given a parse tree in the form of nested ParseTreeNodes, adds an Annotation of type 'constit' to Document 'doc' for each non-terminal node in the tree. |
void |
printTree()
prints the parse tree rooted at this node in an indented form. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public Annotation ann
public java.lang.String word
public int head
| Constructor Detail |
public ParseTreeNode(java.lang.Object category,
ParseTreeNode[] children,
int start,
int end,
Annotation ann,
java.lang.String word)
public ParseTreeNode(java.lang.Object category,
ParseTreeNode[] children,
int start,
int end,
int head)
| Method Detail |
public java.lang.String toString()
public void printTree()
public static Annotation makeParseAnnotations(Document doc,
ParseTreeNode n)
public static Annotation[] children(Annotation node)
node - an Annotation representing a parse tree node
(an Annotation of type 'constit').
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||