On Fri, Jan 9, 2009 at 7:08 PM, Nathan Maves <[email protected]> wrote:
> I use guice to inject a SqlMapClient object into my dao implementations.
>  then I just call the methods on that object as needed.

I'd like to see an example of this.

How are using your these DAOs from other classes? I'm really curious about this.

One of the limitations of using IoC, at least with Spring, is that you
seem to be stuck with the whole ball of wax on the implementation end
unless you want to provide ugly hooks in your enpoints that do
something like applicationContext.getBean("something",
Something.class).

for example if you have:

SomeClass {
   FooBar foobar; //IOC injected!
  method() {
     foobar.something();
  }

you can't just use someClass.method unless where you are calling it
from is under your IoC framework as well of which SomeClass is defined
somewhere (in spring under a config file.)  So I'm curious how you are
saying guice can handle this, if it even can.



-- 
Rick

Reply via email to