org.antlr.runtime.tree
Class TreeRewriter
java.lang.Object
org.antlr.runtime.BaseRecognizer
org.antlr.runtime.tree.TreeParser
org.antlr.runtime.tree.TreeRewriter
public class TreeRewriter
- extends TreeParser
Method Summary |
java.lang.Object |
applyOnce(java.lang.Object t,
TreeRewriter.fptr whichRule)
|
java.lang.Object |
applyRepeatedly(java.lang.Object t,
TreeRewriter.fptr whichRule)
|
java.lang.Object |
bottomup()
|
java.lang.Object |
downup(java.lang.Object t)
|
java.lang.Object |
downup(java.lang.Object t,
boolean showTransformations)
|
void |
reportTransformation(java.lang.Object oldTree,
java.lang.Object newTree)
Override this if you need transformation tracing to go somewhere
other than stdout or if you're not using Tree-derived trees. |
java.lang.Object |
topdown()
|
Methods inherited from class org.antlr.runtime.tree.TreeParser |
getCurrentInputSymbol, getErrorHeader, getErrorMessage, getMissingSymbol, getSourceName, getTreeNodeStream, matchAny, recoverFromMismatchedToken, reset, setTreeNodeStream, traceIn, traceOut |
Methods inherited from class org.antlr.runtime.BaseRecognizer |
alreadyParsedRule, beginResync, combineFollows, computeContextSensitiveRuleFOLLOW, computeErrorRecoverySet, consumeUntil, consumeUntil, displayRecognitionError, emitErrorMessage, endResync, failed, getBacktrackingLevel, getGrammarFileName, getNumberOfSyntaxErrors, getRuleInvocationStack, getRuleInvocationStack, getRuleMemoization, getRuleMemoizationCacheSize, getTokenErrorDisplay, getTokenNames, match, memoize, mismatchIsMissingToken, mismatchIsUnwantedToken, pushFollow, recover, recoverFromMismatchedSet, reportError, setBacktrackingLevel, toStrings, traceIn, traceOut |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
showTransformations
protected boolean showTransformations
originalTokenStream
protected TokenStream originalTokenStream
originalAdaptor
protected TreeAdaptor originalAdaptor
TreeRewriter
public TreeRewriter(TreeNodeStream input)
TreeRewriter
public TreeRewriter(TreeNodeStream input,
RecognizerSharedState state)
applyOnce
public java.lang.Object applyOnce(java.lang.Object t,
TreeRewriter.fptr whichRule)
applyRepeatedly
public java.lang.Object applyRepeatedly(java.lang.Object t,
TreeRewriter.fptr whichRule)
downup
public java.lang.Object downup(java.lang.Object t)
downup
public java.lang.Object downup(java.lang.Object t,
boolean showTransformations)
reportTransformation
public void reportTransformation(java.lang.Object oldTree,
java.lang.Object newTree)
- Override this if you need transformation tracing to go somewhere
other than stdout or if you're not using Tree-derived trees.
topdown
public java.lang.Object topdown()
throws RecognitionException
- Throws:
RecognitionException
bottomup
public java.lang.Object bottomup()
throws RecognitionException
- Throws:
RecognitionException
Copyright © 2013. All Rights Reserved.