Sha256: 1449514862d28c5fad3ce2bf57c8ccf78b5d20f101262efc2e884c0eb03819f6
Contents?: true
Size: 871 Bytes
Versions: 8
Compression:
Stored size: 871 Bytes
Contents
module RelatonIetf class IetfBibliographicItem < RelatonBib::BibliographicItem DOCTYPES = %w[rfc internet-draft].freeze # @return [String, NilClass] attr_reader :doctype # @return [Array<String>] attr_reader :keyword # @param doctype [String] # @param keyword [Array<String>] def initialize(**args) if args[:doctype] && !DOCTYPES.include?(args[:doctype]) warn "[relaton-ietf] WARNING: invalid doctype #{args[:doctype]}" end super end # @param opts [Hash] # @option opts [Nokogiri::XML::Builder] :builder XML builder # @option opts [Boolean] :bibdata # @option opts [Symbol, NilClass] :date_format (:short), :full # @option opts [String, Symbol] :lang language # @return [String] XML def to_xml(**opts) opts[:date_format] ||= :short super **opts end end end
Version data entries
8 entries across 8 versions & 1 rubygems