October 2006
Intermediate to advanced
880 pages
22h 11m
English
Mixing data-access code with application logic violates the emphasis on separation of concerns. There are several reasons why you should consider hiding the Hibernate calls behind a facade, the so-called persistence layer:
The persistence layer can provide a higher level of abstraction for data-access operations. Instead of basic CRUD and query operations, you can expose higher-level operations, such as a getMaximumBid() method. This abstraction is the primary reason why you want to create a persistence layer in larger applications: to support reuse of the same non-CRUD operations.
The persistence layer can have a generic interface without exposing actual implementation details. In other words, you can hide ...