I want to allow third-party modules to be able to bind some custom 
ISomeInterface elements (well,* classes* of ISomeInterface in fact : 
"Class<? extends ISomeInterface >"). I use Multibinder for that and it 
works great.

But I would like to be able, at the very end of my main module's 
configure() method, to process the elements that have been binded in the 
Multibinder to add further bindings for those. More specifically, I'd like 
to be able to automatically bind an AssistedFactory for each of the 
elements that have been multibinded.

Is there a way to retrieve the currently binded elements of a Multibinder, 
without the injector been created yet (while still being in "configure()")?

Something like : 

-------------------
Multibinder<Class<? extends ISomeInterface>> myMultibinder = 
Multibinder.newSetBinder(binder(), new TypeLiteral<Class<? extends 
ISomeInterface >>(){});
Set<Class<? extends ISomeInterface>> currentBindings = 
myMultibinder.getBindings();
-------------------

Then I would use the "currentBindings" to bind assisted factories.

Any idea?


-- 
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.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to