antlr

Class ParseTreeRule

public class ParseTreeRule extends ParseTree

Field Summary
protected intaltNumber
static intINVALID_ALT
protected StringruleName
Constructor Summary
ParseTreeRule(String ruleName)
ParseTreeRule(String ruleName, int altNumber)
Method Summary
protected intgetLeftmostDerivation(StringBuffer buf, int step)
Do a step-first walk, building up a buffer of tokens until you've reached a particular step and print out any rule subroots insteads of descending.
StringgetRuleName()
StringtoString()

Field Detail

altNumber

protected int altNumber

INVALID_ALT

public static final int INVALID_ALT

ruleName

protected String ruleName

Constructor Detail

ParseTreeRule

public ParseTreeRule(String ruleName)

ParseTreeRule

public ParseTreeRule(String ruleName, int altNumber)

Method Detail

getLeftmostDerivation

protected int getLeftmostDerivation(StringBuffer buf, int step)
Do a step-first walk, building up a buffer of tokens until you've reached a particular step and print out any rule subroots insteads of descending.

getRuleName

public String getRuleName()

toString

public String toString()