Class: Relaton::Bib::Converter::BibXml::FromRfcxml

Inherits:
Object
  • Object
show all
Includes:
NamespaceHelper
Defined in:
lib/relaton/bib/converter/bibxml/from_rfcxml.rb

Overview

rubocop:disable Metrics/ClassLength

Instance Method Summary collapse

Methods included from NamespaceHelper

included

Constructor Details

#initialize(reference) ⇒ FromRfcxml

Returns a new instance of FromRfcxml.



8
9
10
# File 'lib/relaton/bib/converter/bibxml/from_rfcxml.rb', line 8

def initialize(reference)
  @reference = reference
end

Instance Method Details

#transformObject

rubocop:disable Metrics/MethodLength



12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# File 'lib/relaton/bib/converter/bibxml/from_rfcxml.rb', line 12

def transform # rubocop:disable Metrics/MethodLength
  namespace::ItemData.new(
    docnumber: @reference.anchor,
    type: "standard",
    docidentifier: docidentifiers,
    status: status,
    language: ["en"],
    script: ["Latn"],
    source: source,
    title: title,
    formattedref: formattedref,
    abstract: abstract,
    contributor: contributor + workgroup_contributors,
    date: date,
    series: series,
    keyword: keyword,
    ext: ext,
  )
end