Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[aspectj-users] Updating variable in the middle of a method

Suppose I have a method like the following:

public StringBuffer myMethod() {
     StringBuffer sb = new StringBuffer();
     return sb.toString();

I want to update this to always return 123.
I would like to do this via an execution pointcut (I don't want to use call)
so I need do get a handle to the sb variable?  Any ideas how this can be

Thanks a million.


View this message in context:
Sent from the AspectJ - users mailing list archive at

Back to the top