public final class UnresolvedTypeVariable extends Type
Modifier and Type | Field and Description |
---|---|
private int |
hash |
private java.lang.String |
name |
EMPTY_ARRAY
Constructor and Description |
---|
UnresolvedTypeVariable(java.lang.String name) |
UnresolvedTypeVariable(java.lang.String name,
AnnotationInstance[] annotations) |
Modifier and Type | Method and Description |
---|---|
UnresolvedTypeVariable |
asUnresolvedTypeVariable()
Casts this type to an
UnresolvedTypeVariable and returns it if the kind is
Type.Kind.UNRESOLVED_TYPE_VARIABLE
Throws an exception otherwise. |
(package private) Type |
copyType(AnnotationInstance[] newAnnotations) |
boolean |
equals(java.lang.Object o)
Compares this Type with another type, and returns true if they are equivalent.
|
int |
hashCode()
Computes a hash code representing this type.
|
java.lang.String |
identifier()
The identifier of this unresolved type variable as it appears in Java source code.
|
Type.Kind |
kind()
Returns the kind of Type this is.
|
java.lang.String |
toString()
Returns a string representation for this type.
|
addAnnotation, annotation, annotationArray, annotations, appendAnnotations, asArrayType, asClassType, asParameterizedType, asPrimitiveType, asTypeVariable, asVoidType, asWildcardType, create, hasAnnotation, name, toString
UnresolvedTypeVariable(java.lang.String name)
UnresolvedTypeVariable(java.lang.String name, AnnotationInstance[] annotations)
public java.lang.String identifier()
The following class has a type parameter, with an identifier of "T":
class Foo<T extends Number> {}
public UnresolvedTypeVariable asUnresolvedTypeVariable()
Type
UnresolvedTypeVariable
and returns it if the kind is
Type.Kind.UNRESOLVED_TYPE_VARIABLE
Throws an exception otherwise.asUnresolvedTypeVariable
in class Type
ClassType
public java.lang.String toString()
Type
Type copyType(AnnotationInstance[] newAnnotations)
public boolean equals(java.lang.Object o)
Type