I used to use Castle as an IoC but I had a problem using Nhibernate/Castle(IoC) in the same project so i moved to Ninject. Now to get to the question, I have this class:
class CustomModule : NinjectModule
{
public override void Load()
{
Bind<Interfaces.ICafe>().To <Concrete.Tea>();
}
}
Concrete
is a separate project and Interfaces.ICafe
is a different project. With Castle I used to give a developer the interfaces DLL and ask him to implement a new concrete implementing that interface and then configure that with the app.config, so no matter what class name he implements it still works because he has to write that in the app.config, so if he made it like Concrete.Coffee
it would still work.
But with Ninject he has to make a concrete with the same class name "Tea" in order to make it work otherwise it wouldn't work because it is hard coded.
I'm new to Ninject and i know there is probably something I'm missing ?