relaton-3gpp 1.13.0 → 1.14.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rake.yml +1 -2
- data/.github/workflows/release.yml +22 -0
- data/README.adoc +47 -58
- data/grammars/basicdoc.rng +3 -27
- data/grammars/biblio-standoc.rng +164 -0
- data/grammars/biblio.rng +82 -19
- data/grammars/relaton-3gpp-compile.rng +11 -0
- data/grammars/{3gpp.rng → relaton-3gpp.rng} +64 -40
- data/lib/relaton_3gpp/bibliographic_item.rb +25 -3
- data/lib/relaton_3gpp/bibliography.rb +2 -1
- data/lib/relaton_3gpp/data_fetcher.rb +2 -1
- data/lib/relaton_3gpp/parser.rb +0 -1
- data/lib/relaton_3gpp/version.rb +1 -1
- data/relaton_3gpp.gemspec +1 -1
- metadata +12 -11
- data/grammars/isodoc.rng +0 -2807
- data/grammars/reqt.rng +0 -223
@@ -1,9 +1,6 @@
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
2
2
|
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
3
|
-
<include href="
|
4
|
-
<start>
|
5
|
-
<ref name="iso-standard"/>
|
6
|
-
</start>
|
3
|
+
<include href="biblio-standoc.rng">
|
7
4
|
<define name="DocumentType">
|
8
5
|
<choice>
|
9
6
|
<value>TR</value>
|
@@ -17,6 +14,9 @@
|
|
17
14
|
</choice>
|
18
15
|
</define>
|
19
16
|
<define name="BibDataExtensionType">
|
17
|
+
<optional>
|
18
|
+
<attribute name="schema-version"/>
|
19
|
+
</optional>
|
20
20
|
<ref name="doctype"/>
|
21
21
|
<optional>
|
22
22
|
<ref name="docsubtype"/>
|
@@ -64,42 +64,66 @@
|
|
64
64
|
</define>
|
65
65
|
<define name="release">
|
66
66
|
<element name="release">
|
67
|
-
<
|
68
|
-
<
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
|
81
|
-
</
|
82
|
-
<
|
83
|
-
<
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
</
|
97
|
-
<
|
98
|
-
<
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
67
|
+
<optional>
|
68
|
+
<element name="version2G">
|
69
|
+
<text/>
|
70
|
+
</element>
|
71
|
+
</optional>
|
72
|
+
<optional>
|
73
|
+
<element name="version3G">
|
74
|
+
<text/>
|
75
|
+
</element>
|
76
|
+
</optional>
|
77
|
+
<optional>
|
78
|
+
<element name="defunct">
|
79
|
+
<data type="boolean"/>
|
80
|
+
</element>
|
81
|
+
</optional>
|
82
|
+
<optional>
|
83
|
+
<element name="wpm-code-2G">
|
84
|
+
<text/>
|
85
|
+
</element>
|
86
|
+
</optional>
|
87
|
+
<optional>
|
88
|
+
<element name="wpm-code-3G">
|
89
|
+
<text/>
|
90
|
+
</element>
|
91
|
+
</optional>
|
92
|
+
<optional>
|
93
|
+
<element name="freeze-meeting">
|
94
|
+
<text/>
|
95
|
+
</element>
|
96
|
+
</optional>
|
97
|
+
<optional>
|
98
|
+
<element name="freeze-stage1-meeting">
|
99
|
+
<text/>
|
100
|
+
</element>
|
101
|
+
</optional>
|
102
|
+
<optional>
|
103
|
+
<element name="freeze-stage2-meeting">
|
104
|
+
<text/>
|
105
|
+
</element>
|
106
|
+
</optional>
|
107
|
+
<optional>
|
108
|
+
<element name="freeze-stage3-meeting">
|
109
|
+
<text/>
|
110
|
+
</element>
|
111
|
+
</optional>
|
112
|
+
<optional>
|
113
|
+
<element name="close-meeting">
|
114
|
+
<text/>
|
115
|
+
</element>
|
116
|
+
</optional>
|
117
|
+
<optional>
|
118
|
+
<element name="project-start">
|
119
|
+
<data type="date"/>
|
120
|
+
</element>
|
121
|
+
</optional>
|
122
|
+
<optional>
|
123
|
+
<element name="project-end">
|
124
|
+
<data type="date"/>
|
125
|
+
</element>
|
126
|
+
</optional>
|
103
127
|
</element>
|
104
128
|
</define>
|
105
129
|
</grammar>
|
@@ -31,6 +31,27 @@ module Relaton3gpp
|
|
31
31
|
super(**args)
|
32
32
|
end
|
33
33
|
|
34
|
+
#
|
35
|
+
# Fetch the flavor shcema version
|
36
|
+
#
|
37
|
+
# @return [String] schema version
|
38
|
+
#
|
39
|
+
def ext_schema
|
40
|
+
@ext_schema ||= schema_versions["relaton-model-3gpp"]
|
41
|
+
end
|
42
|
+
|
43
|
+
#
|
44
|
+
# @override RelatonBib::BibliographicItem#makeid
|
45
|
+
#
|
46
|
+
# @param [RelatonBib::DocumentIdentifier, nil] identifier <description>
|
47
|
+
# @param [Boolean, nil] attribute true if the ID attribute is needed
|
48
|
+
#
|
49
|
+
# @return [String, nil] id
|
50
|
+
#
|
51
|
+
def makeid(identifier, attribute)
|
52
|
+
super&.sub(/^3GPP/, "")
|
53
|
+
end
|
54
|
+
|
34
55
|
# @param opts [Hash]
|
35
56
|
# @option opts [Nokogiri::XML::Builder] :builder XML builder
|
36
57
|
# @option opts [Boolean] :bibdata
|
@@ -40,15 +61,16 @@ module Relaton3gpp
|
|
40
61
|
super do |b|
|
41
62
|
if block_given? then yield b
|
42
63
|
elsif opts[:bibdata] && has_ext_attrs?
|
43
|
-
b.ext do
|
64
|
+
ext = b.ext do
|
44
65
|
b.doctype doctype if doctype
|
45
66
|
b.subdoctype subdoctype if subdoctype
|
46
67
|
editorialgroup&.to_xml b
|
47
68
|
ics.each { |i| i.to_xml b }
|
48
69
|
b.radiotechnology @radiotechnology if @radiotechnology
|
49
|
-
b.send "common-ims-spec", @common_ims_spec if @common_ims_spec
|
50
|
-
@release&.to_xml b
|
70
|
+
b.send :"common-ims-spec", @common_ims_spec if @common_ims_spec
|
71
|
+
@release&.to_xml b
|
51
72
|
end
|
73
|
+
ext["schema-version"] = ext_schema unless opts[:embedded]
|
52
74
|
end
|
53
75
|
end
|
54
76
|
end
|
@@ -8,7 +8,7 @@ module Relaton3gpp
|
|
8
8
|
|
9
9
|
# @param text [String]
|
10
10
|
# @return [RelatonBib::BibliographicItem]
|
11
|
-
def search(text) # rubocop:disable Metrics/MethodLength
|
11
|
+
def search(text) # rubocop:disable Metrics/MethodLength, Metrics/AbcSize
|
12
12
|
file = text.sub(/^3GPP\s/, "").gsub(/[\s,:\/]/, "_").squeeze("_").upcase
|
13
13
|
url = "#{SOURCE}#{file}.yaml"
|
14
14
|
resp = Net::HTTP.get_response URI(url)
|
@@ -16,6 +16,7 @@ module Relaton3gpp
|
|
16
16
|
|
17
17
|
hash = YAML.safe_load resp.body
|
18
18
|
bib_hash = Relaton3gpp::HashConverter.hash_to_bib(hash)
|
19
|
+
bib_hash[:fetched] = Date.today.to_s
|
19
20
|
Relaton3gpp::BibliographicItem.new(**bib_hash)
|
20
21
|
rescue SocketError, Timeout::Error, Errno::EINVAL, Errno::ECONNRESET,
|
21
22
|
EOFError, Net::HTTPBadResponse, Net::HTTPHeaderSyntaxError,
|
@@ -28,7 +28,7 @@ module Relaton3gpp
|
|
28
28
|
def self.fetch(output: "data", format: "yaml")
|
29
29
|
t1 = Time.now
|
30
30
|
puts "Started at: #{t1}"
|
31
|
-
FileUtils.mkdir_p output
|
31
|
+
FileUtils.mkdir_p output
|
32
32
|
new(output, format).fetch
|
33
33
|
t2 = Time.now
|
34
34
|
puts "Stopped at: #{t2}"
|
@@ -53,6 +53,7 @@ module Relaton3gpp
|
|
53
53
|
specrels = dbs["Specs_GSM+3G_release-info"]
|
54
54
|
releases = dbs["Releases"]
|
55
55
|
tstatus = dbs["temp-status"]
|
56
|
+
FileUtils.rm_rf @output if dbs["2001-04-25_schedule"].any?
|
56
57
|
dbs["2001-04-25_schedule"].each do |row|
|
57
58
|
fetch_doc row, specs, specrels, releases, tstatus
|
58
59
|
end
|
data/lib/relaton_3gpp/parser.rb
CHANGED
data/lib/relaton_3gpp/version.rb
CHANGED
data/relaton_3gpp.gemspec
CHANGED
@@ -46,6 +46,6 @@ Gem::Specification.new do |spec|
|
|
46
46
|
|
47
47
|
spec.add_dependency "mdb", "~> 0.5.0"
|
48
48
|
spec.add_dependency "net-ftp", "~> 0.1.0"
|
49
|
-
spec.add_dependency "relaton-bib", "~> 1.
|
49
|
+
spec.add_dependency "relaton-bib", "~> 1.14.0"
|
50
50
|
spec.add_dependency "rubyzip", "~> 2.3.0"
|
51
51
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: relaton-3gpp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.14.1
|
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: 2022-
|
11
|
+
date: 2022-12-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: equivalent-xml
|
@@ -156,14 +156,14 @@ dependencies:
|
|
156
156
|
requirements:
|
157
157
|
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: 1.
|
159
|
+
version: 1.14.0
|
160
160
|
type: :runtime
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: 1.
|
166
|
+
version: 1.14.0
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
168
|
name: rubyzip
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|
@@ -186,6 +186,7 @@ extensions: []
|
|
186
186
|
extra_rdoc_files: []
|
187
187
|
files:
|
188
188
|
- ".github/workflows/rake.yml"
|
189
|
+
- ".github/workflows/release.yml"
|
189
190
|
- ".gitignore"
|
190
191
|
- ".rspec"
|
191
192
|
- ".rubocop.yml"
|
@@ -196,11 +197,11 @@ files:
|
|
196
197
|
- bin/console
|
197
198
|
- bin/rspec
|
198
199
|
- bin/setup
|
199
|
-
- grammars/3gpp.rng
|
200
200
|
- grammars/basicdoc.rng
|
201
|
+
- grammars/biblio-standoc.rng
|
201
202
|
- grammars/biblio.rng
|
202
|
-
- grammars/
|
203
|
-
- grammars/
|
203
|
+
- grammars/relaton-3gpp-compile.rng
|
204
|
+
- grammars/relaton-3gpp.rng
|
204
205
|
- lib/relaton_3gpp.rb
|
205
206
|
- lib/relaton_3gpp/bibliographic_item.rb
|
206
207
|
- lib/relaton_3gpp/bibliography.rb
|
@@ -217,7 +218,7 @@ licenses:
|
|
217
218
|
- BSD-2-Clause
|
218
219
|
metadata:
|
219
220
|
homepage_uri: https://github.com/relaton/relaton-iana
|
220
|
-
post_install_message:
|
221
|
+
post_install_message:
|
221
222
|
rdoc_options: []
|
222
223
|
require_paths:
|
223
224
|
- lib
|
@@ -232,8 +233,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
232
233
|
- !ruby/object:Gem::Version
|
233
234
|
version: '0'
|
234
235
|
requirements: []
|
235
|
-
rubygems_version: 3.
|
236
|
-
signing_key:
|
236
|
+
rubygems_version: 3.1.6
|
237
|
+
signing_key:
|
237
238
|
specification_version: 4
|
238
239
|
summary: 'RelatonIana: Ruby XMLDOC impementation.'
|
239
240
|
test_files: []
|