[aspectwerkz-user] Is there a way to get a pointcut name from within an around advic e?
"Krasheninnikov, Konstantin " <[email protected]>
| Newsgroups | gmane.comp.java.aspectwerkz.user |
|---|---|
| Message-ID | <B649D06566185B459613184B8B87794D0EC569FC@gsnmp17es.firmwide.corp.gs.com> |
Hello,
Given
...
<aspect class="HelloWorldHijacker">
<pointcut name="greetMethod" expression="execution(*
testAOP.HelloWorld2.greet(..))"/>
<advice name="yellifyier" type="around" bind-to="greetMethod"/>
</aspect>
...and
public class HelloWorldHijacker {
public Object yellifyier( JoinPoint joinPoint ) {
String ret = null;
try {
// How to get to the pointcut name (which is "greetMethod") here
??
Object greeting = joinPoint.proceed();
ret = "<yell>" + greeting + "</yell>";
}
catch( Throwable e ) {
e.printStackTrace();
}
return ret;
}
}
Q: Is there a way to get the pointcut name from within the around advice?
Thanks in advance,
-krosh-
P.S. I am attching the ML subscription reply:
<<WELCOME to [email protected]>>
(unnamed)
(message/rfc822, 9.1 KB) - not displayed