Interface IVisitor
-
- All Superinterfaces:
IVisitor
- All Known Subinterfaces:
ITemplateLangVisitor
- All Known Implementing Classes:
ExpressionCopyVisitor,ExpressionVersionRestrictionValidator,TemplateLangExecution,TemplateLangWriter,TemplateSubstitutionExecution
public interface IVisitor extends IVisitor
A visitor interface for the template language elements.- Author:
- Holger Eichelberger
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.ObjectvisitAlternative(AlternativeStatement alternative)Visits an alternative statement.java.lang.ObjectvisitContentAlternativeExpression(ContentAlternativeExpression ex)Visits a content alternative expression.java.lang.ObjectvisitContentImportExpression(ContentImportExpression ex)Visits a content import expression.java.lang.ObjectvisitContentLoopExpression(ContentLoopExpression ex)Visits a content loop expression.java.lang.ObjectvisitContentStatement(ContentStatement cnt)Visits a content statement.java.lang.ObjectvisitContentVarDeclExpression(ContentVarDeclExpression ex)Visits a content variable declaration expression.java.lang.ObjectvisitDef(Def def)Visits a sub-template definition.java.lang.ObjectvisitFlush(FlushStatement flush)Visits a flush statement.java.lang.ObjectvisitJavaExtension(JavaExtension ext)Visits a java extension.java.lang.ObjectvisitLoop(LoopStatement loop)Visits a loop statement.java.lang.ObjectvisitSwitch(SwitchStatement swtch)Visits a switch statement.java.lang.ObjectvisitTemplate(Template template)Visits a template.java.lang.ObjectvisitTemplateBlock(TemplateBlock block)Visits a template block.java.lang.ObjectvisitTemplateCallExpression(TemplateCallExpression call)Visits a template call expression.java.lang.ObjectvisitWhile(WhileStatement stmt)Visits a while statement.-
Methods inherited from interface net.ssehub.easy.instantiation.core.model.common.IVisitor
visitAdvice, visitCompound, visitExpressionStatement, visitTypedef, visitVariableDeclaration
-
-
-
-
Method Detail
-
visitTemplate
java.lang.Object visitTemplate(Template template) throws VilException
Visits a template.- Parameters:
template- the template to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitDef
java.lang.Object visitDef(Def def) throws VilException
Visits a sub-template definition.- Parameters:
def- the sub-template definition to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitTemplateBlock
java.lang.Object visitTemplateBlock(TemplateBlock block) throws VilException
Visits a template block.- Parameters:
block- the template block to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitAlternative
java.lang.Object visitAlternative(AlternativeStatement alternative) throws VilException
Visits an alternative statement.- Parameters:
alternative- the alternative to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitLoop
java.lang.Object visitLoop(LoopStatement loop) throws VilException
Visits a loop statement.- Parameters:
loop- the loop statement to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitWhile
java.lang.Object visitWhile(WhileStatement stmt) throws VilException
Visits a while statement.- Parameters:
stmt- the while statement to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitSwitch
java.lang.Object visitSwitch(SwitchStatement swtch) throws VilException
Visits a switch statement.- Parameters:
swtch- the switch statement to visit- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitContentStatement
java.lang.Object visitContentStatement(ContentStatement cnt) throws VilException
Visits a content statement.- Parameters:
cnt- the content statement- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitJavaExtension
java.lang.Object visitJavaExtension(JavaExtension ext) throws VilException
Visits a java extension.- Parameters:
ext- the java extension- Returns:
- the result of visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitTemplateCallExpression
java.lang.Object visitTemplateCallExpression(TemplateCallExpression call) throws VilException
Visits a template call expression.- Parameters:
call- the call expression- Returns:
- the result of visiting the given expression (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitFlush
java.lang.Object visitFlush(FlushStatement flush) throws VilException
Visits a flush statement.- Parameters:
flush- the flush statement- Returns:
- the result visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitContentAlternativeExpression
java.lang.Object visitContentAlternativeExpression(ContentAlternativeExpression ex) throws VilException
Visits a content alternative expression.- Parameters:
ex- the expression- Returns:
- the result visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitContentLoopExpression
java.lang.Object visitContentLoopExpression(ContentLoopExpression ex) throws VilException
Visits a content loop expression.- Parameters:
ex- the expression- Returns:
- the result visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitContentVarDeclExpression
java.lang.Object visitContentVarDeclExpression(ContentVarDeclExpression ex) throws VilException
Visits a content variable declaration expression.- Parameters:
ex- the expression- Returns:
- the result visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
visitContentImportExpression
java.lang.Object visitContentImportExpression(ContentImportExpression ex) throws VilException
Visits a content import expression.- Parameters:
ex- the expression- Returns:
- the result visiting the given statement (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
-