aboutsummaryrefslogtreecommitdiffstats
path: root/tests/features197/java15/PersonAspect.aj
blob: 695a4de363b81d7a4aacbb07dc5a5e2d6517ad3f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
public aspect PersonAspect {
  // Weave into sealed class
  void around(String name): execution(void sayHello(*)) && args(name) {
    proceed("Sir " + name);
  }

  // ITD into non-sealed subclass of sealed class
  private String Manager.jobTitle;

  public void TopManager.setJobTitle(String jobTitle) {
    this.jobTitle = jobTitle;
  }

  public String TopManager.getJobTitle() {
    return jobTitle;
  }
}