Multiple InjectionConstructors

Topics: Prism v4 - WPF 4
Jun 26, 2013 at 7:25 PM
I sometimes run into a situation which requires me to write several InjectionConstructors that are essentially the same one (i.e. new InjectionConstructor(sameParam);)

Is it possible to declare one (i.e. var injectionContractor = new new InjectionConstructor(sameParam);

and then write code like this
_container.Resolve<IClass1, Class1>(injectionConstructor);
_container.Resolve<IClass2, Class2>(injectionConstructor);

Thanks in advance for your help.
Developer
Jun 26, 2013 at 8:09 PM
Hi,

As this topic is more related to Unity than to Prism I believe you could find better support regarding this in the Unity forums:

Regards,

Damian Cherubini
http://blogs.southworks.net/dcherubini
Jun 26, 2013 at 8:14 PM
Damian,

Thank you for the advice. I have done as you suggested. I was using Unity with Prism in a project. It is the first time that I have used either, and I think I just lost track of the distinction.

Thanks again.