java.lang.Objectantlr.GrammarElement
antlr.AlternativeElement
antlr.AlternativeBlock
antlr.RuleBlock
A list of alternatives and info contained in the rule definition.
Field Summary | |
static int |
AUTO_GEN_BANG
|
static int |
AUTO_GEN_CARET
|
static int |
AUTO_GEN_NONE
|
Constructor Summary | |
RuleBlock(Grammar g,
java.lang.String r)
Construct a named rule. |
|
RuleBlock(Grammar g,
java.lang.String r,
int line,
boolean doAutoGen_)
Construct a named rule with line number information |
Method Summary | |
void |
addAlternative(antlr.Alternative alt)
|
void |
addExceptionSpec(antlr.ExceptionSpec ex)
|
antlr.ExceptionSpec |
findExceptionSpec(java.lang.String label)
|
antlr.ExceptionSpec |
findExceptionSpec(Token label)
|
void |
generate()
|
antlr.Alternative |
getAlternativeAt(int i)
|
Vector |
getAlternatives()
|
boolean |
getAutoGen()
|
int |
getAutoGenType()
|
int |
getColumn()
|
boolean |
getDefaultErrorHandler()
|
antlr.RuleEndElement |
getEndElement()
|
java.lang.String |
getIgnoreRule()
|
java.lang.String |
getInitAction()
|
java.lang.String |
getLabel()
|
int |
getLine()
|
java.lang.String |
getRuleName()
|
boolean |
getTestLiterals()
|
boolean |
isLexerAutoGenRule()
|
Lookahead |
look(int k)
|
void |
prepareForAnalysis()
|
void |
removeTrackingOfRuleRefs(Grammar g)
Walk the syntactic predicate and, for a rule ref R, remove the ref from the list of FOLLOW references for R (stored in the symbol table. |
void |
setAlternatives(Vector v)
|
void |
setAutoGen(boolean doAutoGen_)
|
void |
setAutoGenType(int a)
|
void |
setDefaultErrorHandler(boolean value)
|
void |
setEndElement(antlr.RuleEndElement re)
|
void |
setInitAction(java.lang.String initAction_)
|
void |
setLabel(java.lang.String label_)
|
void |
setOption(Token key,
Token value)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final int AUTO_GEN_NONE
public static final int AUTO_GEN_CARET
public static final int AUTO_GEN_BANG
Constructor Detail |
public RuleBlock(Grammar g, java.lang.String r)
public RuleBlock(Grammar g, java.lang.String r, int line, boolean doAutoGen_)
Method Detail |
public void addExceptionSpec(antlr.ExceptionSpec ex)
public antlr.ExceptionSpec findExceptionSpec(Token label)
public antlr.ExceptionSpec findExceptionSpec(java.lang.String label)
public void generate()
public boolean getDefaultErrorHandler()
public antlr.RuleEndElement getEndElement()
public java.lang.String getIgnoreRule()
public java.lang.String getRuleName()
public boolean getTestLiterals()
public boolean isLexerAutoGenRule()
public Lookahead look(int k)
public void prepareForAnalysis()
public void setDefaultErrorHandler(boolean value)
public void setEndElement(antlr.RuleEndElement re)
public void setOption(Token key, Token value)
public java.lang.String toString()
public void addAlternative(antlr.Alternative alt)
public antlr.Alternative getAlternativeAt(int i)
public Vector getAlternatives()
public boolean getAutoGen()
public java.lang.String getInitAction()
public java.lang.String getLabel()
public void removeTrackingOfRuleRefs(Grammar g)
public void setAlternatives(Vector v)
public void setAutoGen(boolean doAutoGen_)
public void setInitAction(java.lang.String initAction_)
public void setLabel(java.lang.String label_)
public int getAutoGenType()
public void setAutoGenType(int a)
public int getLine()
public int getColumn()