public interface WildcardType extends Type
? extends Number: has an upper bound? super Number: has a lower bound?: unbounded, has an implicit upper bound of java.lang.Object? is equivalent to ? extends Object and is represented as such.
Therefore, either upperBound() or lowerBound() always returns non-null.| Modifier and Type | Method and Description |
|---|---|
default WildcardType |
asWildcardType()
Returns this type as a wildcard type.
|
default Type.Kind |
kind()
Returns the kind of this type.
|
Type |
lowerBound()
Returns the lower bound of this wildcard type.
|
Type |
upperBound()
Returns the upper bound of this wildcard type.
|
asArray, asClass, asDeclaration, asParameterizedType, asPrimitive, asType, asTypeVariable, asVoid, isArray, isClass, isDeclaration, isParameterizedType, isPrimitive, isType, isTypeVariable, isVoid, isWildcardTypeannotation, annotations, annotations, hasAnnotation, hasAnnotation, repeatableAnnotationType upperBound()
null if this wildcard type does not have an upper bound.null if this wildcard type does not have an upper boundType lowerBound()
null if this wildcard type does not have a lower bound.null if this wildcard type does not have a lower bounddefault Type.Kind kind()
Typedefault WildcardType asWildcardType()
TypeasWildcardType in interface Typenull