Top Inners Fields Constructors Methods
org.aspectj.weaver

public abstract Class ResolvedType

extends UnresolvedType
implements AnnotatedElement
Class Inheritance
All Implemented Interfaces
org.aspectj.weaver.AnnotatedElement
Known Direct Subclasses
org.aspectj.weaver.ResolvedType.Primitive, org.aspectj.weaver.ResolvedType.Missing, org.aspectj.weaver.MissingResolvedTypeWithKnownSignature, org.aspectj.weaver.ReferenceType
Imports
java.lang.reflect.Modifier, java.util.ArrayList, .Arrays, .Collection, .Collections, .HashMap, .HashSet, .Iterator, .LinkedList, .List, .Map, .Queue, .Set, org.aspectj.bridge.IMessage, .ISourceLocation, .Message, .MessageUtil, org.aspectj.util.FuzzyBoolean, org.aspectj.weaver.AjAttribute.WeaverVersionInfo, .Iterators.Getter, org.aspectj.weaver.patterns.Declare, .PerClause

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
ResolvedType.FieldGetter

An Iterators.Getter that returns an iterator over all fields declared on some resolved type.

private static class
ResolvedType.MethodGetter

An Iterators.Getter that returns an iterator over all methods declared on some resolved type.

private static class
pack-priv static class
private static class
ResolvedType.PointcutGetter

An Iterators.Getter that returns an iterator over all pointcuts declared on some resolved type.

pack-priv static class
pack-priv static class
pack-priv static class

Field Summary

Modifier and TypeField and Description
private static int
private static int
private String
protected int
public CrosscuttingMembers
public static final ResolvedType[]
public static final ResolvedType[]
private static final ResolvedType.FieldGetter
private static int
private static int
protected List<ConcreteTypeMunger>
private static int
private static int
private static int
private static final ResolvedType.MethodGetter
private static final ResolvedType.MethodGetterIncludingItds
public static final ResolvedType.Missing
private static int
public static final ResolvedType[]
public static final String
private FuzzyBoolean
private static final ResolvedType.PointcutGetter
private ResolvedType[]
public ResolvedType[]
private static int
protected static Set<String>
protected World
Inherited from org.aspectj.weaver.UnresolvedType:
AJC_PRIVILEGEDANNOTATIONARRAY_WITH_JUST_OBJECTAT_INHERITEDAT_RETENTIONAT_TARGETBOOLEANBYTECHARCLONEABLEDOUBLEENUMERRORFLOATINTJAVA_LANG_ANNOTATIONJAVA_LANG_CLASS_ARRAYJAVA_LANG_REFLECT_CONSTRUCTORJAVA_LANG_REFLECT_FIELDJAVA_LANG_REFLECT_METHODJL_CLASSJL_EXCEPTIONJL_STRINGJOINPOINT_ENCLOSINGSTATICPARTJOINPOINT_STATICPARTLONGMISSING_NAMEOBJECTOBJECTARRAYPROCEEDING_JOINPOINTRUNTIME_EXCEPTIONSERIALIZABLESHORTsignaturesignatureErasureSOMETHINGSUPPRESS_AJ_WARNINGSTHROWABLEtypeKindtypeParameterstypeVariablesVOID

Constructor Summary

AccessConstructor and Description
protected
ResolvedType(String signature, World world)

protected
ResolvedType(String signature, String signatureErasure, World world)

Method Summary

Modifier and TypeMethod and Description
private void
addAndRecurse(Set<String> knowninterfaces, List<ResolvedMember> collector, ResolvedType resolvedType, boolean includeITDs, boolean allowMissing, boolean genericsAware)

public void
public void
addInterTypeMunger(ConcreteTypeMunger munger, boolean isDuringCompilation)

Add an intertype munger to this type.

public void
private void
protected boolean
public boolean
canAnnotationTargetType()

Note

Only overridden by ReferenceType subtype

public boolean
private boolean

Returns:

indicates if the munger failed the check
checkAbstractDeclaration
(ConcreteTypeMunger munger)

See PR70794.

public void
checkInterTypeMungers()

Check: 1) That we don't have any abstract type mungers unless this type is abstract.

public boolean

Returns:

true if the override is legal note: calling showMessage with two locations issues TWO messages, not ONE message with an additional source location.
checkLegalOverride
(ResolvedMember parent, ResolvedMember child, int
which parameter is the type transformer (0x10 for first, 0x01 for second, 0x11 for both, 0x00 for neither)
transformerPosition
,
ResolvedType
the declaring type of aspect defining the *first* type transformer
aspectType
)

private boolean

Returns:

true if there is a clash
clashesWithExistingMember
(ConcreteTypeMunger typeTransformer, Iterator<ResolvedMember> existingMembers)

Compare the type transformer with the existing members.

public void
public CrosscuttingMembers
collectCrosscuttingMembers(boolean shouldConcretizeIfNeeded)

public final List<Declare>
collectDeclares(boolean includeAdviceLike)

protected void
private void
private final List<ShadowMunger>
private int
public static boolean
public static boolean
conflictingSignature(Member m1, Member m2, boolean v2itds)

