Sha256: 77667a3e4cf42e9913ae0091c4db8db5adf891b2c84e1a84de9f73c1c6a3bc5f
Contents?: true
Size: 967 Bytes
Versions: 6
Compression:
Stored size: 967 Bytes
Contents
require "relaton/processor" require "relaton_ietf/xml_parser" module RelatonIetf class Processor < Relaton::Processor def initialize @short = :relaton_ietf @prefix = "IETF" @defaultprefix = /^RFC / @idtype = "IETF" end # @param code [String] # @param date [String, NilClass] year # @param opts [Hash] # @return [RelatonIetf::IetfBibliographicItem] def get(code, date, opts) ::RelatonIetf::IetfBibliography.get(code, date, opts) end # @param xml [String] # @return [RelatonIetf::IetfBibliographicItem] def from_xml(xml) ::RelatonIetf::XMLParser.from_xml xml end # @param hash [Hash] # @return [RelatonIetf::IetfBibliographicItem] def hash_to_bib(hash) ::RelatonIetf::IetfBibliographicItem.from_hash hash end # Returns hash of XML grammar # @return [String] def grammar_hash @grammar_hash ||= ::RelatonIetf.grammar_hash end end end
Version data entries
6 entries across 6 versions & 1 rubygems