Class ContentVarDeclExpression
- java.lang.Object
-
- net.ssehub.easy.instantiation.core.model.expressions.Expression
-
- net.ssehub.easy.instantiation.core.model.templateModel.InContentExpression
-
- net.ssehub.easy.instantiation.core.model.templateModel.ContentVarDeclExpression
-
public class ContentVarDeclExpression extends InContentExpression
Creates a content expression/statement that declares and initializes a variable.- Author:
- Holger Eichelberger
-
-
Field Summary
Fields Modifier and Type Field Description private VariableDeclarationvar
-
Constructor Summary
Constructors Constructor Description ContentVarDeclExpression(VariableDeclaration var)Creates an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectaccept(IExpressionVisitor visitor)Visits the expression.VariableDeclarationgetVariable()Returns the declared variable.-
Methods inherited from class net.ssehub.easy.instantiation.core.model.templateModel.InContentExpression
inferType, replaceEmptyLine
-
Methods inherited from class net.ssehub.easy.instantiation.core.model.expressions.Expression
getFormattingHint
-
-
-
-
Field Detail
-
var
private VariableDeclaration var
-
-
Constructor Detail
-
ContentVarDeclExpression
public ContentVarDeclExpression(VariableDeclaration var)
Creates an instance.- Parameters:
var- the variable
-
-
Method Detail
-
getVariable
public VariableDeclaration getVariable()
Returns the declared variable.- Returns:
- the variable
-
accept
public java.lang.Object accept(IExpressionVisitor visitor) throws VilException
Description copied from class:ExpressionVisits the expression.- Specified by:
acceptin classExpression- Parameters:
visitor- the visitor- Returns:
- the result of visiting this expression (may be null)
- Throws:
VilException- in case that visiting fails (e.g., execution)
-
-