public abstract class ReferenceBound extends ParameterBound
ReferenceType
.Modifier and Type | Field and Description |
---|---|
private ReferenceType |
boundType
The type for this bound.
|
Constructor and Description |
---|
ReferenceBound(ReferenceType boundType)
Creates a
ReferenceBound with the given bound type. |
Modifier and Type | Method and Description |
---|---|
abstract ReferenceBound |
applyCaptureConversion()
Applies a capture conversion to any wildcard arguments in the type of this bound.
|
boolean |
equals(@Nullable java.lang.Object obj) |
ReferenceType |
getBoundType()
Returns the
ReferenceType bound of this type. |
boolean |
hasCaptureVariable()
Indicates whether the type of this bound has a capture variable.
|
int |
hashCode() |
(package private) boolean |
hasWildcard()
Indicates whether the type of this bound has a wildcard type argument.
|
boolean |
isGeneric(boolean ignoreWildcards)
Indicates whether the type of this bound is generic.
|
boolean |
isObject()
Indicate whether this bound is
Object . |
boolean |
isVariable()
Indicates whether this bound is a type variable.
|
abstract ReferenceBound |
substitute(Substitution substitution)
Applies the given substitution to this type bound by replacing type variables.
|
java.lang.String |
toString() |
forType, forType, forTypes, getTypeParameters, isGeneric, isLowerBound, isLowerBound, isSubtypeOf, isTypeVariable, isUpperBound, isUpperBound
private final ReferenceType boundType
ReferenceBound(ReferenceType boundType)
ReferenceBound
with the given bound type.boundType
- the ReferenceType
of this boundpublic ReferenceType getBoundType()
ReferenceType
bound of this type.public boolean equals(@Nullable java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public abstract ReferenceBound substitute(Substitution substitution)
ParameterBound
substitute
in class ParameterBound
substitution
- the type substitutionpublic abstract ReferenceBound applyCaptureConversion()
ParameterBound
applyCaptureConversion
in class ParameterBound
ReferenceType.applyCaptureConversion()
boolean hasWildcard()
ParameterBound
hasWildcard
in class ParameterBound
public boolean hasCaptureVariable()
ParameterBound
hasCaptureVariable
in class ParameterBound
public boolean isGeneric(boolean ignoreWildcards)
ParameterBound
isGeneric
in class ParameterBound
ignoreWildcards
- if true, ignore wildcards; that is, treat wildcards as not making the
operation genericpublic boolean isObject()
ParameterBound
Object
.isObject
in class ParameterBound
Object
, false otherwisepublic boolean isVariable()
ParameterBound
isVariable
in class ParameterBound