Do the two members conflict?

public ResolvedType
discoverActualOccurrenceOfTypeInHierarchy(ResolvedType lookingFor)

Look up the actual occurence of a particular type in the hierarchy for 'this' type.

protected boolean
private void
public void
ensureConsistent()

Undo any temporary modifications to the type (for example it may be holding annotations temporarily whilst some matching is occurring - These annotations will be added properly during weaving but sometimes for type completion they need to be held here for a while).

public boolean
equals(Object
the reference object with which to compare.
other
)

Overrides org.aspectj.weaver.UnresolvedType.equals.

Equality is checked based on the underlying signature.
public ConcreteTypeMunger
fillInAnyTypeParameters(ConcreteTypeMunger munger)

Called for all type mungers but only does something if they share type variables with a generic type which they target.

private ResolvedMember[]
public ResolvedPointcutDefinition
private boolean
genericTypeEquals(ResolvedType other)

Checks if the generic type for 'this' and the generic type for 'other' are the same - it can be passed raw or parameterized versions and will just compare the underlying generic type.

protected Map<String, UnresolvedType>
public AnnotationAJ
public AnnotationAJ[]
public AnnotationTargetKind[]
getAnnotationTargetKinds()

Note

Only overridden by ReferenceType subtype

public ResolvedType[]
public String
getBinaryPath()

Returns the path to the jar or class file from which this binary aspect came or null if not a binary aspect

public int

Returns:

the (major) version, WeaverVersionInfo
getCompilerVersion
()

return the weaver version used to build this type - defaults to the most recent version unless discovered otherwise.

public List<ShadowMunger>
public abstract ResolvedMember[]
public abstract ResolvedType[]
public ResolvedMember[]
public ResolvedMember[]
public abstract ResolvedMember[]
public abstract ResolvedMember[]
public List<ShadowMunger>
public Collection<Declare>
public ResolvedType

Returns:

the declaring type, or null if it is not an nested type.
getDeclaringType
()

Returns a ResolvedType object representing the declaring type of this type, or null if this type does not represent a non-package-level-type.

public final Iterator<ResolvedType>
getDirectSupertypes()

Returns an iterator through ResolvedType objects representing all the direct supertypes of this type.

public List<ResolvedMember>
public Iterator<ResolvedMember>
getFields()

returns an iterator through all of the fields of this type, in order for checking from JVM spec 2ed 5.4.3.2.

public ReferenceType
getGenericType()

Overridden by ReferenceType to return a sensible answer for parameterized and raw types.

public Iterator<ResolvedType>

Returns:

an iterator over all types in the hierarchy of this type
getHierarchy
()

Return an iterator over the types in this types hierarchy - starting with this type first, then all superclasses up to Object and then all interfaces (starting with those 'nearest' this type).

public Iterator<ResolvedType>

Returns:

an iterator over all types in the hierarchy of this type
getHierarchy
(final boolean
true if the caller wants full generic information
wantGenerics
,
final boolean
true if the caller even wants those parents introduced via declare parents
wantDeclaredParents
)

Return an iterator over the types in this types hierarchy - starting with this type first, then all superclasses up to Object and then all interfaces (starting with those 'nearest' this type).

public List<ResolvedType>

Returns:

list of resolvedtypes in this types hierarchy, including this type first
getHierarchyWithoutIterator
(boolean includeITDs, boolean allowMissing, boolean
should the list include parameterized/generic types (if not, they will be collapsed to raw)?
genericsAware
)

Return a list of the types in the hierarchy of this type, starting with this type.

public List<ConcreteTypeMunger>
public List<ConcreteTypeMunger>
public List<ConcreteTypeMunger>
public List<ConcreteTypeMunger>
protected Map<String, UnresolvedType>
public Iterator<ResolvedMember>
getMethods(boolean
is true if the caller would like all generics information, otherwise those methods are collapsed to their erasure
wantGenerics
,
boolean wantDeclaredParents)

returns an iterator through all of the methods of this type, in order for checking from JVM spec 2ed 5.4.3.3.

public Iterator<ResolvedMember>
getMethodsIncludingIntertypeDeclarations(boolean wantGenerics, boolean wantDeclaredParents)

public List<ResolvedMember>
getMethodsWithoutIterator(boolean includeITDs, boolean allowMissing, boolean genericsAware)

Return a list of methods, first those declared on this class, then those declared on the superclass (recurse) and then those declared on the superinterfaces.

public abstract int
private ISourceLocation
getMungerLocation(ConcreteTypeMunger munger)

Get a source location for the munger.

public ResolvedType
public PerClause
public Iterator<ResolvedMember>
getPointcuts()

returns an iterator through all of the pointcuts of this type, in order for checking from JVM spec 2ed 5.4.3.2 (as for fields).

public Collection<ResolvedMember>
public ResolvedType
public ResolvedType
public ResolvedType[]
public String
public int
getSize()

Overrides org.aspectj.weaver.UnresolvedType.getSize.

This is the size of this type as used in JVM.
public abstract ISourceContext
public ISourceLocation
public abstract ResolvedType

Returns:

