zxing 0.3.1 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: c3f79b4dbca51ba6146b514d48e9411983626e55
4
+ data.tar.gz: 0686fa416d0bfc86a1758945606a8702a7e28c78
5
+ SHA512:
6
+ metadata.gz: 1fe9da3758b41ed432eafbd8628e6673117e408e18cd6fba75c9a8654f5a232b9ff6e805d7357d3ed491f472ba8d53c98f8184a90c1e9eab14dbc865695df940
7
+ data.tar.gz: c3c0596dbfbf81888f438bad5aabbe247b406bb52bd9541479436f11f31f6be2d02047a78ae25b7082ce177a5f83b06110fcf7c42fcf10323c03ed60648351fb
@@ -6,17 +6,19 @@ module ZXing
6
6
 
7
7
  class Client
8
8
  def self.new
9
- port = find_available_port
10
- remote_client = IO.popen("#{ZXing::BIN} #{port}")
9
+ port = ENV['ZXING_PORT'] || find_available_port
10
+ setup_drb_server(port) unless ENV['ZXING_PORT'] && responsive?(port)
11
+ DRbObject.new_with_uri("druby://127.0.0.1:#{port}")
12
+ end
11
13
 
12
- sleep 0.5 until responsive?(port)
14
+ private
13
15
 
16
+ def self.setup_drb_server(port)
17
+ remote_client = IO.popen("#{ZXing::BIN} #{port}")
18
+ sleep 0.5 until responsive?(port)
14
19
  at_exit { Process.kill(:INT, remote_client.pid) }
15
- client = DRbObject.new_with_uri("druby://127.0.0.1:#{port}")
16
- client
17
20
  end
18
21
 
19
- private
20
22
  def self.responsive?(port)
21
23
  socket = TCPSocket.open('127.0.0.1', port)
22
24
  true
@@ -6,8 +6,8 @@ module ZXing
6
6
  Decoder = Client.new
7
7
  else
8
8
  require 'java'
9
- require 'zxing/core.jar'
10
- require 'zxing/javase.jar'
9
+ require 'zxing/core-3.1.1-SNAPSHOT.jar'
10
+ require 'zxing/javase-3.1.1-SNAPSHOT.jar'
11
11
 
12
12
  java_import com.google.zxing.MultiFormatReader
13
13
  java_import com.google.zxing.BinaryBitmap
@@ -1,3 +1,3 @@
1
1
  module ZXing
2
- VERSION = "0.3.1"
2
+ VERSION = "0.4.0"
3
3
  end
metadata CHANGED
@@ -1,163 +1,112 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: zxing
3
- version: !ruby/object:Gem::Version
4
- hash: 17
5
- prerelease:
6
- segments:
7
- - 0
8
- - 3
9
- - 1
10
- version: 0.3.1
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.4.0
11
5
  platform: ruby
12
- authors:
6
+ authors:
13
7
  - ecin
14
8
  - Joshua Davey
15
9
  autorequire:
16
10
  bindir: bin
17
11
  cert_chain: []
18
-
19
- date: 2011-08-18 00:00:00 -04:00
20
- default_executable:
21
- dependencies:
22
- - !ruby/object:Gem::Dependency
12
+ date: 2014-12-17 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
23
15
  name: jruby-jars
24
- prerelease: false
25
- requirement: &id001 !ruby/object:Gem::Requirement
26
- none: false
27
- requirements:
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
28
18
  - - ">="
29
- - !ruby/object:Gem::Version
30
- hash: 3
31
- segments:
32
- - 0
33
- version: "0"
19
+ - !ruby/object:Gem::Version
20
+ version: '0'
34
21
  type: :runtime
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: sdoc
38
22
  prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
40
- none: false
41
- requirements:
42
- - - ~>
43
- - !ruby/object:Gem::Version
44
- hash: 63
45
- segments:
46
- - 0
47
- - 2
48
- - 20
49
- version: 0.2.20
50
- type: :development
51
- version_requirements: *id002
52
- - !ruby/object:Gem::Dependency
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - ">="
26
+ - !ruby/object:Gem::Version
27
+ version: '0'
28
+ - !ruby/object:Gem::Dependency
53
29
  name: rspec
54
- prerelease: false
55
- requirement: &id003 !ruby/object:Gem::Requirement
56
- none: false
57
- requirements:
58
- - - ~>
59
- - !ruby/object:Gem::Version
60
- hash: 27
61
- segments:
62
- - 2
63
- - 5
64
- - 0
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
65
34
  version: 2.5.0
66
35
  type: :development
67
- version_requirements: *id003
68
- - !ruby/object:Gem::Dependency
69
- name: rake
70
36
  prerelease: false
71
- requirement: &id004 !ruby/object:Gem::Requirement
72
- none: false
73
- requirements:
74
- - - ~>
75
- - !ruby/object:Gem::Version
76
- hash: 63
77
- segments:
78
- - 0
79
- - 9
80
- - 2
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: 2.5.0
42
+ - !ruby/object:Gem::Dependency
43
+ name: rake
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
81
48
  version: 0.9.2
