• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

What to choose, daoFactory or a SpringUtil from ZK?

 
Ranch Hand
Posts: 201
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
Posts: 201
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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?
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

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)
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic