Interface TypeVariableScope
- All Known Subinterfaces:
ArrayTypeDetails, ClassBasedTypeDetails, ClassDetails, ClassDetailsSupport, ClassTypeDetails, MutableClassDetails, ParameterizedTypeDetails, PrimitiveTypeDetails, TypeDetails, TypeVariableDetails, TypeVariableReferenceDetails, VoidTypeDetails, WildcardTypeDetails
- All Known Implementing Classes:
ArrayTypeDetailsImpl, ClassTypeDetailsImpl, DynamicClassDetails, JdkClassDetails, MissingPackageInfoDetails, ParameterizedTypeDetailsImpl, PrimitiveTypeDetailsImpl, SimpleClassDetails, TypeVariableDetailsImpl, TypeVariableReferenceDetailsImpl, VoidTypeDetailsImpl, WildcardTypeDetailsImpl
public interface TypeVariableScope
A scope for TypeVariableDetails references
-
Method Summary
Modifier and TypeMethodDescriptionDetermine the raw class for the given type.resolveTypeVariable(TypeVariableDetails typeVariable) Resolve the type of the provided type variable relative to this scope.
-
Method Details
-
resolveTypeVariable
Resolve the type of the provided type variable relative to this scope. For example, givenclass
A call to this method on theThing<I extends Number>{ I id; }Thingscope with the type variable representingIwill return theI extends Numbertype variable definition itself. If this scope defines a corresponding type argument, the concrete type is returned. For example, givenclass
This method will yield theStuff extends Thing<Integer>{ }Integertype details.- Parameters:
typeVariable- The type variable to resolve- Returns:
- The type variable's resolved type, or
nullif none could be found
-
determineRawClass
ClassDetails determineRawClass()Determine the raw class for the given type. Never returnsnull, opting to return Object instead if the raw class is not known- Returns:
- The raw class details, or Object if "not known".
-