InterpreterRuleContext that knows which alternative
for a rule was matched.
GrammarParserInterpreter
| Modifier and Type | Field and Description |
|---|---|
| protected int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public int | getAltNumber()
For rule associated with this parse tree internal node, return
the outer alternative number used to match the input.
|
| public int | getOuterAltNum()
The predicted outermost alternative for the rule associated with this context object. |
| public void | setAltNumber(int altNumber)
Set the outer alternative number for this context node.
|
| public void |
| outerAltNum | back to summary |
|---|---|
| protected int outerAltNum | |
| GrammarInterpreterRuleContext | back to summary |
|---|---|
| public GrammarInterpreterRuleContext(ParserRuleContext parent, int invokingStateNumber, int ruleIndex) | |
| getAltNumber | back to summary |
|---|---|
| public int getAltNumber() Overrides org. Doc from org. For rule associated with this parse tree internal node, return the outer alternative number used to match the input. Default implementation does not compute nor store this alt num. Create a subclass of ParserRuleContext with backing field and set option contextSuperClass. to set it.
| |
| getOuterAltNum | back to summary |
|---|---|
| public int getOuterAltNum() The predicted outermost alternative for the rule associated with this context object. If this node left recursive, the true original outermost alternative is returned. | |
| setAltNumber | back to summary |
|---|---|
| public void setAltNumber(int altNumber) Overrides org. Doc from org. Set the outer alternative number for this context node. Default implementation does nothing to avoid backing field overhead for trees that don't need it. Create a subclass of ParserRuleContext with backing field and set option contextSuperClass.
| |
| setOuterAltNum | back to summary |
|---|---|
| public void setOuterAltNum(int outerAltNum) | |