relaton-bib 0.3.6 → 0.3.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/relaton_bib/bibliographic_date.rb +2 -3
- data/lib/relaton_bib/bibliographic_item.rb +1 -1
- data/lib/relaton_bib/formatted_string.rb +2 -2
- data/lib/relaton_bib/hash_converter.rb +136 -91
- data/lib/relaton_bib/hit.rb +1 -1
- data/lib/relaton_bib/hit_collection.rb +1 -1
- data/lib/relaton_bib/typed_title_string.rb +10 -3
- data/lib/relaton_bib/version.rb +1 -1
- data/lib/relaton_bib/xml_parser.rb +15 -5
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ceddccd39bcf1423b79aa28256b8bdc0cd5d1920
|
4
|
+
data.tar.gz: 3f4fb8004a268ebe022e00e989a8f01427f2beb9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 59f0667f7628db03cb608f784ba64780796b20933d0531607c53ef51c65d5dd3252f493a8831994d706278de517ec0b6416ddcad7b9056f9f0c86c0e543392f1
|
7
|
+
data.tar.gz: c5df8ae589ab71e155ef6a51edde861350169528982d673fe450a084132aaa895f7ae4efe627f65ddf67ae41d1c1d5f9d2bd1670f394e01452d453eef98158f3
|
data/Gemfile.lock
CHANGED
@@ -6,8 +6,7 @@ module RelatonBib
|
|
6
6
|
# Bibliographic date.
|
7
7
|
class BibliographicDate
|
8
8
|
TYPES = %w[published accessed created implemented obsoleted confirmed
|
9
|
-
updated issued transmitted copied unchanged circulated
|
10
|
-
].freeze
|
9
|
+
updated issued transmitted copied unchanged circulated adapted].freeze
|
11
10
|
|
12
11
|
# @return [String]
|
13
12
|
attr_reader :type
|
@@ -28,7 +27,7 @@ module RelatonBib
|
|
28
27
|
def initialize(type:, on: nil, from: nil, to: nil)
|
29
28
|
raise ArgumentError, "expected :on or :from argument" unless on || from
|
30
29
|
|
31
|
-
raise ArgumentError, "invalid type: #{type}" unless TYPES.include? type
|
30
|
+
# raise ArgumentError, "invalid type: #{type}" unless TYPES.include? type
|
32
31
|
|
33
32
|
@type = type
|
34
33
|
@on = RelatonBib.parse_date on
|
@@ -169,7 +169,7 @@ module RelatonBib
|
|
169
169
|
# @option link [String] :content
|
170
170
|
def initialize(**args)
|
171
171
|
if args[:type] && !TYPES.include?(args[:type])
|
172
|
-
|
172
|
+
warn %{Document type "#{args[:type]}" is invalid.}
|
173
173
|
end
|
174
174
|
|
175
175
|
@title = (args[:title] || []).map do |t|
|
@@ -13,8 +13,8 @@ module RelatonBib
|
|
13
13
|
attr_reader :format
|
14
14
|
|
15
15
|
# @param content [String]
|
16
|
-
# @param language [String] language code Iso639
|
17
|
-
# @param script [String] script code Iso15924
|
16
|
+
# @param language [String, NilClass] language code Iso639
|
17
|
+
# @param script [String, NilClass] script code Iso15924
|
18
18
|
# @param format [String] the content type
|
19
19
|
def initialize(content:, language: nil, script: nil, format: "text/plain")
|
20
20
|
# if format && !FORMATS.include?(format)
|
@@ -35,6 +35,7 @@ module RelatonBib
|
|
35
35
|
|
36
36
|
def extent_hash_to_bib(ret)
|
37
37
|
return unless ret[:extent]
|
38
|
+
|
38
39
|
ret[:extent] = array(ret[:extent])
|
39
40
|
ret[:extent]&.each_with_index do |e, i|
|
40
41
|
ret[:extent][i] = BibItemLocality.new(e[:type], e[:reference_from],
|
@@ -44,45 +45,57 @@ module RelatonBib
|
|
44
45
|
|
45
46
|
def title_hash_to_bib(ret)
|
46
47
|
return unless ret[:title]
|
48
|
+
|
47
49
|
ret[:title] = array(ret[:title])
|
48
50
|
ret[:title] = ret[:title].map do |t|
|
49
|
-
t.is_a?(Hash)
|
50
|
-
|
51
|
+
if t.is_a?(Hash) then t
|
52
|
+
else
|
53
|
+
{ content: t, language: "en", script: "Latn", format: "text/plain", type: "main" }
|
54
|
+
end
|
51
55
|
end
|
52
56
|
end
|
53
57
|
|
54
58
|
def language_hash_to_bib(ret)
|
55
59
|
return unless ret[:language]
|
60
|
+
|
56
61
|
ret[:language] = array(ret[:language])
|
57
62
|
end
|
58
63
|
|
59
64
|
def script_hash_to_bib(ret)
|
60
65
|
return unless ret[:script]
|
66
|
+
|
61
67
|
ret[:script] = array(ret[:script])
|
62
68
|
end
|
63
69
|
|
64
70
|
def abstract_hash_to_bib(ret)
|
65
71
|
return unless ret[:abstract]
|
66
|
-
|
72
|
+
|
73
|
+
ret[:abstract] = array(ret[:abstract]).map do |a|
|
74
|
+
a.is_a?(String) ? FormattedString.new(content: a) : a
|
75
|
+
end
|
67
76
|
end
|
68
77
|
|
69
78
|
def link_hash_to_bib(ret)
|
70
79
|
return unless ret[:link]
|
80
|
+
|
71
81
|
ret[:link] = array(ret[:link])
|
72
82
|
end
|
73
83
|
|
74
84
|
def place_hash_to_bib(ret)
|
75
85
|
return unless ret[:place]
|
86
|
+
|
76
87
|
ret[:place] = array(ret[:place])
|
77
88
|
end
|
78
89
|
|
79
90
|
def accesslocation_hash_to_bib(ret)
|
80
91
|
return unless ret[:accesslocation]
|
92
|
+
|
81
93
|
ret[:accesslocation] = array(ret[:accesslocation])
|
82
94
|
end
|
83
95
|
|
84
96
|
def dates_hash_to_bib(ret)
|
85
97
|
return unless ret[:date]
|
98
|
+
|
86
99
|
ret[:date] = array(ret[:date])
|
87
100
|
ret[:date].each_with_index do |d, i|
|
88
101
|
# value is synonym of on: it is reserved word in YAML
|
@@ -95,6 +108,7 @@ module RelatonBib
|
|
95
108
|
|
96
109
|
def docid_hash_to_bib(ret)
|
97
110
|
return unless ret[:docid]
|
111
|
+
|
98
112
|
ret[:docid] = array(ret[:docid])
|
99
113
|
ret[:docid]&.each_with_index do |id, i|
|
100
114
|
ret[:docid][i] = DocumentIdentifier.new(id: id[:id], type: id[:type])
|
@@ -103,32 +117,35 @@ module RelatonBib
|
|
103
117
|
|
104
118
|
def version_hash_to_bib(ret)
|
105
119
|
return unless ret[:version]
|
120
|
+
|
106
121
|
ret[:version][:draft] = array(ret[:version][:draft])
|
107
|
-
ret[:version]
|
108
|
-
|
122
|
+
ret[:version] && ret[:version] = BibliographicItem::Version.new(
|
123
|
+
ret[:version][:revision_date], ret[:version][:draft]
|
124
|
+
)
|
109
125
|
end
|
110
126
|
|
111
127
|
def biblionote_hash_to_bib(ret)
|
112
128
|
return unless ret[:biblionote]
|
129
|
+
|
113
130
|
ret[:biblionote] = array(ret[:biblionote])
|
114
131
|
(ret[:biblionote])&.each_with_index do |n, i|
|
115
|
-
ret[:biblionote][i] =
|
116
|
-
|
117
|
-
|
118
|
-
|
132
|
+
ret[:biblionote][i] = BiblioNote.new(
|
133
|
+
content: n[:content], type: n[:type], language: n[:language],
|
134
|
+
script: n[:script], format: n[:format]
|
135
|
+
)
|
119
136
|
end
|
120
137
|
end
|
121
138
|
|
122
139
|
def formattedref_hash_to_bib(ret)
|
123
|
-
ret[:formattedref]
|
124
|
-
formattedref(ret[:formattedref])
|
140
|
+
ret[:formattedref] && ret[:formattedref] = formattedref(ret[:formattedref])
|
125
141
|
end
|
126
142
|
|
127
143
|
def docstatus_hash_to_bib(ret)
|
128
|
-
ret[:docstatus]
|
129
|
-
|
130
|
-
|
131
|
-
|
144
|
+
ret[:docstatus] && ret[:docstatus] = DocumentStatus.new(
|
145
|
+
stage: ret[:docstatus][:stage],
|
146
|
+
substage: ret[:docstatus][:substage],
|
147
|
+
iteration: ret[:docstatus][:iteration],
|
148
|
+
)
|
132
149
|
end
|
133
150
|
|
134
151
|
def contributors_hash_to_bib(ret)
|
@@ -146,73 +163,83 @@ module RelatonBib
|
|
146
163
|
end
|
147
164
|
end
|
148
165
|
ret[:contributor][i][:role] = roles
|
149
|
-
ret[:contributor][i][:entity] = c[:person]
|
150
|
-
|
166
|
+
ret[:contributor][i][:entity] = if c[:person]
|
167
|
+
person_hash_to_bib(c[:person])
|
168
|
+
else
|
169
|
+
org_hash_to_bib(c[:organization])
|
170
|
+
end
|
151
171
|
ret[:contributor][i].delete(:person)
|
152
172
|
ret[:contributor][i].delete(:organization)
|
153
173
|
end
|
154
174
|
end
|
155
175
|
|
156
|
-
def org_hash_to_bib(
|
157
|
-
return nil if
|
158
|
-
|
176
|
+
def org_hash_to_bib(org)
|
177
|
+
return nil if org.nil?
|
178
|
+
|
179
|
+
org[:identifier] = array(org[:identifier])&.map do |a|
|
159
180
|
OrgIdentifier.new(a[:type], a[:id])
|
160
181
|
end
|
161
|
-
|
182
|
+
org
|
162
183
|
end
|
163
184
|
|
164
|
-
def person_hash_to_bib(
|
185
|
+
def person_hash_to_bib(person)
|
165
186
|
Person.new(
|
166
|
-
name: fullname_hash_to_bib(
|
167
|
-
affiliation: affiliation_hash_to_bib(
|
168
|
-
contact: contacts_hash_to_bib(
|
169
|
-
identifier: person_identifiers_hash_to_bib(
|
187
|
+
name: fullname_hash_to_bib(person),
|
188
|
+
affiliation: affiliation_hash_to_bib(person),
|
189
|
+
contact: contacts_hash_to_bib(person),
|
190
|
+
identifier: person_identifiers_hash_to_bib(person),
|
170
191
|
)
|
171
192
|
end
|
172
193
|
|
173
|
-
def fullname_hash_to_bib(
|
174
|
-
n =
|
194
|
+
def fullname_hash_to_bib(person)
|
195
|
+
n = person[:name]
|
175
196
|
FullName.new(
|
176
|
-
forename: array(n[:forename])&.map { |f| localname(f,
|
177
|
-
initial: array(n[:initial])&.map { |f| localname(f,
|
178
|
-
addition: array(n[:addition])&.map { |f| localname(f,
|
179
|
-
prefix: array(n[:prefix])&.map { |f| localname(f,
|
180
|
-
surname: localname(n[:surname],
|
181
|
-
completename: localname(n[:completename],
|
197
|
+
forename: array(n[:forename])&.map { |f| localname(f, person) },
|
198
|
+
initial: array(n[:initial])&.map { |f| localname(f, person) },
|
199
|
+
addition: array(n[:addition])&.map { |f| localname(f, person) },
|
200
|
+
prefix: array(n[:prefix])&.map { |f| localname(f, person) },
|
201
|
+
surname: localname(n[:surname], person),
|
202
|
+
completename: localname(n[:completename], person),
|
182
203
|
)
|
183
204
|
end
|
184
205
|
|
185
|
-
def person_identifiers_hash_to_bib(
|
186
|
-
array(
|
206
|
+
def person_identifiers_hash_to_bib(person)
|
207
|
+
array(person[:identifier])&.map do |a|
|
187
208
|
PersonIdentifier.new(a[:type], a[:id])
|
188
209
|
end
|
189
210
|
end
|
190
211
|
|
191
|
-
def affiliation_hash_to_bib(
|
192
|
-
return [] unless
|
193
|
-
|
212
|
+
def affiliation_hash_to_bib(person)
|
213
|
+
return [] unless person[:affiliation]
|
214
|
+
|
215
|
+
array(person[:affiliation]).map do |a|
|
194
216
|
a[:description] = array(a[:description])&.map do |d|
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
217
|
+
cnt = if d.is_a?(Hash)
|
218
|
+
{ content: d[:content], language: d[:language],
|
219
|
+
script: d[:script], format: d[:format] }
|
220
|
+
else { content: d }
|
221
|
+
end
|
222
|
+
FormattedString.new cnt
|
200
223
|
end
|
201
224
|
Affilation.new(
|
202
225
|
organization: Organization.new(org_hash_to_bib(a[:organization])),
|
203
|
-
description: a[:description]
|
226
|
+
description: a[:description],
|
204
227
|
)
|
205
228
|
end
|
206
229
|
end
|
207
230
|
|
208
|
-
def contacts_hash_to_bib(
|
209
|
-
return [] unless
|
210
|
-
|
211
|
-
|
231
|
+
def contacts_hash_to_bib(person)
|
232
|
+
return [] unless person[:contact]
|
233
|
+
|
234
|
+
array(person[:contact]).map do |a|
|
235
|
+
if a[:city] || a[:country]
|
212
236
|
RelatonBib::Address.new(
|
213
237
|
street: Array(a[:street]), city: a[:city], postcode: a[:postcode],
|
214
|
-
country: a[:country], state: a[:state]
|
215
|
-
|
238
|
+
country: a[:country], state: a[:state]
|
239
|
+
)
|
240
|
+
else
|
241
|
+
RelatonBib::Contact.new(type: a[:type], value: a[:value])
|
242
|
+
end
|
216
243
|
end
|
217
244
|
end
|
218
245
|
|
@@ -227,14 +254,14 @@ module RelatonBib
|
|
227
254
|
end
|
228
255
|
|
229
256
|
# @param ret [Hash]
|
230
|
-
# @param
|
231
|
-
# @param
|
232
|
-
def relation_bibitem_hash_to_bib(ret,
|
233
|
-
if
|
234
|
-
ret[:relation][
|
257
|
+
# @param rel [Hash] relation
|
258
|
+
# @param idx [Integr] index of relation
|
259
|
+
def relation_bibitem_hash_to_bib(ret, rel, idx)
|
260
|
+
if rel[:bibitem]
|
261
|
+
ret[:relation][idx][:bibitem] = bib_item(hash_to_bib(rel[:bibitem], true))
|
235
262
|
else
|
236
|
-
warn "bibitem missing: #{
|
237
|
-
ret[:relation][
|
263
|
+
warn "bibitem missing: #{rel}"
|
264
|
+
ret[:relation][idx][:bibitem] = nil
|
238
265
|
end
|
239
266
|
end
|
240
267
|
|
@@ -244,9 +271,9 @@ module RelatonBib
|
|
244
271
|
BibliographicItem.new(item)
|
245
272
|
end
|
246
273
|
|
247
|
-
def relation_biblocality_hash_to_bib(ret,
|
248
|
-
ret[:relation][
|
249
|
-
array(
|
274
|
+
def relation_biblocality_hash_to_bib(ret, rel, idx)
|
275
|
+
ret[:relation][idx][:bib_locality] =
|
276
|
+
array(rel[:bib_locality])&.map do |bl|
|
250
277
|
BibItemLocality.new(bl[:type], bl[:reference_from],
|
251
278
|
bl[:reference_to])
|
252
279
|
end
|
@@ -271,7 +298,7 @@ module RelatonBib
|
|
271
298
|
end
|
272
299
|
|
273
300
|
def medium_hash_to_bib(ret)
|
274
|
-
ret[:medium]
|
301
|
+
ret[:medium] = Medium.new(ret[:medium]) if ret[:medium]
|
275
302
|
end
|
276
303
|
|
277
304
|
def classification_hash_to_bib(ret)
|
@@ -279,52 +306,70 @@ module RelatonBib
|
|
279
306
|
# ret[:classification]&.each_with_index do |c, i|
|
280
307
|
# ret[:classification][i] = RelatonBib::Classification.new(c)
|
281
308
|
# end
|
282
|
-
ret[:classification]
|
309
|
+
if ret[:classification]
|
283
310
|
ret[:classification] = Classification.new(ret[:classification])
|
311
|
+
end
|
284
312
|
end
|
285
313
|
|
286
314
|
def validity_hash_to_bib(ret)
|
287
315
|
return unless ret[:validity]
|
288
|
-
|
289
|
-
ret[:validity][:
|
290
|
-
ret[:validity][:
|
316
|
+
|
317
|
+
ret[:validity][:begins] && b = Time.parse(ret[:validity][:begins])
|
318
|
+
ret[:validity][:ends] && e = Time.parse(ret[:validity][:ends])
|
319
|
+
ret[:validity][:revision] && r = Time.parse(ret[:validity][:revision])
|
291
320
|
ret[:validity] = Validity.new(begins: b, ends: e, revision: r)
|
292
321
|
end
|
293
322
|
|
323
|
+
# @param ogj [Hash, Array, String]
|
324
|
+
# @return [Hash, Array, String]
|
294
325
|
def symbolize(obj)
|
295
|
-
obj.is_a? Hash
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
326
|
+
if obj.is_a? Hash
|
327
|
+
obj.reduce({}) do |memo, (k, v)|
|
328
|
+
memo[k.to_sym] = symbolize(v)
|
329
|
+
memo
|
330
|
+
end
|
331
|
+
elsif obj.is_a? Array
|
332
|
+
obj.reduce([]) { |memo, v| memo << symbolize(v) }
|
333
|
+
else
|
334
|
+
obj
|
335
|
+
end
|
300
336
|
end
|
301
337
|
|
302
|
-
def array(
|
303
|
-
return [] unless
|
304
|
-
return [
|
305
|
-
|
338
|
+
def array(arr)
|
339
|
+
return [] unless arr
|
340
|
+
return [arr] unless arr.is_a?(Array)
|
341
|
+
|
342
|
+
arr
|
306
343
|
end
|
307
344
|
|
308
|
-
def localname(
|
309
|
-
return nil if
|
310
|
-
|
311
|
-
lang
|
312
|
-
|
313
|
-
script
|
314
|
-
|
315
|
-
|
316
|
-
RelatonBib::LocalizedString.new(
|
345
|
+
def localname(name, person)
|
346
|
+
return nil if name.nil?
|
347
|
+
|
348
|
+
lang = name[:language] if name.is_a?(Hash)
|
349
|
+
lang ||= person[:name][:language]
|
350
|
+
script = name[:script] if name.is_a?(Hash)
|
351
|
+
script ||= person[:name][:script]
|
352
|
+
if name.is_a?(Hash)
|
353
|
+
RelatonBib::LocalizedString.new(name[:content], lang, script)
|
354
|
+
else
|
355
|
+
RelatonBib::LocalizedString.new(name, lang, script)
|
356
|
+
end
|
317
357
|
end
|
318
358
|
|
319
|
-
def localizedstring(
|
320
|
-
|
321
|
-
RelatonBib::LocalizedString.new(
|
322
|
-
|
359
|
+
def localizedstring(lst)
|
360
|
+
if lst.is_a?(Hash)
|
361
|
+
RelatonBib::LocalizedString.new(lst[:content], lst[:language], lst[:script])
|
362
|
+
else
|
363
|
+
RelatonBib::LocalizedString.new(lst)
|
364
|
+
end
|
323
365
|
end
|
324
366
|
|
325
|
-
def formattedref(
|
326
|
-
|
327
|
-
RelatonBib::FormattedRef.new(
|
367
|
+
def formattedref(frf)
|
368
|
+
if frf.is_a?(Hash)
|
369
|
+
RelatonBib::FormattedRef.new(frf)
|
370
|
+
else
|
371
|
+
RelatonBib::FormattedRef.new(content: frf)
|
372
|
+
end
|
328
373
|
end
|
329
374
|
end
|
330
375
|
end
|
data/lib/relaton_bib/hit.rb
CHANGED
@@ -4,7 +4,7 @@ module RelatonBib
|
|
4
4
|
attr_reader :hit
|
5
5
|
|
6
6
|
# @param hit [Hash]
|
7
|
-
# @param hit_collection [RelatonNist:HitCollection]
|
7
|
+
# @param hit_collection [RelatonIso::HitCollection, RelatonNist:HitCollection]
|
8
8
|
def initialize(hit, hit_collection = nil)
|
9
9
|
@hit = hit
|
10
10
|
@hit_collection = hit_collection
|
@@ -45,9 +45,16 @@ module RelatonBib
|
|
45
45
|
|
46
46
|
# @return [Hash]
|
47
47
|
def to_hash
|
48
|
-
|
49
|
-
|
50
|
-
|
48
|
+
th = title.to_hash
|
49
|
+
return th unless type
|
50
|
+
|
51
|
+
hash = { "type" => type }
|
52
|
+
if th.is_a? String
|
53
|
+
hash["content"] = th
|
54
|
+
else
|
55
|
+
hash.merge th
|
56
|
+
end
|
57
|
+
hash
|
51
58
|
end
|
52
59
|
end
|
53
60
|
end
|
data/lib/relaton_bib/version.rb
CHANGED
@@ -5,7 +5,7 @@ module RelatonBib
|
|
5
5
|
class << self
|
6
6
|
def from_xml(xml)
|
7
7
|
doc = Nokogiri::XML(xml)
|
8
|
-
bibitem = doc.at "/bibitem"
|
8
|
+
bibitem = doc.at "/bibitem|/bibdata"
|
9
9
|
BibliographicItem.new(item_data(bibitem))
|
10
10
|
end
|
11
11
|
|
@@ -29,8 +29,8 @@ module RelatonBib
|
|
29
29
|
edition: bibitem.at("./edition")&.text,
|
30
30
|
version: fetch_version(bibitem),
|
31
31
|
biblionote: fetch_note(bibitem),
|
32
|
-
language: bibitem
|
33
|
-
script: bibitem
|
32
|
+
language: fetch_language(bibitem),
|
33
|
+
script: fetch_script(bibitem),
|
34
34
|
abstract: fetch_abstract(bibitem),
|
35
35
|
docstatus: fetch_status(bibitem),
|
36
36
|
copyright: fetch_copyright(bibitem),
|
@@ -67,6 +67,14 @@ module RelatonBib
|
|
67
67
|
end
|
68
68
|
end
|
69
69
|
|
70
|
+
def fetch_language(item)
|
71
|
+
item.xpath("./language").reduce([]) { |a, l| l.text.empty? ? a : a << l.text }
|
72
|
+
end
|
73
|
+
|
74
|
+
def fetch_script(item)
|
75
|
+
item.xpath("./script").reduce([]) { |a, s| s.text.empty? ? a : a << s.text }
|
76
|
+
end
|
77
|
+
|
70
78
|
# rubocop:disable Metrics/AbcSize, Metrics/MethodLength
|
71
79
|
|
72
80
|
def fetch_series(item)
|
@@ -145,8 +153,9 @@ module RelatonBib
|
|
145
153
|
status = item.at("./status")
|
146
154
|
return unless status
|
147
155
|
|
156
|
+
stage = status.at "stage"
|
148
157
|
DocumentStatus.new(
|
149
|
-
stage:
|
158
|
+
stage: stage ? stage.text : status.text,
|
150
159
|
substage: status.at("substage")&.text,
|
151
160
|
iteration: status.at("iteration")&.text,
|
152
161
|
)
|
@@ -154,8 +163,9 @@ module RelatonBib
|
|
154
163
|
|
155
164
|
def fetch_dates(item)
|
156
165
|
item.xpath("./date").map do |d|
|
166
|
+
type = d[:type].to_s.empty? ? "published" : d[:type]
|
157
167
|
RelatonBib::BibliographicDate.new(
|
158
|
-
type:
|
168
|
+
type: type, on: d.at("on")&.text, from: d.at("from")&.text,
|
159
169
|
to: d.at("to")&.text
|
160
170
|
)
|
161
171
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-bib
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-09-
|
11
|
+
date: 2019-09-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|