hi, say I have the following classes:

public class A {
  B b = new B();
  private void ma() {
    b.mb();
 }
}
public class B {
  C b = new C();
 private void ma() {
   for(something){
     c.mc();
   }
 }
}

Now I want to catch the join point of calling to --or executing -- C.mc and
get the object of class A who on the top of the call stack, like this:
 private pointcut p(int thisDone,Object iWantA) :
  call(* C.mc(..)) &&
  cflowbelow(execution(* A.ma()))
  && args(byte[], int, thisDone)
  && this(iWantA);

I know this won't work. I can only get b when use this. But how can I get a?
Can any one give me some suggestion?
_______________________________________________
aspectj-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/aspectj-users

Reply via email to