82
49
  type: :development
83
- version_requirements: *id004
84
- description: Need to decode 1D/2D bars and don't mind using JRuby to help with the task? ZXing is the wrapper for you!
85
- email:
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: 0.9.2
56
+ description: Need to decode 1D/2D bars and don't mind using JRuby to help with the
57
+ task? ZXing is the wrapper for you!
58
+ email:
86
59
  - ecin@copypastel.com
87
60
  - josh@joshuadavey.com
88
- executables:
61
+ executables:
89
62
  - zxing
90
- - zxing.compiled.rbc
91
63
  extensions: []
92
-
93
64
  extra_rdoc_files: []
94
-
95
- files:
65
+ files:
66
+ - README.rdoc
96
67
  - bin/zxing
97
- - bin/zxing.compiled.rbc
98
- - lib/a.rb
99
- - lib/a.rbc
68
+ - lib/zxing.rb
100
69
  - lib/zxing/client.rb
101
- - lib/zxing/client.rbc
102
- - lib/zxing/core.jar
70
+ - lib/zxing/core-3.1.1-SNAPSHOT.jar
103
71
  - lib/zxing/decodable.rb
104
72
  - lib/zxing/decoder.rb
105
- - lib/zxing/decoder.rbc
106
- - lib/zxing/javase.jar
73
+ - lib/zxing/javase-3.1.1-SNAPSHOT.jar
107
74
  - lib/zxing/server.rb
108
75
  - lib/zxing/version.rb
109
- - lib/zxing/version.rbc
110
- - lib/zxing.rb
111
- - lib/zxing.rbc
112
76
  - spec/fixtures/cat.png
113
77
  - spec/fixtures/example.png
114
78
  - spec/fixtures/multi_barcode_example.png
115
79
  - spec/spec_helper.rb
116
- - spec/spec_helper.rbc
117
80
  - spec/zxing/decodable_spec.rb
118
81
  - spec/zxing_spec.rb
119
- - spec/zxing_spec.rbc
120
- - README.rdoc
121
- has_rdoc: true
122
82
  homepage: http://github.com/ecin/zxing.rb
123
83
  licenses: []
124
-
84
+ metadata: {}
125
85
  post_install_message:
126
86
  rdoc_options: []
127
-
128
- require_paths:
87
+ require_paths:
129
88
  - lib
130
- required_ruby_version: !ruby/object:Gem::Requirement
131
- none: false
132
- requirements:
89
+ required_ruby_version: !ruby/object:Gem::Requirement
90
+ requirements:
133
91
  - - ">="
134
- - !ruby/object:Gem::Version
135
- hash: 3
136
- segments:
137
- - 0
138
- version: "0"
139
- required_rubygems_version: !ruby/object:Gem::Requirement
140
- none: false
141
- requirements:
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
94
+ required_rubygems_version: !ruby/object:Gem::Requirement
95
+ requirements:
142
96
  - - ">="
143
- - !ruby/object:Gem::Version
144
- hash: 3
145
- segments:
146
- - 0
147
- version: "0"
97
+ - !ruby/object:Gem::Version
98
+ version: '0'
148
99
  requirements: []
149
-
150
100
  rubyforge_project: zxing
151
- rubygems_version: 1.6.2
101
+ rubygems_version: 2.4.3
152
102
  signing_key:
153
- specification_version: 3
103
+ specification_version: 4
154
104
  summary: JRuby wrapper for ZXing 1D/2D barcode image processing library.
155
- test_files:
105
+ test_files:
156
106
  - spec/fixtures/cat.png
157
107
  - spec/fixtures/example.png
158
108
  - spec/fixtures/multi_barcode_example.png
159
109
  - spec/spec_helper.rb
160
- - spec/spec_helper.rbc
161
110
  - spec/zxing/decodable_spec.rb
162
111
  - spec/zxing_spec.rb
