Package de.monticore.types.check
Class SymTypeOfWildcard
- java.lang.Object
-
- de.monticore.types.check.SymTypeExpression
-
- de.monticore.types.check.SymTypeOfWildcard
-
public class SymTypeOfWildcard extends SymTypeExpression
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.Optional<SymTypeExpression>boundprotected booleanisUpper-
Fields inherited from class de.monticore.types.check.SymTypeExpression
functionList, LOG_NAME, sourceInfo, typeSymbol
-
-
Constructor Summary
Constructors Constructor Description SymTypeOfWildcard()Deprecated, for removal: This API element is subject to removal in a future version.use the Factory, the Factory uses the constructor belowSymTypeOfWildcard(SymTypeExpression bound, boolean isUpper)To be used by the SymTypeExpressionFactory
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(ISymTypeVisitor visitor)SymTypeOfWildcardasWildcard()booleandeepEquals(SymTypeExpression sym)SymTypeExpressiongetBound()SymTypeExpressiongetLowerBound()SymTypeExpressiongetUpperBound()booleanhasBound()booleanisUpper()booleanisValidType()Am I a not valid type? e.g.booleanisWildcard()Am I a wildcard (s.-
Methods inherited from class de.monticore.types.check.SymTypeExpression
_internal_setSourceInfo, asArrayType, asFunctionType, asGenericType, asInferenceVariable, asIntersectionType, asNullType, asNumericWithSIUnitType, asObjectType, asObscureType, asPrimitive, asRegExType, asSIUnitType, asTupleType, asTypeVariable, asUnionType, asVoidType, deepClone, getCorrectFields, getCorrectFields, getCorrectMethods, getCorrectMethods, getFieldList, getFieldList, getFieldList, getFieldList, getMethodList, getMethodList, getMethodList, getMethodList, getSourceInfo, getTypeInfo, hasTypeInfo, isArrayType, isFunctionType, isGenericType, isInferenceVariable, isIntersectionType, isNullType, isNumericWithSIUnitType, isObjectType, isObscureType, isPrimitive, isRegExType, isSIUnitType, isTupleType, isTypeVariable, isUnionType, isVoidType, print, printAsJson, printFullName, replaceTypeVariables, transformFieldList, transformMethodList
-
-
-
-
Field Detail
-
bound
protected java.util.Optional<SymTypeExpression> bound
-
isUpper
protected boolean isUpper
-
-
Constructor Detail
-
SymTypeOfWildcard
@Deprecated(forRemoval=true) public SymTypeOfWildcard()
Deprecated, for removal: This API element is subject to removal in a future version.use the Factory, the Factory uses the constructor below
-
SymTypeOfWildcard
public SymTypeOfWildcard(SymTypeExpression bound, boolean isUpper)
To be used by the SymTypeExpressionFactory
-
-
Method Detail
-
hasBound
public boolean hasBound()
-
getBound
public SymTypeExpression getBound()
-
isUpper
public boolean isUpper()
-
getUpperBound
public SymTypeExpression getUpperBound()
- Returns:
- upper bound, TOP if not bounded otherwise
-
getLowerBound
public SymTypeExpression getLowerBound()
- Returns:
- lower bound, BOTTOM if not bounded otherwise
-
isValidType
public boolean isValidType()
Description copied from class:SymTypeExpressionAm I a not valid type? e.g. unknown type, not all type variables set, pseudo types like typeVariables- Overrides:
isValidTypein classSymTypeExpression
-
isWildcard
public boolean isWildcard()
Description copied from class:SymTypeExpressionAm I a wildcard (s. generics)?- Overrides:
isWildcardin classSymTypeExpression
-
asWildcard
public SymTypeOfWildcard asWildcard()
- Overrides:
asWildcardin classSymTypeExpression
-
deepEquals
public boolean deepEquals(SymTypeExpression sym)
- Specified by:
deepEqualsin classSymTypeExpression
-
accept
public void accept(ISymTypeVisitor visitor)
- Overrides:
acceptin classSymTypeExpression
-
-