• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

DAO for joined entities

 
joe priv
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is the best pratice for this senario. I have an Business Object that does not map to a single Hibernate mapping. It is a logical entity comprised of differnt entites (*.hbm.xml). Should there be a DAO for something like this, if not what would the access pattern be?

Thanks
 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would say that providing simplicity to the end users is a major concern when providing APIs to developers. From this standpoint, I believe that delivering a single DAO object would be an appropriate approach.

I'm guessing that is your hunch, as you suggested it, but you must have some reservations about it. What are the drawbacks you can forsee?

-Cameron McKenzie
 
joe priv
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Cameron.

I wasn't sure if this was the best way to handle this kind of scenario. I guess if it works then I should just accept it. But I always like to verify my solution with best practices to make sure there isn't a hidden issue with my stuff.

Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic