This content has been marked as final.
Show 2 replies
-
1. Re: Intercept invoke(Object, Object[])
kabirkhan Nov 4, 2004 1:52 PM (in response to ad-rocha)Hi,
Does this help?<bind pointcut="call(public java.lang.Object java.lang.reflect.Method->invoke(java.lang.Object, java.lang.Object[]) throws java.lang.IllegalAccessException, java.lang.IllegalArgumentException, java.lang.reflect.InvocationTargetException) AND withincode(protected void $instanceof{junit.framework.TestCase}->runTest() throws Throwable)"> <interceptor-ref name="aftt.weaving.TestCaseInterceptor"/> </bind>
1) java system classes cannot be instrumented so caller pointcuts must be used. The reflection aspect was written for this, so use 'call' instead of 'execution'.
2) Everything must use fully qualified names. Even stuff in the java.lang package
HTH
Kabir -
2. Re: Intercept invoke(Object, Object[])
ad-rocha Nov 4, 2004 2:19 PM (in response to ad-rocha)Thanks Kabir,
It's working now!
Andre