title: Is there a way to query on Type using System.Linq.Dynamic
body: <p>I have class "A" which has a collection of class "B". "D" is a subclass of "B" with the property "DMatter" (not inherited from "B") </p>
  
  <p>I can select "A"s that have a "D" with certain content like this with regular Linq:</p>
  
  <pre><code> var result = 
      Aset.Where(a =&gt; a.Bs.OfType&lt;D&gt;().Any(d =&gt; d.DMatter.Contains("ii"))); //works!
  </code></pre>
  
  <p>I can dynamically on B's properties like so:</p>
  
  <pre><code> var result = Aset.Where("Bs.Any(BStuff.Contains(\"bb\"))");//works!
  </code></pre>
  
  <p>But I can't find a way to something like this:</p>
  
  <pre><code>result = Aset.Where("Bs.OfType&lt;D&gt;().Any(DMatter.Contains(\"ii\"))");//Explodes!
  </code></pre>
  
  <p>Any solutions?</p>