With Castle.Windsor
I was able to define an implementation of a service via XML configuration and pass this implementation as a parameter to other services:
<components>
<component id="service1" service="MyAssembly.IService, MyAssembly" type="MyAssembly.Service1, MyAssembly"/>
<component id="consumer" type="MyAssembly.Consumer, MyAssembly">
<parameters>
<serviceInstatnce>${service1}</serviceInstatnce>
</parameters>
</component>
</components>
Is there a way to do the same thing with Autofac
XML configuration? I wasn't able to find anything reagarding this in their documentation or tutorials.