rseed 1.0.8 → 1.0.9
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.
- checksums.yaml +8 -8
- data/lib/rseed/processor.rb +13 -12
- data/lib/rseed/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
MGRjNTEyYjQzZGJjMmEwY2EwZjYwMTQyNDI2N2IzN2Y0NTc4NmJjNA==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NWUwMDU2MTA4OGEwNjA5ZDYwOTc2MWU0MDhmODNmYTRmM2IyNGZiMA==
|
|
7
7
|
SHA512:
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
ODJjNjg2OTgxMTY5ZDhkZmJiNDBlNjNlMzUyZmJmOTk5ZjkwZjk1YzU4MjVl
|
|
10
|
+
ZTIwZmYzOGI0MWU4MzkwYjRkZTViMDYyNzBmMzc4YTc2MjgzN2ZhZmFkMTc1
|
|
11
|
+
ZTcxYzI5M2JkZGYzMWVkZmJkYjc5ZTJiMzNlNWE4ZjY5MzhiYzM=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
MDk0YWI1MThlN2YzZjgxYmMyMzgwNDRjYjhmZDk4ZDJkMTkzZWQ5OTI4MmU0
|
|
14
|
+
YTMwYzU1ZjkxZjE3NmM4NTFhNjRlZmUyN2IyNmI5ZjJhM2FlZTUyODQ0Zjkz
|
|
15
|
+
YjYzY2ZiOWQ5ZTgwMzMxYTkxMTFjNTVhMGQ0YTQ3NmUzNjk3OWY=
|
data/lib/rseed/processor.rb
CHANGED
|
@@ -10,18 +10,7 @@ module Rseed
|
|
|
10
10
|
|
|
11
11
|
adapter = options[:adapter].is_a?(Adapter) ? options[:adapter] : Rseed.const_get("#{options[:adapter].to_s.classify}Adapter").new
|
|
12
12
|
converter = options[:converter].is_a?(Converter) ? options[:converter] : Rseed.const_get("#{options[:converter].to_s.classify}Converter").new
|
|
13
|
-
if options[:converter_options]
|
|
14
|
-
converter_options = options[:converter_options]
|
|
15
|
-
if converter_options.is_a? String
|
|
16
|
-
options = converter_options.split(";")
|
|
17
|
-
converter_options = {}
|
|
18
|
-
options.each do |option|
|
|
19
|
-
s = option.split("=")
|
|
20
|
-
converter_options[s[0].strip] = s[1].strip
|
|
21
|
-
end
|
|
22
|
-
end
|
|
23
|
-
converter.options = HashWithIndifferentAccess.new(converter_options)
|
|
24
|
-
end
|
|
13
|
+
converter_options = deserialize_converter_options(options[:converter_options])if options[:converter_options]
|
|
25
14
|
@within_transaction = options[:within_transaction]
|
|
26
15
|
@adapter = adapter
|
|
27
16
|
@converter = converter
|
|
@@ -109,5 +98,17 @@ module Rseed
|
|
|
109
98
|
yield
|
|
110
99
|
end
|
|
111
100
|
end
|
|
101
|
+
|
|
102
|
+
def deserialize_converter_options converter_options
|
|
103
|
+
if converter_options.is_a? String
|
|
104
|
+
co = converter_options.split(";")
|
|
105
|
+
converter_options = {}
|
|
106
|
+
co.each do |option|
|
|
107
|
+
s = option.split("=")
|
|
108
|
+
converter_options[s[0].strip] = s[1].strip
|
|
109
|
+
end
|
|
110
|
+
end
|
|
111
|
+
HashWithIndifferentAccess.new(converter_options)
|
|
112
|
+
end
|
|
112
113
|
end
|
|
113
114
|
end
|
data/lib/rseed/version.rb
CHANGED