protected class TypePool.LazyTypeDescription.GenericTypeToken.ForParameterizedType.LazyParameterizedType extends GenericTypeDescription.ForParameterizedType
GenericTypeDescription.ForParameterizedType.Latent, GenericTypeDescription.ForParameterizedType.OfLoadedType
GenericTypeDescription.ForGenericArray, GenericTypeDescription.ForNonGenericType, GenericTypeDescription.ForParameterizedType, GenericTypeDescription.ForTypeVariable, GenericTypeDescription.ForWildcardType, GenericTypeDescription.LazyProjection, GenericTypeDescription.Sort, GenericTypeDescription.SuperTypeIterator, GenericTypeDescription.Visitor<T>
NamedElement.WithGenericName, NamedElement.WithRuntimeName
EMPTY_NAME, NO_NAME
Constructor and Description |
---|
LazyParameterizedType(TypePool typePool,
TypeVariableSource typeVariableSource)
Creates a new description of a parameterized type.
|
Modifier and Type | Method and Description |
---|---|
TypeDescription |
asErasure()
Returns the erasure of this type.
|
GenericTypeDescription |
getOwnerType()
Returns the owner type of this type.
|
GenericTypeList |
getParameters()
Returns the type parameters of this type.
|
accept, equals, getComponentType, getDeclaredFields, getDeclaredMethods, getInterfaces, getLowerBounds, getSort, getSourceCodeName, getStackSize, getSuperType, getSymbol, getTypeName, getUpperBounds, getVariableSource, hashCode, isArray, isPrimitive, iterator, represents, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
forEach, spliterator
public LazyParameterizedType(TypePool typePool, TypeVariableSource typeVariableSource)
typePool
- The type pool that is used for locating a generic type.typeVariableSource
- The type variable source to use for resolving type variables.public TypeDescription asErasure()
GenericTypeDescription
GenericTypeDescription.Sort.WILDCARD
)
do not have a well-defined erasure and cause an IllegalStateException
to be thrown.public GenericTypeList getParameters()
GenericTypeDescription
Returns the type parameters of this type.
Parameters are only well-defined for parameterized types
(GenericTypeDescription.Sort.PARAMETERIZED
), generic array types
(GenericTypeDescription.Sort.GENERIC_ARRAY
) and non-generic types
(GenericTypeDescription.Sort.NON_GENERIC
). For non-generic and generic array types,
the returned list is always empty. For all other types, this method throws an IllegalStateException
.
public GenericTypeDescription getOwnerType()
GenericTypeDescription
Returns the owner type of this type.
An owner type is only well-defined for parameterized types
(GenericTypeDescription.Sort.PARAMETERIZED
) , generic array types
(GenericTypeDescription.Sort.GENERIC_ARRAY
) and non-generic types
(GenericTypeDescription.Sort.NON_GENERIC
). Non-generic types and generic array types do
never have an owner type. For all other types, this method throws an IllegalStateException
.
null
if no such owner type exists.Copyright © 2014–2015. All rights reserved.