Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

123456789101112131415161718192021222324252627
  1. import org.aspectj.testing.Tester;
  2. public class PointcutFormals {
  3. public static void main(String[] args) {
  4. new PointcutFormals().call(0);
  5. Tester.check(false, "Shouldn't have compiled!");
  6. }
  7. void call(int i) {}
  8. }
  9. aspect Aspect {
  10. int n;
  11. pointcut calls_pc1 (int n): call(void *.call(n));
  12. pointcut calls_pc2 (int n): call(void *.call(..));
  13. pointcut calls_pc (): call(void *.call(n));
  14. pointcut executions_pc(): execution(void *(n));
  15. before(): calls_pc () { }
  16. before(): executions_pc() { }
  17. after(): calls_pc () { }
  18. after(): executions_pc() { }
  19. void around(): calls_pc () { }
  20. void around(): executions_pc() { }
  21. }