

Public Member Functions | |
| CommonTree () | |
| CommonTree (CommonTree node) | |
| CommonTree (Token t) | |
| Token | getToken () |
| Tree | dupNode () |
| boolean | isNil () |
| int | getType () |
| String | getText () |
| int | getLine () |
| int | getCharPositionInLine () |
| int | getTokenStartIndex () |
| void | setTokenStartIndex (int index) |
| int | getTokenStopIndex () |
| void | setTokenStopIndex (int index) |
| int | getChildIndex () |
| Tree | getParent () |
| void | setParent (Tree t) |
| void | setChildIndex (int index) |
| String | toString () |
Public Attributes | |
| Token | token |
| CommonTree | parent |
| int | childIndex = -1 |
Protected Attributes | |
| int | startIndex = -1 |
| int | stopIndex = -1 |
Definition at line 38 of file CommonTree.java.
| org.antlr.runtime.tree.CommonTree.CommonTree | ( | ) |
Definition at line 53 of file CommonTree.java.
| org.antlr.runtime.tree.CommonTree.CommonTree | ( | CommonTree | node | ) |
Definition at line 55 of file CommonTree.java.
| org.antlr.runtime.tree.CommonTree.CommonTree | ( | Token | t | ) |
Definition at line 62 of file CommonTree.java.
| Token org.antlr.runtime.tree.CommonTree.getToken | ( | ) |
Definition at line 66 of file CommonTree.java.
| Tree org.antlr.runtime.tree.CommonTree.dupNode | ( | ) |
| boolean org.antlr.runtime.tree.CommonTree.isNil | ( | ) |
Indicates the node is a nil node but may still have children, meaning the tree is a flat list.
Reimplemented from org.antlr.runtime.tree.BaseTree.
Reimplemented in org.antlr.runtime.tree.CommonErrorNode.
Definition at line 74 of file CommonTree.java.
| int org.antlr.runtime.tree.CommonTree.getType | ( | ) |
Return a token type; needed for tree parsing
Implements org.antlr.runtime.tree.Tree.
Reimplemented in org.antlr.runtime.tree.CommonErrorNode.
Definition at line 78 of file CommonTree.java.
| String org.antlr.runtime.tree.CommonTree.getText | ( | ) |
Implements org.antlr.runtime.tree.Tree.
Reimplemented in org.antlr.runtime.tree.CommonErrorNode.
Definition at line 85 of file CommonTree.java.
| int org.antlr.runtime.tree.CommonTree.getLine | ( | ) |
In case we don't have a token payload, what is the line for errors?
Reimplemented from org.antlr.runtime.tree.BaseTree.
Definition at line 92 of file CommonTree.java.
| int org.antlr.runtime.tree.CommonTree.getCharPositionInLine | ( | ) |
| int org.antlr.runtime.tree.CommonTree.getTokenStartIndex | ( | ) |
What is the smallest token index (indexing from 0) for this node and its children?
Implements org.antlr.runtime.tree.Tree.
Definition at line 112 of file CommonTree.java.
| void org.antlr.runtime.tree.CommonTree.setTokenStartIndex | ( | int | index | ) |
| int org.antlr.runtime.tree.CommonTree.getTokenStopIndex | ( | ) |
What is the largest token index (indexing from 0) for this node and its children?
Implements org.antlr.runtime.tree.Tree.
Definition at line 123 of file CommonTree.java.
| void org.antlr.runtime.tree.CommonTree.setTokenStopIndex | ( | int | index | ) |
| int org.antlr.runtime.tree.CommonTree.getChildIndex | ( | ) |
BaseTree doesn't track child indexes.
Reimplemented from org.antlr.runtime.tree.BaseTree.
Definition at line 134 of file CommonTree.java.
| Tree org.antlr.runtime.tree.CommonTree.getParent | ( | ) |
BaseTree doesn't track parent pointers.
Reimplemented from org.antlr.runtime.tree.BaseTree.
Definition at line 138 of file CommonTree.java.
| void org.antlr.runtime.tree.CommonTree.setParent | ( | Tree | t | ) |
| void org.antlr.runtime.tree.CommonTree.setChildIndex | ( | int | index | ) |
| String org.antlr.runtime.tree.CommonTree.toString | ( | ) | [virtual] |
Override to say how a node (not a tree) should look as text
Implements org.antlr.runtime.tree.BaseTree.
Reimplemented in org.antlr.runtime.tree.CommonErrorNode, and org.antlr.runtime.tree.TreeWizard.TreePattern.
Definition at line 150 of file CommonTree.java.
A single token is the payload
Definition at line 40 of file CommonTree.java.
int org.antlr.runtime.tree.CommonTree.startIndex = -1 [protected] |
What token indexes bracket all tokens associated with this node and below?
Definition at line 45 of file CommonTree.java.
int org.antlr.runtime.tree.CommonTree.stopIndex = -1 [protected] |
Definition at line 45 of file CommonTree.java.
Who is the parent node of this node; if null, implies node is root
Definition at line 48 of file CommonTree.java.
What index is this node in the child list? Range: 0..n-1
Definition at line 51 of file CommonTree.java.
1.5.5