* @see org.aspectj.weaver.patterns.Pointcut#match(org.aspectj.weaver.Shadow)
*/
protected FuzzyBoolean matchInternal(Shadow shadow) {
AnnotatedElement toMatchAgainst = null;
Member member = shadow.getSignature();
ResolvedMember rMember = member.resolve(shadow.getIWorld());
if (rMember == null) {
if (member.getName().startsWith(NameMangler.PREFIX)) {
return FuzzyBoolean.NO;
}
shadow.getIWorld().getLint().unresolvableMember.signal(member.toString(), getSourceLocation());
return FuzzyBoolean.NO;
}
Shadow.Kind kind = shadow.getKind();
if (kind == Shadow.StaticInitialization) {
toMatchAgainst = rMember.getDeclaringType().resolve(shadow.getIWorld());
} else if ((kind == Shadow.ExceptionHandler)) {
toMatchAgainst = rMember.getParameterTypes()[0].resolve(shadow.getIWorld());
} else {
toMatchAgainst = rMember;
// FIXME asc I'd like to get rid of this bit of logic altogether, shame ITD fields don't have an effective sig attribute
// FIXME asc perf cache the result of discovering the member that contains the real annotations
if (rMember.isAnnotatedElsewhere()) {
if (kind == Shadow.FieldGet || kind == Shadow.FieldSet) {
// FIXME asc should include supers with getInterTypeMungersIncludingSupers ?
List mungers = rMember.getDeclaringType().resolve(shadow.getIWorld()).getInterTypeMungers();
for (Iterator iter = mungers.iterator(); iter.hasNext();) {
ConcreteTypeMunger typeMunger = (ConcreteTypeMunger) iter.next();
if (typeMunger.getMunger() instanceof NewFieldTypeMunger) {
ResolvedMember fakerm = typeMunger.getSignature();
if (fakerm.equals(member)) {
ResolvedMember ajcMethod = AjcMemberMaker.interFieldInitializer(fakerm, typeMunger.getAspectType());
ResolvedMember rmm = findMethod(typeMunger.getAspectType(), ajcMethod);
toMatchAgainst = rmm;
}
}
}
}