| Modifier and Type | Class and Description |
|---|---|
| pack-priv static class |
| Modifier and Type | Field and Description |
|---|---|
| protected Hashtable | |
| protected TNode | |
| protected TNode | |
| protected int | |
| protected boolean | |
| protected String | text
Hides antlr. |
| pack-priv static String | |
| protected int | ttype
Hides antlr. |
| protected TNode |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addSibling(final AST node)
add the new node as a new sibling, inserting it ahead of any existing next sibling. |
| public TNode | |
| public TNode | |
| public void | doubleLink()
set up reverse links between this node and its first child and its first sibling, and link those as well |
| public TNode | firstChildOfType(final int type)
find the first child of the node of the given type, return null on failure |
| public TNode | firstSiblingOfType(final int type)
find the first sibling of the node of the given type, return null on failure |
| public String | |
| private static void | |
| public ASTLocusTag | getASTLocusTag()
Implements com. ASTLocusTag, if available,
otherwise returns null.
|
| public Object | |
| public Hashtable | |
| public TNode | |
| public TNode | |
| public TNode | |
| public TNode | |
| public int | |
| public int | |
| public boolean | |
| public static String | |
| public TNode | |
| public String | getText()
Overrides antlr. Implements antlr. |
| public int | getType()
Overrides antlr. Implements antlr. |
| public void | initialize(final Token token)
Overrides antlr. Implements antlr. |
| public void | initialize(final AST tr)
Overrides antlr. Implements antlr. |
| public int | |
| public TNode | |
| protected static void | |
| public static void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | setText(final String text_)
Overrides antlr. Implements antlr. |
| public static void | setTokenVocabulary(final String s)
Set the token vocabulary to a tokentypes class generated by antlr. |
| public void | setType(final int ttype_)
Overrides antlr. Implements antlr. |
| public String | toString()
Overrides antlr. Implements antlr. |
| attributes | back to summary |
|---|---|
| protected Hashtable<String, Object> attributes | |
| defNode | back to summary |
|---|---|
| protected TNode defNode | |
| left | back to summary |
|---|---|
| protected TNode left | |
| lineNum | back to summary |
|---|---|
| protected int lineNum | |
| marker | back to summary |
|---|---|
| protected boolean marker | |
| text | back to summary |
|---|---|
| protected String text Hides antlr. | |
| tokenVocabulary | back to summary |
|---|---|
| pack-priv static String tokenVocabulary | |
| ttype | back to summary |
|---|---|
| protected int ttype Hides antlr. | |
| up | back to summary |
|---|---|
| protected TNode up | |
| TNode | back to summary |
|---|---|
| public TNode() | |
| addSibling | back to summary |
|---|---|
| public void addSibling(final AST node) add the new node as a new sibling, inserting it ahead of any existing next sibling. This method maintains double-linking. if node is null, nothing happens. If the node has siblings, then they are added in as well. | |
| deepCopy | back to summary |
|---|---|
| public TNode deepCopy() return a deep copy of this node, and all sub nodes. New tree is doubleLinked, with no parent or siblings. Marker value is not copied! | |
| deepCopyWithRightSiblings | back to summary |
|---|---|
| public TNode deepCopyWithRightSiblings() return a deep copy of this node, all sub nodes, and right siblings. New tree is doubleLinked, with no parent or left siblings. defNode is not copied | |
| doubleLink | back to summary |
|---|---|
| public void doubleLink() set up reverse links between this node and its first child and its first sibling, and link those as well | |
| firstChildOfType | back to summary |
|---|---|
| public TNode firstChildOfType(final int type) find the first child of the node of the given type, return null on failure | |
| firstSiblingOfType | back to summary |
|---|---|
| public TNode firstSiblingOfType(final int type) find the first sibling of the node of the given type, return null on failure | |
| getAllChildrenText | back to summary |
|---|---|
| public String getAllChildrenText(final String name) Returns the text for this node, its children and siblings. Implementation converts the AST LISP notation to serialized form. | |
| getAllChildrenText | back to summary |
|---|---|
| private static void getAllChildrenText(final StringBuilder buf, final TNode upNode, TNode thisNode) | |
| getASTLocusTag | back to summary |
|---|---|
| public ASTLocusTag getASTLocusTag() Implements com. Doc from com. Returns this instance's
If source is not available,
implementation returns
| |
| getAttribute | back to summary |
|---|---|
| public Object getAttribute(final String attrName) lookup the attribute name in the attribute table. If the value does not exist, it returns null. | |
| getAttributesTable | back to summary |
|---|---|
| public Hashtable get the hashtable that holds attribute values. | |
| getDefNode | back to summary |
|---|---|
| public TNode getDefNode() return the def node for this node | |
| getFirstSibling | back to summary |
|---|---|
| public TNode getFirstSibling() return the first sibling of this node, which is this if the prev sibling is null | |
| getLastChild | back to summary |
|---|---|
| public TNode getLastChild() return the last child of this node, or null if there is none | |
| getLastSibling | back to summary |
|---|---|
| public TNode getLastSibling() return the last sibling of this node, which is this if the next sibling is null | |
| getLineNum | back to summary |
|---|---|
| public int getLineNum() Get the line number for this node. If the line number is 0, search for a non-zero line num among children | |
| getLocalLineNum | back to summary |
|---|---|
| public int getLocalLineNum() | |
| getMarker | back to summary |
|---|---|
| public boolean getMarker() Get the marker value for this node. This member is a general-use marker. | |
| getNameForType | back to summary |
|---|---|
| public static String getNameForType(final int t) converts an int tree token type to a name. Does this by reflecting on nsdidl.IDLTreeTokenTypes, and is dependent on how ANTLR 2.00 outputs that class. | |
| getParent | back to summary |
|---|---|
| public TNode getParent() return the parent node of this node | |
| getText | back to summary |
|---|---|
| public String getText() Overrides antlr. Implements antlr. Get the token text for this node
| |
| getType | back to summary |
|---|---|
| public int getType() Overrides antlr. Implements antlr. Get the token type for this node
| |
| initialize | back to summary |
|---|---|
| public void initialize(final Token token) Overrides antlr. Implements antlr.
| |
| initialize | back to summary |
|---|---|
| public void initialize(final AST tr) Overrides antlr. Implements antlr.
| |
| numberOfChildren | back to summary |
|---|---|
| public int numberOfChildren() return the number of children of this node | |
| parentOfType | back to summary |
|---|---|
| public TNode parentOfType(final int type) find first parent of the given type, return null on failure | |
| printASTNode | back to summary |
|---|---|
| protected static void printASTNode(final AST t, final int indent) protected method that does the work of printing | |
| printTree | back to summary |
|---|---|
| public static void printTree(final AST t) print given tree to System.out | |
| removeSelf | back to summary |
|---|---|
| public void removeSelf() remove this node from the tree, resetting sibling and parent pointers as necessary. This method maintains double-linking | |
| setAttribute | back to summary |
|---|---|
| public void setAttribute(final String attrName, final Object value) set an attribute in the attribute table. | |
| setDefNode | back to summary |
|---|---|
| public void setDefNode(final TNode n) set the def node for this node | |
| setLineNum | back to summary |
|---|---|
| public void setLineNum(final int lineNum_) Set the line number for this node | |
| setMarker | back to summary |
|---|---|
| public void setMarker(final boolean marker_) Set the marker value for this node. This property is a general-use boolean marker. | |
| setText | back to summary |
|---|---|
| public void setText(final String text_) Overrides antlr. Implements antlr. Set the token text for this node
| |
| setTokenVocabulary | back to summary |
|---|---|
| public static void setTokenVocabulary(final String s) Set the token vocabulary to a tokentypes class generated by antlr. | |
| setType | back to summary |
|---|---|
| public void setType(final int ttype_) Overrides antlr. Implements antlr. Set the token type for this node
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides antlr. Implements antlr. return a short string representation of the node
| |
| Modifier and Type | Field and Description |
|---|---|
| protected int |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| private String | |
| pack-priv void |
| level | back to summary |
|---|---|
| protected int level | |
| DebugASTVisitor | back to summary |
|---|---|
| pack-priv DebugASTVisitor(final int level) | |
| tabs | back to summary |
|---|---|
| private String tabs(final StringBuilder sb) | |
| visit | back to summary |
|---|---|
| pack-priv void visit(final AST node) | |