title: XML to IEnumerable<T>
body: <p>Is there a way to Take a given XML file and convert (preferably using C# Generics) it into a Concrete Ienumerable list of T  where T is my concrete class</p>
  
  <p>So for example I may have an XML file like</p>
  
  <pre><code>&lt;fruits&gt;
      &lt;fruit&gt;
          &lt;id&gt;1&lt;/id&gt;
          &lt;name&gt;apple&lt;/name&gt;
      &lt;/fruit&gt;
      &lt;fruit&gt;
          &lt;id&gt;2&lt;/id&gt;
          &lt;name&gt;orange&lt;/name&gt;
      &lt;/fruit&gt;
  &lt;/fruits&gt;
  </code></pre>
  
  <p>and I would like to see a list of a Fruit Objects</p>
  
  <p>where it has properties like</p>
  
  <pre><code>public class Fruit : IFruit
  {
      public string name;
      public int id;
  }
  </code></pre>
  
  <p>I assume I'd need some kind of Mapping if I was to use generics, as I would like this to work for ideally the IFruit interface (not sure if thats possible)</p>
  
  <p>Thanks in advance</p>