class Fieldhand::ListMetadataFormatsParser
A parser for ListMetadataFormats responses.
See www.openarchives.org/OAI/openarchivesprotocol.html#ListMetadataFormats
Attributes
response_parser[R]
Public Class Methods
new(response_parser)
click to toggle source
Return a parser for the given response parser.
# File lib/fieldhand/list_metadata_formats_parser.rb, line 13 def initialize(response_parser) @response_parser = response_parser end
Public Instance Methods
items()
click to toggle source
Return an array of `MetadataFormat`s found in the response.
# File lib/fieldhand/list_metadata_formats_parser.rb, line 18 def items response_parser. root. locate('ListMetadataFormats/metadataFormat'). map { |item| MetadataFormat.new(item, response_parser.response_date) } end