Ok, thank you Tim. That's what I "feared" but I wanted to make sure I was not missing some feature here.
Since I don't need to resolve all possible super-types, but only the "Collection" one, I ended up creating an additional method which automatically binds the specialized binding and the one for Collection. Guillaume Le jeudi 6 juin 2013 06:35:25 UTC+2, Tim Boudreau a écrit : > > The bottom line is you have to explicitly bind things. You could write > something that iterates all the interfaces implemented by something and > binds them all - but it's a recipe non-obvious problems when it blows up > because two things resolve to the same type. I tried having something > called "bindPolymorphic()" for similar reasons some years ago, and it ended > up being more trouble than it was worth. > > -Tim > > -- You received this message because you are subscribed to the Google Groups "google-guice" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-guice?hl=en. For more options, visit https://groups.google.com/groups/opt_out.
