Module: MusicBrainz::Bindings::Track
Instance Method Summary collapse
Instance Method Details
#parse(xml) ⇒ Object
4 5 6 7 8 9 10 11 |
# File 'lib/musicbrainz/bindings/track.rb', line 4 def parse(xml) { position: (xml.xpath('./position').text rescue nil), recording_id: (xml.xpath('./recording').attribute('id').value rescue nil), title: (xml.xpath('./recording/title').text rescue nil), length: (xml.xpath('./recording/length').text rescue nil) } end |