title: How do I run XPath queries in QT?
body: <p>How do I run an XPath query in QT?</p>
  
  <p>I need to sort out certain tags with specific values in a certain attribute. The QXmlQuery documentation is anything but legible.</p>
  
  <p>The schema I'm parsing is the Rhythmbox DB format:</p>
  
  <pre>
  <code>
  &lt;rhythmdb version="1.6">
    &lt;entry type="ignore">
      &lt;title>&lt;/title>
      &lt;genre>&lt;/genre>
      &lt;artist>&lt;/artist>
      &lt;album>&lt;/album>
      &lt;location>file:///mnt/disk/music/Cover.jpg&lt;/location>
      &lt;mountpoint>file:///mnt/disk&lt;/mountpoint>
      &lt;mtime>1222396828&lt;/mtime>
      &lt;date>0&lt;/date>
      &lt;mimetype>application/octet-stream&lt;/mimetype>
      &lt;mb-trackid>&lt;/mb-trackid>
      &lt;mb-artistid>&lt;/mb-artistid>
      &lt;mb-albumid>&lt;/mb-albumid>
      &lt;mb-albumartistid>&lt;/mb-albumartistid>
      &lt;mb-artistsortname>&lt;/mb-artistsortname>
    &lt;/entry>
    &lt;entry type="song">
      &lt;title>Bar&lt;/title>
      &lt;genre>Foobared Music&lt;/genre>
      &lt;artist>Foo&lt;/artist>
      &lt;album>The Great big Bar&lt;/album>
      &lt;track-number>1&lt;/track-number>
      &lt;disc-number>1&lt;/disc-number>
      &lt;duration>208&lt;/duration>
      &lt;file-size>8694159&lt;/file-size>
      &lt;location>file:///media/disk/music/01-Foo_-_Bar.ogg
      &lt;mountpoint>file:///media/disk
      &lt;mtime>1216995840&lt;/mtime>
      &lt;first-seen>1250478814&lt;/first-seen>
      &lt;last-seen>1250478814&lt;/last-seen>
      &lt;bitrate>301&lt;/bitrate>
      &lt;date>732677&lt;/date>
      &lt;mimetype>application/x-id3&lt;/mimetype>
      &lt;mb-trackid>&lt;/mb-trackid>
      &lt;mb-artistid>&lt;/mb-artistid>
      &lt;mb-albumid>&lt;/mb-albumid>
      &lt;mb-albumartistid>&lt;/mb-albumartistid>
      &lt;mb-artistsortname>&lt;/mb-artistsortname>
    &lt;/entry>
  &lt;/rhythmdb>
  </code>
  </pre>
  
  <p>This is your basic XML Schema which has a collection of structured entries. My intention was to filter out the entries with the type 'ignore'.</p>