Open creynders opened 11 years ago
Or come to think of it, neatest would probably be:
injector.map(IFoo).toSingleton(Foo);
injector.map(IBar).toProviderOf(IFoo);
Or:
injector.map(IFoo).and(IBar).toSingleton(Foo);
Or:
injector.mapAll(IFoo, IBar).toSingleton(Foo);
@peterjoel yeah, I like the first one, but that might be a bit hard to implement.
See http://knowledge.robotlegs.org/discussions/robotlegs-2/2124-mapping-multiple-interfaces-to-same-singleton-instance
and #136