[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] catching methods *not* calling a specific method?

Hello,
 
Is it possible to have a static pointcut that would
flag methods whose implementations do *not* call
another, specified method? Some akin to:
 
execution (* MySuperClass+.someMethod*(..)) && !(call
(* MySuperClass+.wantedMethod()) );

(which doesn't work).

I'm not very sure it's possible, whether
wantedMethod() is called depends on the program flow.
In my case it's a linear flow (and no exceptions), but
this is still a particular case of program flow.

Thanks,
Razvan

PS (yeah, instead of checking the call, the better way
would be to add an aspect making the call, but I
cannot do that right now within my project's
constraints).