Interface PartialParseTreeListener
- All Superinterfaces:
ParseTreeListener
- All Known Implementing Classes:
HandlerTarget,HandlerTargetImpl,ParsedReplaceTarget,ParsedReplaceTargetImpl,ProxyParseTreeListener,ReplaceTarget,RunPhase,SearchTerminals,SearchTerminalsDynamic,SearchTerminalsImpl,TerminalReplaceTarget,TerminalReplaceTargetImpl,ThrowTarget,ThrowTargetImpl,TransformationPhase,WalkPhase,WrapThrowTarget,WrapThrowTargetImpl
Adds a method to the parse tree listener with which the parse tree walker can
detect if it should stop walking the tree.
-
Method Summary
Modifier and TypeMethodDescriptiondefault booleanisDeepEnough(ExtendedContext node) Returns if this parse tree listener wants to continue to walk the tree but not go any deeper into the current (given) rule.default booleanReturns if this parse tree listener is no longer interested in walking the tree.Methods inherited from interface org.antlr.v4.runtime.tree.ParseTreeListener
enterEveryRule, exitEveryRule, visitErrorNode, visitTerminal
-
Method Details
-
isFinished
default boolean isFinished()Returns if this parse tree listener is no longer interested in walking the tree.- Returns:
trueif the parse tree walker should stop walking the tree entirely.- API Usage Note:
- This method will be called at every level of the tree as the parse tree walker decides whether or not to continue iterating the children of each node.
-
isDeepEnough
Returns if this parse tree listener wants to continue to walk the tree but not go any deeper into the current (given) rule.- Parameters:
node- The current node in which to maybe not visit the children- Returns:
trueif the parse tree walker
-