title: how to return an IList with members of an arbitrary type
body: <p>I'm not sure this is even possible, but here goes: I have a class <code>Zoo</code> which holds a dictionary of Animal Type -> List of Animals. e.g.</p>
  
  <pre><code>Cat Type -&gt; {Cat1, Cat2}
  Zebra Type -&gt; {Zebra1, Zebra2}
  </code></pre>
  
  <p><code>Cat</code> and <code>Zebra</code> are subclasses of <code>Animal</code>. Now <code>Zoo</code> has a method <code>IList&lt;Animal&gt;</code> <code>GetAnimalsOfType(Type type)</code>.</p>
  
  <p>I'd like the return value to be of the type of the animal requested, so instead of getting an <code>IList&lt;Animal&gt;</code> I'd get an <code>IList&lt;Cat&gt;</code> or an <code>IList&lt;Zebra&gt;</code> depending on the type of animal I passed in the type parameter.</p>
  
  <p>Is this possible? If so how?</p>