Building the service layer

The service layer classes and interfaces will follow the same naming conventions of our DAO layer, where Service simply replaces the Dao equivalent name:

Building the service layer

Our first definition will be for the Result class.

The Result Data Transfer Object

The service layer will communicate with the request handling tier through interfaces that return Result Data Transfer Objects (DTO). The DTO design pattern is commonly used in enterprise application programming to transfer data between different layers or subsystems. Our Result DTO will have the following three properties:

  • boolean success: This property is used if the action was successful ...

Get Enterprise Application Development with Ext JS and Spring now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.