Top Description Fields Constructors Methods
org.antlr.v4.runtime.tree

public Class IterativeParseTreeWalker

extends ParseTreeWalker
Class Inheritance
Imports
org.antlr.v4.runtime.misc.IntegerStack, java.util.ArrayDeque, .Deque

An iterative (read: non-recursive) pre-order and post-order tree walker that doesn't use the thread stack but heap-based stacks. Makes it possible to process deeply nested parse trees.

Field Summary

Inherited from org.antlr.v4.runtime.tree.ParseTreeWalker:
DEFAULT

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
walk(ParseTreeListener
The listener used by the walker to process grammar rules
listener
,
ParseTree
The parse tree to be walked on
t
)

Overrides org.antlr.v4.runtime.tree.ParseTreeWalker.walk.

Performs a walk on the given parse tree starting at the root and going down recursively with depth-first search.
Inherited from org.antlr.v4.runtime.tree.ParseTreeWalker:
enterRuleexitRule

Constructor Detail

IterativeParseTreeWalkerback to summary
public IterativeParseTreeWalker()

Method Detail

walkback to summary
public void walk(ParseTreeListener listener, ParseTree t)

Overrides org.antlr.v4.runtime.tree.ParseTreeWalker.walk.

Doc from org.antlr.v4.runtime.tree.ParseTreeWalker.walk.

Performs a walk on the given parse tree starting at the root and going down recursively with depth-first search. On each node, ParseTreeWalker#enterRule is called before recursively walking down into child nodes, then ParseTreeWalker#exitRule is called after the recursive call to wind up.

Parameters
listener:ParseTreeListener

The listener used by the walker to process grammar rules

t:ParseTree

The parse tree to be walked on

Annotations
@Override