edn-abnf 0.5.39 → 0.6.1pre

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: edn-abnf
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.39
4
+ version: 0.6.1pre
5
5
  platform: ruby
6
6
  authors:
7
7
  - Carsten Bormann
@@ -112,8 +112,6 @@ files:
112
112
  - lib/cbor-diagnostic-app/hgrammar.rb
113
113
  - lib/cbor-diagnostic-app/ip.rb
114
114
  - lib/cbor-diagnostic-app/ipgrammar.rb
115
- - lib/cbor-diagnostic-app/t1_b1.rb
116
- - lib/cbor-diagnostic-app/zzz.rb
117
115
  - lib/edn-abnf.rb
118
116
  - lib/parser/edn-util.rb
119
117
  - lib/parser/edngrammar.rb
@@ -135,7 +133,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
135
133
  - !ruby/object:Gem::Version
136
134
  version: '0'
137
135
  requirements: []
138
- rubygems_version: 4.0.8
136
+ rubygems_version: 4.0.2
139
137
  specification_version: 4
140
138
  summary: CBOR Extended Diagnostic Notation (EDN) implemented in ABNF
141
139
  test_files: []
@@ -1,32 +0,0 @@
1
- require "cbor-diagnostic-app/0"
2
-
3
- class CBOR_DIAG::Helper
4
- def self.decode_string(app_prefix, s, to_text = false)
5
- ret = if CBOR::Sequence === s
6
- args = s.elements
7
- else
8
- args = [s]
9
- end.map { |el|
10
- unless String === el || el.respond_to?(:value) && String === el.value
11
- raise ArgumentError.new("cbor-diagnostic: #{app_prefix}<<>>: #{el.cbor_diagnostic} not a string: Argument Error")
12
- end
13
- el.b
14
- }.join.b # .b needed so empty array becomes byte string, too
15
- if to_text
16
- ret = ret.force_encoding(Encoding::UTF_8)
17
- end
18
- ret
19
- end
20
- end
21
-
22
- class CBOR_DIAG::App_b1
23
- def self.decode(app_prefix, s)
24
- CBOR_DIAG::Helper.decode_string(app_prefix, s, false)
25
- end
26
- end
27
-
28
- class CBOR_DIAG::App_t1
29
- def self.decode(app_prefix, s)
30
- CBOR_DIAG::Helper.decode_string(app_prefix, s, true)
31
- end
32
- end
@@ -1,13 +0,0 @@
1
- require "cbor-diagnostic-app/0"
2
-
3
- class CBOR_DIAG::App_zzz
4
- def self.decode(app_prefix, s)
5
- CBOR::Tagged.new(999, [app_prefix, s])
6
- end
7
- end
8
-
9
- class CBOR_DIAG::App_yyy
10
- def self.decode(app_prefix, s)
11
- CBOR::Tagged.new(999, [app_prefix, s])
12
- end
13
- end