public class ParameterizedTypeBinding extends ReferenceBinding implements Substitution
| Modifier and Type | Field and Description |
|---|---|
TypeBinding[] |
arguments |
protected ReferenceBinding |
enclosingType |
LookupEnvironment |
environment |
FieldBinding[] |
fields |
char[] |
genericTypeSignature |
ReferenceBinding[] |
memberTypes |
MethodBinding[] |
methods |
ReferenceBinding |
superclass |
ReferenceBinding[] |
superInterfaces |
ReferenceBinding |
type |
compoundName, fPackage, LUB_GENERIC, modifiers, samProblemBinding, singleAbstractMethod, sourceNameBOOLEAN, BYTE, CHAR, DOUBLE, FLOAT, id, INT, LONG, NULL, SHORT, tagBits, TYPE_USE_BINDING, typeAnnotations, VOIDANY_EXCEPTION, ARRAY_TYPE, BASE_TYPE, DefaultLocationArrayContents, DefaultLocationField, DefaultLocationParameter, DefaultLocationReturnType, DefaultLocationTypeArgument, DefaultLocationTypeBound, DefaultLocationTypeParameter, FIELD, GENERIC_TYPE, IMPORT, INTERSECTION_TYPE, INTERSECTION_TYPE18, LOCAL, METHOD, NO_ANNOTATIONS, NO_ELEMENT_VALUE_PAIRS, NO_EXCEPTIONS, NO_FIELDS, NO_MEMBER_TYPES, NO_METHODS, NO_NULL_DEFAULT, NO_PARAMETER_NAMES, NO_PARAMETERS, NO_REFERENCE_TYPES, NO_SUPERINTERFACES, NO_TYPE_VARIABLES, NO_TYPES, NONNULL_BY_DEFAULT, NULL_UNSPECIFIED_BY_DEFAULT, NullnessDefaultMASK, PACKAGE, PARAMETERIZED_TYPE, POLY_TYPE, RAW_TYPE, TYPE, TYPE_PARAMETER, TYPE_USE, UNINITIALIZED_FIELDS, UNINITIALIZED_METHODS, UNINITIALIZED_REFERENCE_TYPES, VARIABLE, WILDCARD_TYPE| Constructor and Description |
|---|
ParameterizedTypeBinding(ReferenceBinding type,
TypeBinding[] arguments,
ReferenceBinding enclosingType,
LookupEnvironment environment) |
| Modifier and Type | Method and Description |
|---|---|
ReferenceBinding |
actualType()
May return an UnresolvedReferenceBinding.
|
java.lang.String |
annotatedDebugName() |
void |
boundCheck(Scope scope,
TypeReference[] argumentReferences)
Iterate type arguments, and validate them according to corresponding variable bounds.
|
boolean |
canBeInstantiated()
Answer true if the receiver can be instantiated
|
ParameterizedTypeBinding |
capture(Scope scope,
int start,
int end)
Perform capture conversion for a parameterized type with wildcard arguments
|
TypeBinding |
clone(TypeBinding outerType)
Virtual copy constructor: a copy is made of the receiver's entire instance state and then suitably
parameterized by the arguments to the clone operation as seen fit by each type.
|
java.util.List |
collectMissingTypes(java.util.List missingTypes)
Iterate through the type components to collect instances of leaf missing types
|
void |
collectSubstitutes(Scope scope,
TypeBinding actualType,
InferenceContext inferenceContext,
int constraint)
Collect the substitutes into a map for certain type variables inside the receiver type
e.g.
|
void |
computeId() |
char[] |
computeUniqueKey(boolean isLeaf)
p.X
|
char[] |
constantPoolName()
Answer the receiver's constant pool name.
|
ParameterizedMethodBinding |
createParameterizedMethod(MethodBinding originalMethod) |
java.lang.String |
debugName() |
ReferenceBinding |
enclosingType() |
LookupEnvironment |
environment()
Returns the lookup environment
|
TypeBinding |
erasure() |
int |
fieldCount() |
FieldBinding[] |
fields() |
ReferenceBinding |
genericType()
Return the original generic type from which the parameterized type got instantiated from.
|
char[] |
genericTypeSignature()
Ltype |
long |
getAnnotationTagBits()
Compute the tagbits for standard annotations.
|
int |
getEnclosingInstancesSlotSize() |
MethodBinding |
getExactConstructor(TypeBinding[] argumentTypes) |
MethodBinding |
getExactMethod(char[] selector,
TypeBinding[] argumentTypes,
CompilationUnitScope refScope) |
MethodBinding |
getExactMethodBase(char[] selector,
TypeBinding[] argumentTypes,
CompilationUnitScope refScope) |
FieldBinding |
getField(char[] fieldName,
boolean needResolve) |
FieldBinding |
getField(char[] fieldName,
boolean resolve,
InvocationSite site,
Scope scope)
Where multiple fields with the same name are defined, this will
return the one most visible one...
|
ReferenceBinding |
getMemberType(char[] typeName) |
MethodBinding[] |
getMethods(char[] selector) |
MethodBinding[] |
getMethodsBase(char[] selector) |
TypeBinding[] |
getNonWildcardParameterization(Scope scope) |
int |
getOuterLocalVariablesSlotSize() |
MethodBinding |
getSingleAbstractMethod(Scope scope,
boolean replaceWildcards)
Return the single abstract method of a functional interface, or null, if the receiver is not a functional interface as defined in JLS 9.8.
|
MethodBinding |
getSingleAbstractMethod(Scope scope,
boolean replaceWildcards,
int start,
int end) |
boolean |
hasMemberTypes() |
boolean |
hasTypeBit(int bit)
Answer an additional bit characterizing this type, like
TypeIds.BitAutoCloseable. |
boolean |
implementsMethod(MethodBinding method) |
protected void |
initializeArguments() |
boolean |
isBoundParameterizedType()
Returns true if parameterized type AND not of the form List>
|
boolean |
isEquivalentTo(TypeBinding otherType)
Returns true if a type is identical to another one,
or for generic types, true if compared to its raw type.
|
boolean |
isHierarchyConnected()
Returns true if the type hierarchy is connected
|
boolean |
isParameterizedType()
Returns true if the type is parameterized, e.g.
|
boolean |
isProperType(boolean admitCapture18)
JLS8 Sect 18.1.1
|
boolean |
isRawSubstitution()
Returns true for raw substitution
|
int |
kind() |
ReferenceBinding[] |
memberTypes() |
boolean |
mentionsAny(TypeBinding[] parameters,
int idx)
Does this type mention any of the given type parameters, except the one at position 'idx'?
|
MethodBinding[] |
methods() |
char[] |
nullAnnotatedReadableName(CompilerOptions options,
boolean shortNames)
Answer a readable name (for error reporting) that includes nullness type annotations.
|
int |
problemId()
Define to be able to get the computeId() for the inner type binding.
|
char[] |
qualifiedPackageName()
Answer the qualified name of the receiver's package separated by periods
or an empty string if its the default package.
|
char[] |
qualifiedSourceName()
Answer the source name for the type.
|
char[] |
readableName()
Answer the receiver's signature.
|
char[] |
shortReadableName() |
char[] |
signature()
Answer the receiver classfile signature.
|
char[] |
sourceName() |
TypeBinding |
substitute(TypeVariableBinding originalVariable)
Returns the type substitute for a given type variable, or itself
if no substitution got performed.
|
ReferenceBinding |
superclass() |
ReferenceBinding[] |
superInterfaces() |
void |
swapUnresolved(UnresolvedReferenceBinding unresolvedType,
ReferenceBinding resolvedType,
LookupEnvironment env) |
ReferenceBinding[] |
syntheticEnclosingInstanceTypes() |
SyntheticArgumentBinding[] |
syntheticOuterLocalVariables() |
java.lang.String |
toString() |
TypeBinding[] |
typeArguments() |
TypeVariableBinding[] |
typeVariables() |
TypeBinding |
unannotated()
Return this type minus its type annotations
|
TypeBinding |
uncapture(Scope scope)
Perform capture deconversion for a parameterized type with captured wildcard arguments
|
FieldBinding[] |
unResolvedFields() |
TypeBinding |
withoutToplevelNullAnnotation()
Return this type minus its toplevel null annotations.
|
acceptsNonNullDefault, appendNullAnnotation, applyCloseableClassWhitelists, applyCloseableInterfaceWhitelists, availableFields, availableMethods, binarySearch, binarySearch, canBeSeenBy, canBeSeenBy, canBeSeenBy, computeGenericTypeSignature, computeId, depth, detectAnnotationCycle, enclosingTypeAt, enumConstantCount, getAccessFlags, getAnnotations, getFileName, getMethods, getPackage, getTypeVariable, hashCode, hasIncompatibleSuperType, hasRestrictedAccess, implementsInterface, innerCanBeSeenBy, innerCanBeSeenBy, isAbstract, isAnnotationType, isBinaryBinding, isClass, isCompatibleWith, isConsistentIntersection, isDefault, isDeprecated, isEnum, isFinal, isFunctionalInterface, isHierarchyBeingActivelyConnected, isHierarchyBeingConnected, isInterface, isOrEnclosedByPrivateType, isPrivate, isProtected, isPublic, isStatic, isStrictfp, isSubtypeOf, isSubTypeOfRTL, isSuperclassOf, isThrowable, isUncheckedException, isUsed, isViewedAsDeprecated, outermostEnclosingType, retrieveAnnotationHolder, setAnnotations, setContainerAnnotationType, sortFields, sortMethods, tagAsHavingDefectiveContainerTypeclosestMatch, containerAnnotationType, dimensions, enclosingMethod, enterRecursiveFunction, equalsEquals, exitRecursiveFunction, findSuperTypeOriginatingFrom, findSuperTypeOriginatingFrom, genericCast, getErasureCompatibleType, getIntersectingTypes, getTypeAnnotations, hasNullTypeAnnotations, hasTypeAnnotations, isAnonymousType, isArrayType, isBaseType, isBoxedPrimitiveType, isBoxingCompatibleWith, isCapture, isCompatibleWith, isFunctionalType, isGenericType, isHierarchyInconsistent, isIntersectionType, isIntersectionType18, isLocalType, isMemberType, isNestedType, isNumericType, isParameterizedTypeWithActualArguments, isParameterizedWithOwnVariables, isPolyType, isPotentiallyCompatibleWith, isPrimitiveOrBoxedPrimitiveType, isPrimitiveType, isProvablyDistinct, isRawType, isReifiable, isRepeatableAnnotationType, isTypeArgumentContainedBy, isTypeVariable, isUnboundWildcard, isUnresolvedType, isWildcard, leafComponentType, needsUncheckedConversion, notEquals, original, prototype, setTypeAnnotations, signableName, sIsMoreSpecific, wellKnownTypecomputeUniqueKey, initializeDeprecatedAnnotationTagBits, isParameter, isTaggedRepeatable, isValidBinding, isVolatile, setAnnotationspublic ReferenceBinding type
public TypeBinding[] arguments
public LookupEnvironment environment
public char[] genericTypeSignature
public ReferenceBinding superclass
public ReferenceBinding[] superInterfaces
public FieldBinding[] fields
public ReferenceBinding[] memberTypes
public MethodBinding[] methods
protected ReferenceBinding enclosingType
public ParameterizedTypeBinding(ReferenceBinding type, TypeBinding[] arguments, ReferenceBinding enclosingType, LookupEnvironment environment)
public ReferenceBinding actualType()
actualType in class TypeBindinggenericType()public boolean isParameterizedType()
TypeBindingTypeBinding.isParameterizedTypeWithActualArguments() instead to find out.isParameterizedType in class TypeBindingpublic void boundCheck(Scope scope, TypeReference[] argumentReferences)
public boolean canBeInstantiated()
ReferenceBindingcanBeInstantiated in class ReferenceBindingReferenceBinding.canBeInstantiated()public ParameterizedTypeBinding capture(Scope scope, int start, int end)
capture in class TypeBindingTypeBinding.capture(Scope,int, int)public TypeBinding uncapture(Scope scope)
uncapture in class TypeBindingTypeBinding.uncapture(Scope)public java.util.List collectMissingTypes(java.util.List missingTypes)
TypeBindingcollectMissingTypes in class TypeBindingTypeBinding.collectMissingTypes(java.util.List)public void collectSubstitutes(Scope scope, TypeBinding actualType, InferenceContext inferenceContext, int constraint)
collectSubstitutes in class TypeBindingpublic void computeId()
computeId in class ReferenceBindingReferenceBinding.computeId()public char[] computeUniqueKey(boolean isLeaf)
ReferenceBindingcomputeUniqueKey in class ReferenceBindingpublic char[] constantPoolName()
ReferenceBindingconstantPoolName in class ReferenceBindingTypeBinding.constantPoolName()public TypeBinding clone(TypeBinding outerType)
TypeBindingclone in class TypeBindingpublic ParameterizedMethodBinding createParameterizedMethod(MethodBinding originalMethod)
public java.lang.String debugName()
debugName in class ReferenceBindingTypeBinding.debugName()public java.lang.String annotatedDebugName()
annotatedDebugName in class TypeBindingpublic ReferenceBinding enclosingType()
enclosingType in class TypeBindingTypeBinding.enclosingType()public LookupEnvironment environment()
Substitutionenvironment in interface SubstitutionSubstitution.environment()public TypeBinding erasure()
erasure in class TypeBindingTypeBinding.erasure()public int fieldCount()
fieldCount in class ReferenceBindingReferenceBinding.fieldCount()public FieldBinding[] fields()
fields in class ReferenceBindingReferenceBinding.fields()public ReferenceBinding genericType()
if no resolution is required (unlikely)public char[] genericTypeSignature()
genericTypeSignature in class TypeBindingpublic long getAnnotationTagBits()
BindinggetAnnotationTagBits in class ReferenceBindingReferenceBinding.getAnnotationTagBits()public int getEnclosingInstancesSlotSize()
getEnclosingInstancesSlotSize in class ReferenceBindingpublic MethodBinding getExactConstructor(TypeBinding[] argumentTypes)
getExactConstructor in class ReferenceBindingReferenceBinding.getExactConstructor(TypeBinding[])public MethodBinding getExactMethodBase(char[] selector, TypeBinding[] argumentTypes, CompilationUnitScope refScope)
public FieldBinding getField(char[] fieldName, boolean needResolve)
getField in class ReferenceBindingReferenceBinding.getField(char[], boolean)public ReferenceBinding getMemberType(char[] typeName)
getMemberType in class ReferenceBindingReferenceBinding.getMemberType(char[])public MethodBinding[] getMethodsBase(char[] selector)
ReferenceBinding.getMethods(char[])public int getOuterLocalVariablesSlotSize()
getOuterLocalVariablesSlotSize in class ReferenceBindingpublic boolean hasMemberTypes()
hasMemberTypes in class ReferenceBindingpublic boolean hasTypeBit(int bit)
TypeBindingTypeIds.BitAutoCloseable.hasTypeBit in class TypeBindingpublic boolean implementsMethod(MethodBinding method)
protected void initializeArguments()
public boolean isBoundParameterizedType()
isBoundParameterizedType in class TypeBindingpublic boolean isEquivalentTo(TypeBinding otherType)
TypeBindingisEquivalentTo in class TypeBindingpublic boolean isHierarchyConnected()
ReferenceBindingisHierarchyConnected in class ReferenceBindingpublic boolean isProperType(boolean admitCapture18)
TypeBindingisProperType in class ReferenceBindingadmitCapture18 - request if CaptureBinding18 shuld be considered as a proper type.
If unsure say 'true', only in Scope.greaterLowerBound(TypeBinding[], Scope, LookupEnvironment)
CaptureBinding18 has to be excluded to prevent an NPE on a branch that heuristically tries to avoid
inconsistent intersections.public boolean isRawSubstitution()
SubstitutionisRawSubstitution in interface SubstitutionSubstitution.isRawSubstitution()public TypeBinding unannotated()
TypeBindingunannotated in class TypeBindingpublic TypeBinding withoutToplevelNullAnnotation()
TypeBindingwithoutToplevelNullAnnotation in class TypeBindingpublic int kind()
kind in class TypeBindingpublic ReferenceBinding[] memberTypes()
memberTypes in class ReferenceBindingReferenceBinding.memberTypes()public boolean mentionsAny(TypeBinding[] parameters, int idx)
TypeBindingmentionsAny in class TypeBindingpublic MethodBinding[] methods()
methods in class ReferenceBindingReferenceBinding.methods()public int problemId()
problemId in class BindingBinding.problemId()public char[] qualifiedPackageName()
TypeBindingqualifiedPackageName in class TypeBindingTypeBinding.qualifiedPackageName()public char[] qualifiedSourceName()
ReferenceBindingqualifiedSourceName in class ReferenceBindingTypeBinding.qualifiedSourceName()public char[] readableName()
ReferenceBindingreadableName in class ReferenceBindingBinding.readableName()public char[] shortReadableName()
shortReadableName in class ReferenceBindingBinding.shortReadableName()public char[] nullAnnotatedReadableName(CompilerOptions options, boolean shortNames)
TypeBindingnullAnnotatedReadableName in class ReferenceBindingTypeBinding.nullAnnotatedReadableName(CompilerOptions,boolean)public char[] signature()
TypeBindingsignature in class ReferenceBindingTypeBinding.signature()public char[] sourceName()
sourceName in class ReferenceBindingTypeBinding.sourceName()public TypeBinding substitute(TypeVariableBinding originalVariable)
Substitutionsubstitute in interface SubstitutionSubstitution.substitute(org.aspectj.org.eclipse.jdt.internal.compiler.lookup.TypeVariableBinding)public ReferenceBinding superclass()
superclass in class ReferenceBindingReferenceBinding.superclass()public ReferenceBinding[] superInterfaces()
superInterfaces in class ReferenceBindingReferenceBinding.superInterfaces()public void swapUnresolved(UnresolvedReferenceBinding unresolvedType, ReferenceBinding resolvedType, LookupEnvironment env)
swapUnresolved in class TypeBindingpublic ReferenceBinding[] syntheticEnclosingInstanceTypes()
syntheticEnclosingInstanceTypes in class ReferenceBindingReferenceBinding.syntheticEnclosingInstanceTypes()public SyntheticArgumentBinding[] syntheticOuterLocalVariables()
syntheticOuterLocalVariables in class TypeBindingTypeBinding.syntheticOuterLocalVariables()public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()public TypeVariableBinding[] typeVariables()
typeVariables in class TypeBindingpublic TypeBinding[] typeArguments()
public FieldBinding[] unResolvedFields()
unResolvedFields in class ReferenceBindingpublic MethodBinding getSingleAbstractMethod(Scope scope, boolean replaceWildcards)
TypeBindinggetSingleAbstractMethod in class ReferenceBindingscope - scopereplaceWildcards - Should wildcards be replaced following JLS 9.8? Say false for lambdas with explicit argument types which should apply 18.5.3public MethodBinding getSingleAbstractMethod(Scope scope, boolean replaceWildcards, int start, int end)
public TypeBinding[] getNonWildcardParameterization(Scope scope)
public FieldBinding getField(char[] fieldName, boolean resolve, InvocationSite site, Scope scope)
ReferenceBindinggetField in class ReferenceBindingpublic MethodBinding getExactMethod(char[] selector, TypeBinding[] argumentTypes, CompilationUnitScope refScope)
getExactMethod in class ReferenceBindingpublic MethodBinding[] getMethods(char[] selector)
getMethods in class ReferenceBinding