class RelatonIho::Processor

Attributes

idtype[R]

Public Class Methods

new() click to toggle source
# File lib/relaton_iho/processor.rb, line 7
def initialize
  @short = :relaton_iho
  @prefix = "IHO"
  @defaultprefix = %r{^IHO\s}
  @idtype = "IHO"
end

Public Instance Methods

from_xml(xml) click to toggle source

@param xml [String] @return [RelatonIho::IhoBibliographicItem]

# File lib/relaton_iho/processor.rb, line 24
def from_xml(xml)
  ::RelatonIho::XMLParser.from_xml xml
end
get(code, date, opts) click to toggle source

@param code [String] @param date [String, NilClass] year @param opts [Hash] @return [RelatonIho::IhoBibliographicItem]

# File lib/relaton_iho/processor.rb, line 18
def get(code, date, opts)
  ::RelatonIho::IhoBibliography.get(code, date, opts)
end
grammar_hash() click to toggle source

Returns hash of XML grammar @return [String]

# File lib/relaton_iho/processor.rb, line 36
def grammar_hash
  @grammar_hash ||= ::RelatonIho.grammar_hash
end
hash_to_bib(hash) click to toggle source

@param hash [Hash] @return [RelatonIho::IhoBibliographicItem]

# File lib/relaton_iho/processor.rb, line 30
def hash_to_bib(hash)
  ::RelatonIho::IhoBibliographicItem.new hash
end