I want to inject a IDictionary
of {key, interface}
into a contructor, but I have no idea how to set it up in the program.cs
I can initiate the Interfaces and I can could initiate an IDictionary
but I have no idea how to combine them.
Any suggestions would be appriciated.
Additional Context:
So i need to inject my services like
I need to inject the services eg,
s.AddTransient<IFooService, AFooService>();
s.AddTransient<IFooService, BFooService>();
but in the contructor I want
public MyClass(IDictionary<string, IFooService> fooServices)