I have lots of classes that take an IMyService as a constructor argument.
e.g.
ClassA(IMyservice myservice)
// this should take a Concrete1 for IMyService
ClassB(IMyservice myservice)
// this should take a Concrete2 for IMyService
How do I do my registration so that ClassB gets a Concrete2 and ClassA gets a Concrete1?
Plus, is there a way to make one the default and only specify the instances that deviate from the default? (As the majority will take a Concrete1 and only a small number will take a Concrete2.)
I am using the fluent interface, NOT the XML configuration.
Use Service Overrides: