Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] Does target() work when calling static methods

target() will not match for static methods.

cheers,
Andy.

2009/3/9 Jochen Wuttke <jochen.wuttke@xxxxxx>
Hi,

I have an aspect that does not do what I expect. The pointcut looks like this:

   pointcut initMethod(): target(JspFactory)
       && call(* javax.servlet.jsp.JspFactory.setDefaultFactory(..));

The advice addressed by this joinpoint doesn't get woven and I start suspecting that this is because #setDefaultFactory is static, and hence there is no target object. Is that a correct interpretation or am I missing something else?

Jochen
_______________________________________________
aspectj-users mailing list
aspectj-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/aspectj-users


Back to the top