title: Ruby / Nokogiri / Xpath shallow search
body: <p>The code applied to the (simplified) xml below gets me the node with myanim1.swf, as expected.  I actually want the node with myanim3.swf.  I would like to say "get the first node with a property tag with attribute  name=animationUrl, but don't go deeper than one child". I currently have a work-around, but I'm looking for a more elegant solution.   </p>
  
  <p>This is ruby, and the object is a Nokogiri object. I believe this is XPath searching, but I'm a little unclear as to whether it is Nokogiri's flavor of XPath.  Anyway, help appreciated, thanks.</p>
  
  <p>XML:</p>
  
  <pre><code>&lt;blah&gt;
      &lt;property name="overlays"&gt;
          &lt;array&gt;
              &lt;object type="myType"&gt;
                  &lt;property name="animationUrl" value="myanim1.swf"/&gt;
              &lt;/object&gt;
              &lt;object type="myType"&gt;
                  &lt;property name="animationUrl" value="myanim2.swf"/&gt;
              &lt;/object&gt;
          &lt;/array&gt;
      &lt;/property&gt;
      &lt;property name="animationUrl" value="myanim3"/&gt;
      &lt;/property&gt;
  &lt;/blah&gt;
  </code></pre>
  
  <p>CODE:</p>
  
  <pre><code>myNode = thisNode.search("property[name=animationUrl]").first.andand["value"]
  </code></pre>