T
- The type variable we wish to capture.public class TypeParameter<T> extends TypeToken<T>
TypeToken
.TypeToken.Capture, TypeToken.Infer, TypeToken.Retain, TypeToken.Wildcards
Modifier | Constructor and Description |
---|---|
protected |
TypeParameter()
Capture the type variable provided as an argument to the type parameter of
this constructor.
|
Modifier and Type | Method and Description |
---|---|
TypeArgument<T> |
asClass(java.lang.Class<T> type) |
TypeArgument<?> |
asType(java.lang.reflect.Type type) |
TypeArgument<T> |
asType(TypeToken<T> type) |
static TypeParameter<?> |
forTypeVariable(java.lang.reflect.TypeVariable<?> type)
Capture the given type variable in a TypeToken.
|
java.lang.reflect.TypeVariable<?> |
getType()
The type represented by this
TypeToken . |
cast, constructors, copy, declaredConstructors, declaredFields, declaredMethods, deepCopy, equals, fields, forAnnotatedType, forClass, forNull, forType, forType, forType, fromString, fromString, getAnnotatedDeclaration, getBounds, getErasedType, getErasedTypeToken, getErasedUpperBounds, getExtending, getInferenceVariablesMentioned, getOwningDeclaration, getRemainingInferenceVariableDependencies, getSuper, getThis, getThisTypeToken, getTypeArguments, getTypeParameterCount, getTypeParameters, getUpperBounds, getWildcardExtending, getWildcardSuper, hashCode, infer, isCastableFrom, isCastableFrom, isCastableTo, isCastableTo, isGeneric, isPrimitive, isPrimitiveWrapper, isProper, isRaw, methods, parameterize, resolve, resolveSupertype, satisfiesConstraintFrom, satisfiesConstraintFrom, satisfiesConstraintTo, satisfiesConstraintTo, substituteInstantiations, toString, toString, unwrapPrimitive, withAllTypeArguments, withAllTypeArguments, withBounds, withConstraintFrom, withConstraintFrom, withConstraintTo, withConstraintTo, withTypeArguments, withTypeArguments, withTypeArguments, wrapPrimitive
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
deepCopy
asTypedObject, getThisType
getAllTypeArguments, getAllTypeParameterCount, getAllTypeParameters, resolveTypeArgument, resolveTypeArgument, withTypeArguments
protected TypeParameter()
public java.lang.reflect.TypeVariable<?> getType()
TypeToken
TypeToken
.public static TypeParameter<?> forTypeVariable(java.lang.reflect.TypeVariable<?> type)
type
- The type variable to capture.public TypeArgument<T> asType(TypeToken<T> type)
public TypeArgument<T> asClass(java.lang.Class<T> type)
public TypeArgument<?> asType(java.lang.reflect.Type type)