Capturing Primitive Assignments [message #34389] |
Sat, 17 April 2004 20:20 |
Eclipse User |
|
|
|
Originally posted by: bret540.yahoo.com
For a school assignment, we are trying to model a stack machine using
AspectJ. I need to figure out how I can write a Pointcut that can execute
before ANY variable is used inside of a method.
For example in this method,
public static int bar(){
String str;
int r;
str = new String(here);
r = str.length();
return r;
}
I need to capture the initialization of 'str' and 'r' and the values they
are assigned. Can anoyne give me a hand or point me in the right
direction? (I already know how one can capture a method and capture a
getter or a setter, but I believe capturing primitives is a little
trickier)
Thanks,
Bret
|
|
|
Powered by
FUDForum. Page generated in 0.02053 seconds