Thank you for the advice: by using only Guice to perform this stuff, I
forgot I could do it manually...
However, would the change you speak about allow the kind of stuff below?
interface Game { }
interface GameFactory { Game create (String s); }
class GameImpl implements Game { GameImpl(@Assisted Integer i) { } } // Not
the same as the create method signature
with the provider
@Provides
public Integer provideInteger (String sInt) { return Integer.parseInt(sInt);
}
Because I would really love to see this implemented.
Regards,
Olivier
2009/9/2 [email protected] <[email protected]>
>
> On Sep 2, 7:50 am, Olivier <[email protected]> wrote:
> > I just encountered an error (see below) that annoys me: I receive an
> > error in child injector, but I don't have any child injector. Since
> > the project is recenlty rewritten from scratch, I have only three
> > modules (plus one "installing" these). The Game class is bound through
> > an assisted injection and only once. I checked several times.
>
> Both assisted inject and private modules use child injectors behind-
> the-scenes. We're thinking about changing assisted inject's internals
> to avoid this problem, so you can get Game from either an injection or
> from an assisted inject-powered factory.
>
> In the interim, you might have to do the assisted injection manually -
> ie. implement the factory by hand rather than with a FactoryProvider.
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"google-guice" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-guice?hl=en
-~----------~----~----~----~------~----~------~--~---