spogulis no
https://github.com/eclipse-aspectj/aspectj.git
synced 2024-09-03 17:56:34 +02:00
26 rindas
678 B
Java
26 rindas
678 B
Java
import org.aspectj.testing.Tester;
|
|
|
|
/** @testcase PR#619 direct use outside aspect of defined abstract pointcut */
|
|
public abstract aspect AbstractPointcutAccess {
|
|
public static void main (String[] args) {
|
|
Tester.event("main");
|
|
Tester.checkAllEvents();
|
|
}
|
|
static {
|
|
Tester.expectEvent("main");
|
|
Tester.expectEvent("used");
|
|
}
|
|
|
|
abstract pointcut abstractPointcut();
|
|
}
|
|
aspect ConcretePointcutAccess extends AbstractPointcutAccess {
|
|
pointcut abstractPointcut() : execution(void main(..));
|
|
}
|
|
|
|
aspect AbstractPointcutUser {
|
|
before () : ConcretePointcutAccess.abstractPointcut() {
|
|
Tester.event("used");
|
|
}
|
|
}
|
|
|