title: How to get all instances of a type by name from unity container?
body: <p>I have a container with some registered instances like:</p>
  
  <pre><code>container.RegisterInstance(typeof(Interface1), "Mapping1", new Class1("1"))
           .RegisterInstance(typeof(Interface1), "Mapping1", new Class1("2"))
           .RegisterInstance(typeof(Interface1), "Mapping2", new Class1("3"))
           .RegisterInstance(typeof(Interface1), "Mapping2", new Class1("4"));
  </code></pre>
  
  <p>So how can I get all instances of type <code>Interface1</code> named, for example, "Mapping1"?
  Calling code will be something like this: </p>
  
  <pre><code>var instances = container.ResolveAll&lt;Interface1&gt;("Mapping1");
  </code></pre>
  
  <p>Thank you for answering.</p>