the superclass of this type, or null (if this represents a jlObject, primitive, or void)
getSuperclass
()

public ResolvedType
public Collection<ConcreteTypeMunger>
public WeaverStateInfo
public World
public boolean
private boolean
private void
public final boolean
public boolean
isAnnotation()

Note

Only overridden by Name subtype.

public boolean
public boolean
isAnnotationWithRuntimeRetention()

Note

Only overridden by Name subtype.

public boolean
public boolean
public abstract boolean

Returns:

true iff variables of this type could be assigned values of other without casting
isAssignableFrom
(ResolvedType
the other type
other
)

Determines if the variables of this type could be assigned values of another type without casting.

public abstract boolean
isAssignableFrom(ResolvedType other, boolean allowMissing)

public boolean
public boolean

Returns:

true if it is an exception and it is a checked one, false otherwise.
isCheckedException
()

public boolean
public abstract boolean

Returns:

true iff values of other could possibly be cast to this type.
isCoerceableFrom
(ResolvedType
the other type
other
)

Determines if values of another type could possibly be cast to this type.

public final boolean

Returns:

true iff variables of this type could be assigned values of other with possible conversion
isConvertableFrom
(ResolvedType
the other type
other
)

Determines if variables of this type could be assigned values of another with lots of help.

private boolean
public boolean
isEnum()

Note

Only overridden by Name subtype.

public boolean

Returns:

true if assignable to java.lang.Exception
isException
()

public boolean
public final boolean
public boolean
public boolean
isInheritedAnnotation()

For an annotation type, this will return if it is marked with @Inherited

public final boolean
public boolean
public static boolean
public static boolean
isMoreVisible(int m1, int m2)

public boolean
private static boolean
isPackage(int i)

public boolean
isParameterizedWithTypeVariable()

return true if the parameterization of this type includes a member type variable.

public boolean
public boolean
public boolean
public boolean
public boolean
public static boolean
isVisible(int modifiers, ResolvedType targetType, ResolvedType fromType)

public ResolvedMember
lookupDirectlyDeclaredMemberNoSupers(Member member)

as lookupMemberNoSupers, but does not include ITDs

public ResolvedMember
lookupField(Member field)

described in JVM spec 2ed 5.4.3.2

private ResolvedMember
lookupMember(Member m, ResolvedMember[] a)

return null if not found

public ResolvedMember
lookupMemberIncludingITDsOnInterfaces(Member member)

This lookup has specialized behaviour - a null result tells the EclipseTypeMunger that it should make a default implementation of a method on this type.

private ResolvedMember
public ResolvedMember
lookupMemberNoSupers(Member member)

Look up a member, takes into account any ITDs on this type.

public ResolvedMember
public ResolvedMember
lookupMethod(Member m)

described in JVM spec 2ed 5.4.3.3.

public ResolvedMember

Returns:

the real signature defined by any matching intertype declaration, otherwise null
lookupMethodInITDs
(Member
the member to lookup in intertype declarations affecting this type
member
)

public ResolvedMember
lookupResolvedMember(ResolvedMember aMember, boolean allowMissing, boolean eraseGenerics)

Looks for the first member in the hierarchy matching aMember.

public ResolvedMember
public static ResolvedType
makeArray(ResolvedType type, int dim)

public static boolean
public boolean
public UnresolvedType
parameterize(Map<String, UnresolvedType> typeBindings)

Overrides org.aspectj.weaver.UnresolvedType.parameterize.

Iff I am a parameterized type, and any of my parameters are type variable references (or nested parameterized types), return a version with those type parameters replaced in accordance with the passed bindings.
public ResolvedType
private void
recurseHierarchy(Set<String> knowninterfaces, List<ResolvedType> collector, ResolvedType resolvedType, boolean includeITDs, boolean allowMissing, boolean genericsAware)

Recurse up a type hierarchy, first the superclasses then the super interfaces.

private static boolean
samePackage(ResolvedType targetType, ResolvedType fromType)

public void
setBinaryPath(String binaryPath)

public void
private String
toString(UnresolvedType[] typeParameters)

private String
Inherited from org.aspectj.weaver.UnresolvedType:
addforGenericTypeforGenericTypeSignatureforGenericTypeVariablesforNameforNamesforPrimitiveTypeforRawTypeNameforSignatureforSignaturesgetBaseNamegetClassNamegetComponentTypegetDimensionsgetErasureSignaturegetNamegetNameAsIdentifiergetNamesgetOutermostTypegetPackageNamegetPackageNameAsIdentifiergetRawNamegetSignaturegetSimpleBaseNamegetSimpleNamegetTypekindgetTypeParametersgetTypeVariableNamedgetTypeVariableshashCodeinsertisArrayisGenericTypeisGenericWildcardisParameterizedOrGenericTypeisParameterizedOrRawTypeisParameterizedTypeisPrimitiveTypeisRawTypeisSimpleTypeisTypeVariableReferenceisVoidmakeArrayneedsModifiableDelegatereadreadArrayresolvesetNeedsModifiableDelegatetoDebugStringtoStringtoTraceStringwritewriteArray