public class ParametrizedTypeJavaType extends ClassJavaType
Type.ArrayType, Type.Primitives| Constructor and Description |
|---|
ParametrizedTypeJavaType(JavaSymbol.TypeJavaSymbol symbol,
TypeSubstitution typeSubstitution,
TypeSubstitutionSolver typeSubstitutionSolver) |
| Modifier and Type | Method and Description |
|---|---|
JavaType |
erasure()
JLS8 4.6
|
boolean |
isSubtypeOf(Type superType)
Check whether a type is a subtype of another.
|
protected ClassJavaType |
substitutedType(ClassJavaType type) |
JavaType |
substitution(TypeVariableJavaType typeVariableType) |
List<TypeVariableJavaType> |
typeParameters() |
directSuperTypes, getSuperType, is, isSubtypeOf, superTypesfullyQualifiedName, getSymbol, isArray, isClass, isNumerical, isParameterized, isPrimitive, isPrimitive, isPrimitiveWrapper, isTagged, isUnknown, isVoid, name, primitiveType, primitiveWrapperType, symbol, toStringpublic ParametrizedTypeJavaType(JavaSymbol.TypeJavaSymbol symbol, TypeSubstitution typeSubstitution, TypeSubstitutionSolver typeSubstitutionSolver)
@Nullable public JavaType substitution(TypeVariableJavaType typeVariableType)
public List<TypeVariableJavaType> typeParameters()
public boolean isSubtypeOf(Type superType)
Type
This method will consider implemented interfaces as well as superclasses.
Type type, myOtherType;
type.isSubtypeOf(myOtherType);
isSubtypeOf in interface TypeisSubtypeOf in class ClassJavaTypesuperType - instance of a potential superType.protected ClassJavaType substitutedType(ClassJavaType type)
substitutedType in class ClassJavaTypeCopyright © 2012–2018 SonarSource. All rights reserved.