A Beneficial Scenario. Figure 10 shows a scenario where the use of aspects is
advantageous. In this scenario, in the left-hand side of the template, the three
marked preconditions are used to check the nullity of the input parameters of the
three methods illustrated in the class Employee (e.g. JC.requires(name ! ¼ null) for
the method setName). Therefore, it is straightforward to implement these homogenous
preconditions with a single before advice in the AO version (as illustrated in
the right-hand side of the refactoring template).