summaryrefslogtreecommitdiffstats
path: root/tests/new/subaspects/parent/PrivatePointcutOuterClass.java
blob: 7ae3752c0ffe2d334452fffc2353fdfb54a1dec8 (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
package parent;

import org.aspectj.testing.*;

/** PR#647 outer subaspects of an aspect with private pointcut */
public abstract aspect PrivatePointcutOuterClass {
    public static void main (String[] args) {
        Tester.event("main");
        Tester.checkAllEvents();
    } 
    static {
        Tester.expectEvent("main");
        Tester.expectEvent("definePrivate");
    }
    
    before() : definePrivate() {
        Tester.event("definePrivate");
    }

    /** private must be implemented in defining class */
    private pointcut definePrivate() 
        : execution(void PrivatePointcutOuterClass.main(..));
}
aspect InnerChild extends PrivatePointcutOuterClass { }