net.sourceforge.nrl.parser.ast.impl
Class AntlrAstVisitor
java.lang.Object
net.sourceforge.nrl.parser.ast.impl.AntlrAstVisitor
- All Implemented Interfaces:
- INRLAstVisitor
- Direct Known Subclasses:
- AntlrModelResolverVisitor
public abstract class AntlrAstVisitor
- extends Object
- implements INRLAstVisitor
An abstract class that narrows the AST visitor interface a bit, to pass it an
Antlr3NRLBaseAst
.
Subclasses need to implement visitBefore(Antlr3NRLBaseAst)
, and
visitAfter(Antlr3NRLBaseAst)
only if necessary.
- Author:
- Christian Nentwich
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AntlrAstVisitor
public AntlrAstVisitor()
visitBefore
public final boolean visitBefore(INRLAstNode node)
- Description copied from interface:
INRLAstVisitor
- Visit an AST node and, if this method returns true, visit its children in
order.
- Specified by:
visitBefore
in interface INRLAstVisitor
- Parameters:
node
- the AST node
- Returns:
- true if the children should be visited
visitAfter
public final void visitAfter(INRLAstNode node)
- Description copied from interface:
INRLAstVisitor
- Visit an AST node after its children have been processed. This is always
called after
INRLAstVisitor.visitBefore(INRLAstNode)
by the AST.
- Specified by:
visitAfter
in interface INRLAstVisitor
- Parameters:
node
- the node to visit
visitBefore
protected abstract boolean visitBefore(Antlr3NRLBaseAst node)
visitAfter
protected void visitAfter(Antlr3NRLBaseAst node)
Copyright © 2006-2013. All Rights Reserved.