Class UglyExpressionsTypeVisitor
- java.lang.Object
-
- de.monticore.types3.AbstractTypeVisitor
-
- de.monticore.expressions.uglyexpressions.types3.UglyExpressionsTypeVisitor
-
- All Implemented Interfaces:
UglyExpressionsVisitor2,de.monticore.visitor.IVisitor
- Direct Known Subclasses:
UglyExpressionsCTTIVisitor
public class UglyExpressionsTypeVisitor extends AbstractTypeVisitor implements UglyExpressionsVisitor2
-
-
Field Summary
-
Fields inherited from class de.monticore.types3.AbstractTypeVisitor
ctx4Ast, LOG_NAME, tmpMap, type4Ast
-
-
Constructor Summary
Constructors Constructor Description UglyExpressionsTypeVisitor()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidendVisit(ASTCreatorExpression expr)voidendVisit(ASTInstanceofExpression expr)voidendVisit(ASTTypeCastExpression expr)protected SymTypeExpressiongetArrayCreatorType(ASTArrayCreator creator)protected java.util.Optional<java.lang.Integer>getArrayDimensionSpecifierSize(ASTArrayDimensionSpecifier dimSpec)only returns the dimensionality if the expression types are correct if the expressions are not correct, Log::error will be usedprotected SymTypeExpressiongetClassCreatorType(ASTClassCreator creator)protected java.util.List<SymTypeOfFunction>getConstructors(ASTClassCreator creator)Constructors of the inner type, NOT filtered by the argument expressions.protected SymTypeExpressiongetCreatorType(ASTCreator creator)This needs to be extended, whenever a new Creator is added.voidsetOOWithinTypeBasicSymbolsResolver(OOWithinTypeBasicSymbolsResolver withinTypeResolver)Deprecated, for removal: This API element is subject to removal in a future version.is now a static delegatevoidsetTypeContextCalculator(TypeContextCalculator typeCtxCalc)Deprecated, for removal: This API element is subject to removal in a future version.is now a static delegate-
Methods inherited from class de.monticore.types3.AbstractTypeVisitor
getAsBasicSymbolsScope, getInferenceContext4Ast, getType4Ast, setContext4Ast, setType4Ast
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Method Detail
-
setOOWithinTypeBasicSymbolsResolver
@Deprecated(forRemoval=true) public void setOOWithinTypeBasicSymbolsResolver(OOWithinTypeBasicSymbolsResolver withinTypeResolver)
Deprecated, for removal: This API element is subject to removal in a future version.is now a static delegate
-
setTypeContextCalculator
@Deprecated(forRemoval=true) public void setTypeContextCalculator(TypeContextCalculator typeCtxCalc)
Deprecated, for removal: This API element is subject to removal in a future version.is now a static delegate
-
endVisit
public void endVisit(ASTTypeCastExpression expr)
- Specified by:
endVisitin interfaceUglyExpressionsVisitor2
-
endVisit
public void endVisit(ASTInstanceofExpression expr)
- Specified by:
endVisitin interfaceUglyExpressionsVisitor2
-
endVisit
public void endVisit(ASTCreatorExpression expr)
- Specified by:
endVisitin interfaceUglyExpressionsVisitor2
-
getCreatorType
protected SymTypeExpression getCreatorType(ASTCreator creator)
This needs to be extended, whenever a new Creator is added.Returns the type the CreatorExpressions is to have. This is calculated here, as a Creator is neither an ASTExpression nor an ASTMCType, thus we do not need to modify Type4Ast.
-
getClassCreatorType
protected SymTypeExpression getClassCreatorType(ASTClassCreator creator)
-
getArrayCreatorType
protected SymTypeExpression getArrayCreatorType(ASTArrayCreator creator)
-
getArrayDimensionSpecifierSize
protected java.util.Optional<java.lang.Integer> getArrayDimensionSpecifierSize(ASTArrayDimensionSpecifier dimSpec)
only returns the dimensionality if the expression types are correct if the expressions are not correct, Log::error will be used
-
getConstructors
protected java.util.List<SymTypeOfFunction> getConstructors(ASTClassCreator creator)
Constructors of the inner type, NOT filtered by the argument expressions. Important: TheASTClassCreator.getMCType()has to have its type stored in the map already.- Returns:
- if empty, an error will have been logged
-
-