blob: 7a2296f293725d86e120b4be1e7d71ff818b9cb5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
package test;
import test.ChildInt;
import test.Parent;
import test.ParentInt;
public aspect AspectTrace {
public pointcut p1(): execution(* test.Parent+.do*(..));
public pointcut p2(): withincode(* test.Parent+.do*(..)) && this(test.Parent+);
public pointcut p3() : execution(* test.ParentInt.*(..));
public pointcut p4() : execution(* test.ChildInt.*(..));
before() : p1() {
System.out.println("p1" + thisJoinPoint);
}
// before() : p2(){
// System.out.println("p2" + thisJoinPoint);
// }
//
before() : p3() {
System.out.println("p3" + thisJoinPoint);
}
//
// before() : p4() {
// System.out.println("p4" + thisJoinPoint);
// }
}
|