relaton-ieee 1.19.2 → 1.20.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/relaton_ieee/ieee_bibliographic_item.rb +19 -1
- data/lib/relaton_ieee/renderer/bibxml.rb +17 -0
- data/lib/relaton_ieee/version.rb +1 -1
- data/relaton_ieee.gemspec +1 -1
- metadata +8 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 48e29befbf896c3fc598040f4b93e1c1c601ca652602db77a41300a39243213d
|
4
|
+
data.tar.gz: 0d5060435ad8cf5d2b1c24a64215632ea707b0da8c8f504095748f8ca56818ac
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 717cf18a8d236ce50ec0b9fc71404b8cd6ac790f6313035a6c2bb1cc03c50b9130fb4c98b8ec28b7659597d1fc074408553f30bd2ccc77d85086e92ef7528754
|
7
|
+
data.tar.gz: 67493d4a175515bdc8aa807888fb1ec8b0b55f09b816c23a7a0137157a0de4948f413a76dc719aca3fb00aff4f0706544a682d56aa8c52a2e5bccafe1a474f9d
|
@@ -1,3 +1,5 @@
|
|
1
|
+
require_relative "renderer/bibxml"
|
2
|
+
|
1
3
|
module RelatonIeee
|
2
4
|
class IeeeBibliographicItem < RelatonBib::BibliographicItem
|
3
5
|
SUBTYPES = %w[amendment corrigendum erratum].freeze
|
@@ -87,7 +89,7 @@ module RelatonIeee
|
|
87
89
|
#
|
88
90
|
def to_hash(embedded: false) # rubocop:disable Metrics/AbcSize
|
89
91
|
hash = super
|
90
|
-
hash["trialuse"] = trialuse unless trialuse.nil?
|
92
|
+
hash["ext"]["trialuse"] = trialuse unless trialuse.nil?
|
91
93
|
hash["ext"]["standard_status"] = standard_status unless standard_status.nil?
|
92
94
|
hash["ext"]["standard_modified"] = standard_modified unless standard_modified.nil?
|
93
95
|
hash["ext"]["pubstatus"] = pubstatus unless pubstatus.nil?
|
@@ -95,6 +97,10 @@ module RelatonIeee
|
|
95
97
|
hash
|
96
98
|
end
|
97
99
|
|
100
|
+
def has_ext?
|
101
|
+
super || !trialuse.nil? || standard_status || standard_modified || pubstatus || holdstatus
|
102
|
+
end
|
103
|
+
|
98
104
|
# @param prefix [String]
|
99
105
|
# @return [String]
|
100
106
|
def to_asciibib(prefix = "")
|
@@ -102,5 +108,17 @@ module RelatonIeee
|
|
102
108
|
out += "#{prefix}.trialuse:: #{trialuse}\n" unless trialuse.nil?
|
103
109
|
out
|
104
110
|
end
|
111
|
+
|
112
|
+
#
|
113
|
+
# Render BibXML (RFC)
|
114
|
+
#
|
115
|
+
# @param [Nokogiri::XML::Builder, nil] builder
|
116
|
+
# @param [Boolean] include_keywords (false)
|
117
|
+
#
|
118
|
+
# @return [String, Nokogiri::XML::Builder::NodeBuilder] XML
|
119
|
+
#
|
120
|
+
def to_bibxml(builder = nil, include_keywords: false)
|
121
|
+
Renderer::BibXML.new(self).render builder: builder, include_keywords: include_keywords
|
122
|
+
end
|
105
123
|
end
|
106
124
|
end
|
@@ -0,0 +1,17 @@
|
|
1
|
+
module RelatonIeee
|
2
|
+
module Renderer
|
3
|
+
class BibXML < RelatonBib::Renderer::BibXML
|
4
|
+
|
5
|
+
#
|
6
|
+
# Render workgroup
|
7
|
+
#
|
8
|
+
# @param [Nokogiri::XML::Builder] builder xml builder
|
9
|
+
#
|
10
|
+
def render_workgroup(builder)
|
11
|
+
@bib.editorialgroup&.committee&.each do |committee|
|
12
|
+
builder.workgroup committee
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
data/lib/relaton_ieee/version.rb
CHANGED
data/relaton_ieee.gemspec
CHANGED
@@ -34,7 +34,7 @@ Gem::Specification.new do |spec|
|
|
34
34
|
spec.add_dependency "faraday", "~> 2.7.0"
|
35
35
|
spec.add_dependency "ieee-idams", "~> 0.2.10"
|
36
36
|
spec.add_dependency "mini_portile2", "~> 2.8.0"
|
37
|
-
spec.add_dependency "relaton-bib", "~> 1.
|
37
|
+
spec.add_dependency "relaton-bib", "~> 1.20.0"
|
38
38
|
spec.add_dependency "relaton-index", "~> 0.2.0"
|
39
39
|
spec.add_dependency "rubyzip", "~> 2.3.0"
|
40
40
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-ieee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.20.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-12-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -58,14 +58,14 @@ dependencies:
|
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: 1.
|
61
|
+
version: 1.20.0
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: 1.
|
68
|
+
version: 1.20.0
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: relaton-index
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -133,6 +133,7 @@ files:
|
|
133
133
|
- lib/relaton_ieee/processor.rb
|
134
134
|
- lib/relaton_ieee/pub_id.rb
|
135
135
|
- lib/relaton_ieee/rawbib_id_parser.rb
|
136
|
+
- lib/relaton_ieee/renderer/bibxml.rb
|
136
137
|
- lib/relaton_ieee/util.rb
|
137
138
|
- lib/relaton_ieee/version.rb
|
138
139
|
- lib/relaton_ieee/xml_parser.rb
|
@@ -143,7 +144,7 @@ licenses:
|
|
143
144
|
metadata:
|
144
145
|
homepage_uri: https://github.com/relaton/relaton-ieee
|
145
146
|
source_code_uri: https://github.com/relaton/relaton-ieee
|
146
|
-
post_install_message:
|
147
|
+
post_install_message:
|
147
148
|
rdoc_options: []
|
148
149
|
require_paths:
|
149
150
|
- lib
|
@@ -159,7 +160,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
159
160
|
version: '0'
|
160
161
|
requirements: []
|
161
162
|
rubygems_version: 3.3.27
|
162
|
-
signing_key:
|
163
|
+
signing_key:
|
163
164
|
specification_version: 4
|
164
165
|
summary: 'RelatonIeee: retrieve IEEE Standards for bibliographic use using the IeeeBibliographicItem
|
165
166
|
model'
|