| Author |
What to choose, daoFactory or a SpringUtil from ZK?
|
Girish Vasmatkar
Ranch Hand
Joined: Apr 24, 2008
Posts: 199
|
|
Hi Guys,
I'm using Spting along with ZK for Presentation layer. I have got a lot of DAOs, 44 to be precise to deal with.
My question is whether to use the daofactory patter as more or less all the Spring developers use or to go with a utility class called SpringUtil provided by ZK. ZK integrates with Spring and provides this class.
You can get any bean from this class in this form
So, basically it is a design issue that I must deal with.
Thanks!!!
|
 |
Girish Vasmatkar
Ranch Hand
Joined: Apr 24, 2008
Posts: 199
|
|
Okay, I was wondering what is left other than daoFactory pattern if you were not using ZK ?
Why not just inject the dao's themselves(which are gonna be used) in the classes rather than first injecting all the daos in the daofactory and injecting daofactory in the required class?
|
 |
Amila Domingo
Greenhorn
Joined: Nov 08, 2009
Posts: 1
|
|
Girish Vasmatkar wrote:Okay, I was wondering what is left other than daoFactory pattern if you were not using ZK ?
Why not just inject the dao's themselves(which are gonna be used) in the classes rather than first injecting all the daos in the daofactory and injecting daofactory in the required class?
Hi All,
i have a similar problem (whether to inject daos to required classes or use a dao factory). i have two questions,
1. isn't injecting daos add unnecessary code (setters)
2. what is the main advantage we get from using dao factory pattern with spring ioc (other than not having reference variables for daos and setters)
|
 |
 |
|
|
subject: What to choose, daoFactory or a SpringUtil from ZK?
|
|
|