class Fieldhand::ListIdentifiersParser

A parser for ListIdentifiers responses.

See www.openarchives.org/OAI/openarchivesprotocol.html#ListIdentifiers

Attributes

response_parser[R]

Public Class Methods

new(response_parser) click to toggle source

Return a new parser for the given response parser.

# File lib/fieldhand/list_identifiers_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 `Header`s found in the response.

# File lib/fieldhand/list_identifiers_parser.rb, line 18
def items
  response_parser.
    root.
    locate('ListIdentifiers/header').
    map { |item| Header.new(item, response_parser.response_date) }
end