163
- - spec/zxing_spec.rbc
112
+ has_rdoc:
@@ -1,390 +0,0 @@
1
- !RBIX
2
- 2390329161478264409
3
- x
4
- M
5
- 1
6
- n
7
- n
8
- x
9
- 10
10
- __script__
11
- i
12
- 180
13
- 5
14
- 7
15
- 0
16
- 64
17
- 47
18
- 49
19
- 1
20
- 1
21
- 15
22
- 5
23
- 7
24
- 2
25
- 64
26
- 47
27
- 49
28
- 1
29
- 1
30
- 15
31
- 45
32
- 3
33
- 4
34
- 78
35
- 49
36
- 5
37
- 1
38
- 19
39
- 0
40
- 15
41
- 45
42
- 6
43
- 7
44
- 49
45
- 8
46
- 0
47
- 19
48
- 1
49
- 15
50
- 45
51
- 6
52
- 9
53
- 49
54
- 10
55
- 0
56
- 19
57
- 2
58
- 15
59
- 7
60
- 11
61
- 64
62
- 45
63
- 6
64
- 12
65
- 49
66
- 8
67
- 0
68
- 45
69
- 6
70
- 13
71
- 49
72
- 10
73
- 0
74
- 35
75
- 2
76
- 7
77
- 14
78
- 64
79
- 49
80
- 15
81
- 1
82
- 7
83
- 16
84
- 64
85
- 35
86
- 3
87
- 19
88
- 3
89
- 15
90
- 45
91
- 17
92
- 18
93
- 7
94
- 19
95
- 64
96
- 65
97
- 49
98
- 20
99
- 0
100
- 49
101
- 21
102
- 2
103
- 19
104
- 4
105
- 15
106
- 99
107
- 43
108
- 22
109
- 7
110
- 23
111
- 49
112
- 5
113
- 1
114
- 20
115
- 4
116
- 49
117
- 24
118
- 1
119
- 9
120
- 111
121
- 1
122
- 8
123
- 124
124
- 99
125
- 43
126
- 22
127
- 7
128
- 23
129
- 49
130
- 5
131
- 1
132
- 20
133
- 4
134
- 49
135
- 25
136
- 1
137
- 15
138
- 20
139
- 4
140
- 47
141
- 101
142
- 26
143
- 7
144
- 27
145
- 63
146
- 2
147
- 19
148
- 5
149
- 15
150
- 7
151
- 28
152
- 64
153
- 20
154
- 5
155
- 7
156
- 29
157
- 64
158
- 7
159
- 30
160
- 20
161
- 0
162
- 47
163
- 101
164
- 26
165
- 7
166
- 31
167
- 63
168
- 3
169
- 35
170
- 4
171
- 19
172
- 6
173
- 15
174
- 5
175
- 7
176
- 32
177
- 64
178
- 20
179
- 3
180
- 20
181
- 6
182
- 81
183
- 33
184
- 36
185
- 1
186
- 47
187
- 51
188
- 34
189
- 1
190
- 15
191
- 2
192
- 11
193
- I
194
- d
195
- I
196
- 7
197
- I
198
- 0
199
- I
200
- 0
201
- n
202
- p
203
- 35
204
- s
205
- 8
206
- rubygems
207
- x
208
- 7
209
- require
210
- s
211
- 10
212
- jruby-jars
213
- x
214
- 4
215
- ARGV
216
- n
217
- x
218
- 2
219
- []
220
- x
221
- 9
222
- JRubyJars
223
- n
224
- x
225
- 13
226
- core_jar_path
227
- n
228
- x
229
- 15
230
- stdlib_jar_path
231
- s
232
- 3
233
- -cp
234
- n
235
- n
236
- s
237
- 1
238
- :
239
- x
240
- 4
241
- join
242
- s
243
- 14
244
- org.jruby.Main
245
- x
246
- 4
247
- File
248
- n
249
- s
250
- 9
251
- ../../lib
252
- x
253
- 11
254
- active_path
255
- x
256
- 11
257
- expand_path
258
- x
259
- 7
260
- Globals
261
- x
262
- 2
263
- $:
264
- x
265
- 8
266
- include?
267
- x
268
- 7
269
- unshift
270
- x
271
- 4
272
- to_s
273
- s
274
- 16
275
- /zxing/server.rb
276
- s
277
- 2
278
- -r
279
- s
280
- 2
281
- -e
282
- s
283
- 21
284
- ZXing::Server.start!(
285
- s
286
- 1
287
- )
288
- s
289
- 4
290
- java
291
- x
292
- 1
293
- +
294
- x
295
- 4
296
- exec
297
- p
298
- 33
299
- I
300
- 0
301
- I
302
- 2
303
- I
304
- 9
305
- I
306
- 3
307
- I
308
- 12
309
- I
310
- 5
311
- I
312
- 1c
313
- I
314
- 7
315
- I
316
- 25
317
- I
318
- 8
319
- I
320
- 2e
321
- I
322
- b
323
- I
324
- 45
325
- I
326
- c
327
- I
328
- 4a
329
- I
330
- a
331
- I
332
- 4d
333
- I
334
- f
335
- I
336
- 5d
337
- I
338
- 10
339
- I
340
- 7c
341
- I
342
- 0
343
- I
344
- 7d
345
- I
346
- 12
347
- I
348
- 89
349
- I
350
- 15
351
- I
352
- 8e
353
- I
354
- 16
355
- I
356
- 9e
357
- I
358
- 14
359
- I
360
- a1
361
- I
362
- 19
363
- I
364
- b4
365
- x
366
- 50
367
- /Users/ncrespo/Developer/ruby/ruby/zxing/bin/zxing
368
- p
369
- 7
370
- x
371
- 4
372
- port
373
- x
374
- 5
375
- jruby
376
- x
377
- 12
378
- jruby_stdlib
379
- x
380
- 9
381
- java_args
382
- x
383
- 3
384
- lib
385
- x
386
- 4
387
- path
388
- x
389
- 9
390
- ruby_args