Przeglądaj źródła

excluding new preinitialization join points

tags/V_1_1_b5
jhugunin 21 lat temu
rodzic
commit
bc0c559654
2 zmienionych plików z 2 dodań i 2 usunięć
  1. 1
    1
      tests/new/AroundAll.java
  2. 1
    1
      tests/new/CflowAlone.java

+ 1
- 1
tests/new/AroundAll.java Wyświetl plik

@@ -154,7 +154,7 @@ aspect A {
}

Object around(): //initialization(C.new(String)) {
if(test()) && !within(A) && !call(* A.*(..)) {
if(test()) && !within(A) && !call(* A.*(..)) && !preinitialization(new(..)) {
A.log("enter " + thisJoinPoint);
Object ret = proceed();
A.log("exit " + thisJoinPoint);

+ 1
- 1
tests/new/CflowAlone.java Wyświetl plik

@@ -20,7 +20,7 @@ aspect Filteraspect {
//pointcut goCut(): cflow(!within(FilterAspect));
//pointcut goCut(): cflow(within(FilterAspect));
//pointcut goCut(): cflow(within(testclass1));
pointcut goCut(): !within(Filteraspect) && cflow(within(testclass1));
pointcut goCut(): !within(Filteraspect) && cflow(within(testclass1)) && !preinitialization(new(..));
// works ok
//pointcut goCut(): within(Filteraspect);
Object around(): goCut() { i++; return proceed(); }

Ładowanie…
Anuluj
Zapisz