I guess http://code.google.com/p/google-guice/wiki/Multibindings is what im 
looking for.

it is not annotation based and I have to configure plugins by hand but 
maybe I can leave with it for now.


On Friday, December 7, 2012 10:58:24 PM UTC+1, paweł kamiński wrote:
>
>  
> <http://stackoverflow.com/questions/13670060/guice-return-set-of-instances-with-custom-annotation#>
>  
>   
> I have very simple scenario where class A registers instances for types.
>
> A.register(T1.class, new H1());
> A.register(T2.class, new H2());
>
> this is fairly simple configuration when done by hand but guice injection 
> doesn't work when I create instances outside the guice framework. 
>
> I try to figure out how to create and configure A with all instance with 
> custom annotation using guice. is guice even prepared for that?
>
> I know that in java it is possible to use javax.enterprise.inject.Instance 
> to get all instances of type (and optionally annotated with custom 
> annotation) but I dont want to use this if possible.
>
> thanks for any help
>

-- 
You received this message because you are subscribed to the Google Groups 
"google-guice" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-guice/-/IprRX92TdgIJ.
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.

Reply via email to