Is it possible to wire events to methods with Autofac instead of whole object via interfaces/classes (through constructor and property injection). I want to bind at function level instead of type level. Programmatically I expect the following job to be done (in C#):
someType.Output += someOtherType.Input;
For example Spring.net does support the following construct to achieve that:
<object id="SomeType" type="Whatever.SomeType, Whatever" />
<object id="SomeOtherType" type="Whatever.SomeOtherType, Whatever">
<listener event="Output" method="Input">
<ref object="SomeType" />
</listener>
</object>
Is Autofac able to do that and how? Is it possible to use xml config for such a task?
someType
andsomeOtherType
take a dependency on which acts as the go between for the two classes? – Centipoise