Sha256: b2a4dd66e711696cdae1fc5ff97c61a62205f75274bf445e68a6fbe2df52053e

Contents?: true

Size: 545 Bytes

Versions: 39

Compression:

Stored size: 545 Bytes

Contents

module Relaton
  module Render
    module Iec
      class Parse < ::Relaton::Render::Parse
        def simple_or_host_xml2hash(doc, host)
          ret = super
          ret.merge(home_standard: home_standard(doc, ret[:publisher_raw]))
        end

        def home_standard(_doc, pubs)
          pubs&.any? do |r|
            ["International Organization for Standardization", "ISO",
             "International Electrotechnical Commission", "IEC"]
              .include?(r[:nonpersonal])
          end
        end
      end
    end
  end
end

Version data entries

39 entries across 39 versions & 1 rubygems

Version Path
metanorma-iec-2.5.7 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.6 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.5 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.4 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.3 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.2 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.1 lib/relaton/render-iec/parse.rb
metanorma-iec-2.5.0 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.13 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.12 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.11 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.9 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.8 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.7 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.6 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.5 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.4 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.3 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.2 lib/relaton/render-iec/parse.rb
metanorma-iec-2.4.1 lib/relaton/render-iec/parse.rb