PetClinic业务逻辑很少,该示例项目主要是展示持久化层。但是没有展示ibatis,展示ibatis是在JPetStore这个示例项目。
1、
Since the PetClinic application is all about database access and there is very little business logic in the application outside of that, there is no separation of the primary Business and Persistence Layer API‘s. While this design technique should not be used for an application with more complex business logic, it is acceptable here because all of the non-persistence related business rules have been implemented in business objects and have not leaked into the Persistence Layer. The most important facet of the design is that the Business and Persistence Layers are COMPLETELY independent of the Presentation Layer.
The Persistence Layer can be configured to use either HSQL or MySQL with any one of the following data access technologies aided by infrastructure provided by Spring:
JDBC
Hibernate 3
Java Persistence API(JPA)
NOTE: Spring also provides infrastructure for using other Object/Relational Mapping frameworks such as JDO and iBATIS SqlMaps, but these are not demonstrated in PetClinic. (See the ‘jpetstore‘ sample application that ships with the full Spring Framework distribution for an example of using iBatis and Spring.)
原文:http://my.oschina.net/diedai/blog/519060