Hello,
 
Is it good or bad design to make my beans extends the DAO ?
 
I mean, an "animal" bean is not exactly a specialized animal DAO, but I could call the save,
update and delete methos directly from the "zoo" Facade if I extend animalDAO from animal.
 
The difference would be in the bean, if I extend the DAO, I would not have to instantiate it in my init or pseudo constructor, and could call the DAO CRUD methods
easily from the bean body.
On the counterpart, it seems as I already mentioned, that the DAO methods would be exposed to the outside world, an this just don't feel right for me
(hmmmm ... maybe that's one of the reasons for a Transfer Object to exists).
 
Anyway, is there any good or bad argument against it ?
 
[]s

Marcantonio Silva
Diretor de Desenvolvimento de Produtos - Navita
[EMAIL PROTECTED]
www.navita.com.br
Tel: +55 11 3055.2004
Cel: +55 11 7732.4907 (novo)

 

Reply via email to