In this chapter, you've learned a new way to factor business logic beyond encapsulating it in the Service layer—one that aligns the logic—implementing the validation changes and interpretation of an object's data through a Domain class named accordingly. As with the Service layer, this approach makes such code easy to find for new and experienced developers working on the code base.
A Domain class combines the traditional Apex Trigger logic and custom Domain logic, such as the calculation of championship points for a contestant or the verification of compliance rules against the cars, drivers, and teams.
By utilizing Apex classes, the ability to start leveraging OOP practices emerges, using interfaces and factory methods to implement functional subsystems within the application to deliver not only implementation speed, consistency, and reuse, but...