This content has been marked as final.
Show 5 replies
-
1. Re: Caller pointcuts
kabirkhan Jun 15, 2005 1:56 PM (in response to oberon777)"oberon777" wrote:
Is there a way to get call site information (line number, etc.) from a CallerInvocation?
No"oberon777" wrote:
Also is there some sort of a Wrapper interface for getting arguments and the called method/constructor from a CallerInvocation? All sublasses seem to define means for doing so.
You need to cast it to the correct subclass (MethodCallefByMethodInvocation etc.) and access the methods from there. -
2. Re: Caller pointcuts
oberon777 Jun 15, 2005 2:11 PM (in response to oberon777)You mean, line # information is never recorded at all?..
This is a little surprising because I would think that this is not an uncommon requirement to disambiguate based on the call site.
-Ben -
3. Re: Caller pointcuts
oberon777 Jun 15, 2005 2:12 PM (in response to oberon777)Also, is the situation any different for "callee" pointcuts? It is possible to query the calling method for the line #?
-
4. Re: Caller pointcuts
bill.burke Jun 16, 2005 8:18 AM (in response to oberon777)writing an aspect that depends on line number sounds quite dangerous and eroneous. We will never support it..Sorry...
-
5. Re: Caller pointcuts
oberon777 Jun 17, 2005 1:25 PM (in response to oberon777)I didn't mean depending on the line number, sorry...
I just meant logging the line number for debugging purposes. Anyway, I got it to work using exceptions, which allow one to query the stack trace.