title: Ninject factory method with input parameter to determine which implementation to return
body: <p>I am trying to find a way to have a factory class / method that would take in an object or some kind of identifier (string or type) then based off the input parameter determine which implementation of the interface to create and return. </p>
  
  <p>how do I setup my factory method and register the dependency for the interface? following is what I have roughly.</p>
  
  <pre><code>public class ISampleFactory
  {
     public ISample GetSample(Type type)
     {
        // do something here to return an implementation of ISample
     }
  }
  
  
  public class SampleA : ISample
  {
     public void DoSomething();
  }
  
  public class SampleB : ISample
  {
     public void DoSomething();
  }
  
  public interface ISample
  {
     void DoSomethin();
  }
  </code></pre>