David_W (70) [Avatar] Offline
In listing 16.24, the pointcut could be changed from
pointcut lineOrderModification() : execution(* LineItem.set*(..));
pointcut lineOrderModification() : set(* LineItem.*);

This simplifies the case where the rich domain model means that other methods than setters in LineItem might modify state.
Of course, this might also introduce issues with the repository. However, assuming that the Order class has methods to load an order, and this also loads the associated line items, then the cflow solves this.
ramnivas (171) [Avatar] Offline
Re: alternative pointcut in LineItemExposureControlAspect in 16.3.1
I made a note. Thanks.