public static class GenericTypeDescription.ForWildcardType.Latent extends GenericTypeDescription.ForWildcardType
GenericTypeDescription.ForWildcardType.Latent, GenericTypeDescription.ForWildcardType.OfLoadedTypeGenericTypeDescription.ForGenericArray, GenericTypeDescription.ForNonGenericType, GenericTypeDescription.ForParameterizedType, GenericTypeDescription.ForTypeVariable, GenericTypeDescription.ForWildcardType, GenericTypeDescription.LazyProjection, GenericTypeDescription.Sort, GenericTypeDescription.SuperTypeIterator, GenericTypeDescription.Visitor<T>NamedElement.WithGenericName, NamedElement.WithRuntimeNameSYMBOLEMPTY_NAME, NO_NAME| Modifier | Constructor and Description |
|---|---|
protected |
Latent(List<? extends GenericTypeDescription> upperBounds,
List<? extends GenericTypeDescription> lowerBounds)
Creates a description of a latent wildcard.
|
| Modifier and Type | Method and Description |
|---|---|
static GenericTypeDescription |
boundedAbove(GenericTypeDescription upperBound)
Creates a wildcard with an upper bound.
|
static GenericTypeDescription |
boundedBelow(GenericTypeDescription lowerBound)
Creates a wildcard with a lower bound.
|
GenericTypeList |
getLowerBounds()
Returns the lower bounds of this type.
|
GenericTypeList |
getUpperBounds()
Returns the upper bounds of this type.
|
static GenericTypeDescription |
unbounded()
Creates an unbounded wildcard.
|
accept, asErasure, equals, getComponentType, getDeclaredFields, getDeclaredMethods, getInterfaces, getOwnerType, getParameters, getSort, getSourceCodeName, getStackSize, getSuperType, getSymbol, getTypeName, getVariableSource, hashCode, isArray, isPrimitive, iterator, represents, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitforEach, spliteratorprotected Latent(List<? extends GenericTypeDescription> upperBounds, List<? extends GenericTypeDescription> lowerBounds)
upperBounds - The wildcard's upper bounds.lowerBounds - The wildcard's lower bounds.public static GenericTypeDescription unbounded()
Object type.public static GenericTypeDescription boundedAbove(GenericTypeDescription upperBound)
upperBound - The upper bound of the wildcard.public static GenericTypeDescription boundedBelow(GenericTypeDescription lowerBound)
Object type.lowerBound - The lower bound of the wildcard.public GenericTypeList getUpperBounds()
GenericTypeDescription
Returns the upper bounds of this type. Any type with a well-defined upper bound is bound by at least one type. If no such
type is defined, the bound is implicitly Object.
Only non-symbolic type variables (GenericTypeDescription.Sort.VARIABLE,
GenericTypeDescription.Sort.VARIABLE_DETACHED) and wildcard types
(GenericTypeDescription.Sort.WILDCARD) have well-defined upper bounds. For other
types, an IllegalStateException is thrown.
public GenericTypeList getLowerBounds()
GenericTypeDescriptionReturns the lower bounds of this type.
Only wildcard types (GenericTypeDescription.Sort.WILDCARD) define a lower bound. For other
types, an IllegalStateException is thrown.
Copyright © 2014–2015. All rights reserved.