Question

In a Wicket/Spring/Hibernate project I inherited I find the following pattern:

For each Entity there exists an abstract class called EntityHome generated by Hibernate Tools which provides methods for finding, persisting, merging, and removing Entity. In another package there are classes called EntityDao for each EntityHome which in most cases simply extend EntityHome without adding any additional functionality.

Normally I would create a single generic DAO for handling persist, find, merge, and remove generically and have all DAOs extend this one.

The closest thing to some kind of documentation for Home Objects I found is http://docs.jboss.org/seam/1.1GA/reference/en/html/framework.html#d0e6756 and what I read there pretty much matches what a DAO should do.

So my question is: what is the difference between a Home Object and a DAO? Is there any at all?

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top