aspose_barcode_cloud 1.0.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: f03ae67f3d87a05e9ded1449fd28beb402a259ca
4
+ data.tar.gz: d03b5121ed7eb1e31ab196fb75d9444deb77bea3
5
+ SHA512:
6
+ metadata.gz: e636ede453ec47533644835cd58e993525670c5b455334d1ab903d3e6283ff23eff50f61619b422e0ffa4abbfac7871edce3c1d89e8df8861d6722e64f58fb73
7
+ data.tar.gz: 6a16b8b607438c97ef9e22d7acacbe06e9a3bc9d225d80cab3781b123b6d7f94bbf93409bb7a9a91a6f2b90498cfc2ca2c139fb2b8701d07d55b21a8d64ab10e
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2001-2016 Aspose Pty Ltd
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
@@ -0,0 +1,42 @@
1
+ # Aspose.Slides Cloud SDK For Ruby
2
+ This SDK lets you use [Aspose Cloud Slides APIs](http://www.aspose.com/cloud/powerpoint-api.aspx) in your web apps.
3
+
4
+ ## Installing
5
+ You can simply install Aspose Slides Cloud SDK with gem:
6
+
7
+ `gem install aspose_slides_cloud`
8
+
9
+ ## Usage
10
+ APIs of this SDK can be called as follows:
11
+
12
+ ```ruby
13
+ require 'aspose_slides_cloud'
14
+
15
+ class SlidesUsage
16
+
17
+ include AsposeSlidesCloud
18
+ include AsposeStorageCloud
19
+
20
+ def initialize
21
+ #Get App key and App SID from https://cloud.aspose.com
22
+ AsposeApp.app_key_and_sid("APP_KEY", "APP_SID")
23
+ @slides_api = SlidesApi.new
24
+ end
25
+
26
+ def put_slides_convert
27
+ #Convert presentation from request content to format specified.
28
+ file_name = "sample.pptx"
29
+ convert_to_format = "pdf"
30
+ response = @slides_api.put_slides_convert(File.open("data/" << file_name,"r") { |io| io.read }, {format: convert_to_format})
31
+ end
32
+
33
+ end
34
+ ```
35
+ ## Unit Tests
36
+ Aspose Slides SDK includes a suite of unit tests within the [test](https://github.com/asposeslides/Aspose_Slides_Cloud/blob/master/SDKs/Aspose.Slides_Cloud_SDK_For_Ruby/test/slides_tests.rb) subdirectory. These Unit Tests also serves as examples of how to use the Aspose Slides SDK.
37
+
38
+ ## Contact
39
+ Your feedback is very important to us. Please email us all your queries and feedback at marketplace@aspose.com.
40
+
41
+ ## License
42
+ Aspose Slides SDK is available under the MIT license. See the [LICENSE](https://github.com/asposeslides/Aspose_Slides_Cloud/blob/master/SDKs/Aspose.Slides_Cloud_SDK_For_Ruby/LICENSE) file for more info.
@@ -0,0 +1,26 @@
1
+ # -*- encoding: utf-8 -*-
2
+ $:.push File.expand_path("../lib", __FILE__)
3
+ require "aspose_barcode_cloud/version"
4
+
5
+ Gem::Specification.new do |s|
6
+ s.name = "aspose_barcode_cloud"
7
+ s.version = AsposeBarcodeCloud::VERSION
8
+ s.platform = Gem::Platform::RUBY
9
+ s.authors = ["M. Sohail Ismail"]
10
+ s.email = ["muhammad.sohail@aspose.com"]
11
+ s.homepage = "http://www.aspose.com/cloud/barcode-api.aspx"
12
+ s.summary = %q{Aspose.Barcode for Cloud}
13
+ s.description = %q{Aspose.Barcode for Cloud is a REST API for barcode generation and recognition. It helps you generate barcode images from scratch in linear (1D), two dimensional (2D), and postal formats. Generate barcode images in a variety of image formats: JPEG, PNG, GIF, BMP, TIFF and many others. Recognize barcodes from different image types. Aspose.Barcode for Cloud allows you to control all aspects of the image and barcode when generating barcode images. Specify image width, height, border style, output image format and more. You can also set barcode attributes like font style, font color, background color, barcode type and the barcode text location.}
14
+ s.license = "MIT"
15
+
16
+ s.add_runtime_dependency 'typhoeus', '~> 0.8'
17
+ s.add_runtime_dependency 'json', '~> 1.7'
18
+ s.add_runtime_dependency 'aspose_storage_cloud', '~> 1.0', '>= 1.0.0'
19
+
20
+ s.add_development_dependency 'minitest', '~> 5.8'
21
+
22
+ s.files = `git ls-files`.split("\n")
23
+ s.test_files = `git ls-files -- test/*`.split("\n")
24
+ s.executables = []
25
+ s.require_paths = ["lib"]
26
+ end
@@ -0,0 +1,39 @@
1
+ require 'aspose_storage_cloud'
2
+
3
+ # Common files
4
+ require_relative 'aspose_barcode_cloud/api_client'
5
+ require_relative 'aspose_barcode_cloud/api_error'
6
+ require_relative 'aspose_barcode_cloud/version'
7
+ require_relative 'aspose_barcode_cloud/configuration'
8
+
9
+ # Models
10
+ require_relative 'aspose_barcode_cloud/models/base_object'
11
+ require_relative 'aspose_barcode_cloud/models/base_response'
12
+ require_relative 'aspose_barcode_cloud/models/barcode_response_list'
13
+ require_relative 'aspose_barcode_cloud/models/barcode_response'
14
+ require_relative 'aspose_barcode_cloud/models/barcode_reader'
15
+ require_relative 'aspose_barcode_cloud/models/barcode_builders_list'
16
+ require_relative 'aspose_barcode_cloud/models/barcode_builder'
17
+ require_relative 'aspose_barcode_cloud/models/resolution'
18
+ require_relative 'aspose_barcode_cloud/models/margins'
19
+
20
+ # APIs
21
+ require_relative 'aspose_barcode_cloud/api/barcode_api'
22
+
23
+ module AsposeBarcodeCloud
24
+ class << self
25
+ # Configure sdk using block.
26
+ # AsposeBarcodeCloud.configure do |config|
27
+ # config.username = "xxx"
28
+ # config.password = "xxx"
29
+ # end
30
+ # If no block given, return the configuration singleton instance.
31
+ def configure
32
+ if block_given?
33
+ yield Configuration.instance
34
+ else
35
+ Configuration.instance
36
+ end
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,478 @@
1
+ require "uri"
2
+
3
+ module AsposeBarcodeCloud
4
+ class BarcodeApi
5
+ attr_accessor :api_client
6
+
7
+ def initialize(api_client = nil)
8
+ @api_client = api_client || Configuration.api_client
9
+ end
10
+
11
+ # Generate barcode.
12
+ #
13
+ # @param [Hash] opts the optional parameters
14
+ # @option opts [String] :text The code text.
15
+ # @option opts [String] :type Barcode type.
16
+ # @option opts [String] :format Result format.
17
+ # @option opts [Float] :resolution_x Horizontal resolution.
18
+ # @option opts [Float] :resolution_y Vertical resolution.
19
+ # @option opts [Float] :dimension_x Smallest width of barcode unit (bar or space).
20
+ # @option opts [Float] :dimension_y Smallest height of barcode unit (for 2D barcodes).
21
+ # @option opts [String] :enable_checksum Sets if checksum will be generated.
22
+ # @return [File]
23
+ def get_barcode_generate(opts = {})
24
+ if Configuration.debugging
25
+ Configuration.logger.debug "Calling API: BarcodeApi#get_barcode_generate ..."
26
+ end
27
+
28
+ # resource path
29
+ path = "/barcode/generate".sub('{format}','json')
30
+
31
+ # query parameters
32
+ query_params = {}
33
+ query_params[:'text'] = opts[:'text'] if opts[:'text']
34
+ query_params[:'type'] = opts[:'type'] if opts[:'type']
35
+ query_params[:'format'] = opts[:'format'] if opts[:'format']
36
+ query_params[:'resolutionX'] = opts[:'resolution_x'] if opts[:'resolution_x']
37
+ query_params[:'resolutionY'] = opts[:'resolution_y'] if opts[:'resolution_y']
38
+ query_params[:'dimensionX'] = opts[:'dimension_x'] if opts[:'dimension_x']
39
+ query_params[:'dimensionY'] = opts[:'dimension_y'] if opts[:'dimension_y']
40
+ query_params[:'enableChecksum'] = opts[:'enable_checksum'] if opts[:'enable_checksum']
41
+
42
+ # header parameters
43
+ header_params = {}
44
+
45
+ # HTTP header 'Accept' (if needed)
46
+ _header_accept = []
47
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
48
+
49
+ # HTTP header 'Content-Type'
50
+ _header_content_type = []
51
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
52
+
53
+ # form parameters
54
+ form_params = {}
55
+
56
+ # http body (model)
57
+ post_body = nil
58
+
59
+
60
+ auth_names = []
61
+ result = @api_client.call_api(:GET, path,
62
+ :header_params => header_params,
63
+ :query_params => query_params,
64
+ :form_params => form_params,
65
+ :body => post_body,
66
+ :auth_names => auth_names,
67
+ :return_type => 'File')
68
+ if Configuration.debugging
69
+ Configuration.logger.debug "API called: BarcodeApi#get_barcode_generate. Result: #{result.inspect}"
70
+ end
71
+ return result
72
+ end
73
+
74
+ # Generate multiple barcodes and return in response stream
75
+ #
76
+ # @param dto List of barcodes
77
+ # @param [Hash] opts the optional parameters
78
+ # @option opts [String] :format Format to return stream in
79
+ # @return [File]
80
+ def post_generate_multiple(dto, opts = {})
81
+ if Configuration.debugging
82
+ Configuration.logger.debug "Calling API: BarcodeApi#post_generate_multiple ..."
83
+ end
84
+
85
+ # verify the required parameter 'dto' is set
86
+ fail "Missing the required parameter 'dto' when calling post_generate_multiple" if dto.nil?
87
+
88
+ # resource path
89
+ path = "/barcode/generateMultiple".sub('{format}','json')
90
+
91
+ # query parameters
92
+ query_params = {}
93
+ query_params[:'format'] = opts[:'format'] if opts[:'format']
94
+
95
+ # header parameters
96
+ header_params = {}
97
+
98
+ # HTTP header 'Accept' (if needed)
99
+ _header_accept = []
100
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
101
+
102
+ # HTTP header 'Content-Type'
103
+ _header_content_type = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript', 'application/x-www-form-urlencoded']
104
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
105
+
106
+ # form parameters
107
+ form_params = {}
108
+
109
+ # http body (model)
110
+ post_body = @api_client.object_to_http_body(dto)
111
+
112
+
113
+ auth_names = []
114
+ result = @api_client.call_api(:POST, path,
115
+ :header_params => header_params,
116
+ :query_params => query_params,
117
+ :form_params => form_params,
118
+ :body => post_body,
119
+ :auth_names => auth_names,
120
+ :return_type => 'File')
121
+ if Configuration.debugging
122
+ Configuration.logger.debug "API called: BarcodeApi#post_generate_multiple. Result: #{result.inspect}"
123
+ end
124
+ return result
125
+ end
126
+
127
+ # Recognize barcode from an url.
128
+ #
129
+ # @param [Hash] opts the optional parameters
130
+ # @option opts [String] :type Barcode type.
131
+ # @option opts [String] :checksum_validation Checksum validation parameter.
132
+ # @option opts [BOOLEAN] :strip_fnc Allows to strip FNC symbol in recognition results.
133
+ # @option opts [Integer] :rotation_angle Recognition of rotated barcode. Possible angles are 90, 180, 270, default is 0
134
+ # @option opts [String] :url The image file url.
135
+ # @option opts [File] :file
136
+ # @return [BarcodeResponseList]
137
+ def post_barcode_recognize_from_urlor_content(opts = {})
138
+ if Configuration.debugging
139
+ Configuration.logger.debug "Calling API: BarcodeApi#post_barcode_recognize_from_urlor_content ..."
140
+ end
141
+
142
+ # resource path
143
+ path = "/barcode/recognize".sub('{format}','json')
144
+
145
+ # query parameters
146
+ query_params = {}
147
+ query_params[:'type'] = opts[:'type'] if opts[:'type']
148
+ query_params[:'checksumValidation'] = opts[:'checksum_validation'] if opts[:'checksum_validation']
149
+ query_params[:'stripFnc'] = opts[:'strip_fnc'] if opts[:'strip_fnc']
150
+ query_params[:'rotationAngle'] = opts[:'rotation_angle'] if opts[:'rotation_angle']
151
+ query_params[:'url'] = opts[:'url'] if opts[:'url']
152
+
153
+ # header parameters
154
+ header_params = {}
155
+
156
+ # HTTP header 'Accept' (if needed)
157
+ _header_accept = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript']
158
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
159
+
160
+ # HTTP header 'Content-Type'
161
+ _header_content_type = []
162
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
163
+
164
+ # form parameters
165
+ form_params = {}
166
+ form_params["file"] = opts[:'file'] if opts[:'file']
167
+
168
+ # http body (model)
169
+ post_body = nil
170
+
171
+
172
+ auth_names = []
173
+ result = @api_client.call_api(:POST, path,
174
+ :header_params => header_params,
175
+ :query_params => query_params,
176
+ :form_params => form_params,
177
+ :body => post_body,
178
+ :auth_names => auth_names,
179
+ :return_type => 'BarcodeResponseList')
180
+ if Configuration.debugging
181
+ Configuration.logger.debug "API called: BarcodeApi#post_barcode_recognize_from_urlor_content. Result: #{result.inspect}"
182
+ end
183
+ return result
184
+ end
185
+
186
+ # Generate barcode and save on server.
187
+ #
188
+ # @param name The image name.
189
+ # @param [Hash] opts the optional parameters
190
+ # @option opts [String] :text Barcode&#39;s text.
191
+ # @option opts [String] :type The barcode type.
192
+ # @option opts [String] :format The image format.
193
+ # @option opts [Float] :resolution_x Horizontal resolution.
194
+ # @option opts [Float] :resolution_y Vertical resolution.
195
+ # @option opts [Float] :dimension_x Smallest width of barcode unit (bar or space).
196
+ # @option opts [Float] :dimension_y Smallest height of barcode unit (for 2D barcodes).
197
+ # @option opts [String] :code_location {CodeLocation} property of the barcode.
198
+ # @option opts [String] :gr_unit Measurement of barcode properties.
199
+ # @option opts [String] :auto_size Sets if barcode size will be updated automatically.
200
+ # @option opts [Float] :bar_height Height of the bar.
201
+ # @option opts [Float] :image_height Height of the image.
202
+ # @option opts [Float] :image_width Width of the image.
203
+ # @option opts [String] :image_quality Detepmines {ImageQualityMode} of the barcode image.
204
+ # @option opts [Float] :rot_angle Angle of barcode orientation.
205
+ # @option opts [Float] :top_margin Top margin.
206
+ # @option opts [Float] :bottom_margin Bottom margin.
207
+ # @option opts [Float] :left_margin Left margin.
208
+ # @option opts [Float] :right_margin Right margin.
209
+ # @option opts [String] :enable_checksum Sets if checksum will be generated.
210
+ # @option opts [String] :storage Image&#39;s storage.
211
+ # @option opts [String] :folder Image&#39;s folder.
212
+ # @option opts [File] :file
213
+ # @return [BaseResponse]
214
+ def put_barcode_generate_file(name, opts = {})
215
+ if Configuration.debugging
216
+ Configuration.logger.debug "Calling API: BarcodeApi#put_barcode_generate_file ..."
217
+ end
218
+
219
+ # verify the required parameter 'name' is set
220
+ fail "Missing the required parameter 'name' when calling put_barcode_generate_file" if name.nil?
221
+
222
+ # resource path
223
+ path = "/barcode/{name}/generate".sub('{format}','json').sub('{' + 'name' + '}', name.to_s)
224
+
225
+ # query parameters
226
+ query_params = {}
227
+ query_params[:'text'] = opts[:'text'] if opts[:'text']
228
+ query_params[:'type'] = opts[:'type'] if opts[:'type']
229
+ query_params[:'format'] = opts[:'format'] if opts[:'format']
230
+ query_params[:'resolutionX'] = opts[:'resolution_x'] if opts[:'resolution_x']
231
+ query_params[:'resolutionY'] = opts[:'resolution_y'] if opts[:'resolution_y']
232
+ query_params[:'dimensionX'] = opts[:'dimension_x'] if opts[:'dimension_x']
233
+ query_params[:'dimensionY'] = opts[:'dimension_y'] if opts[:'dimension_y']
234
+ query_params[:'codeLocation'] = opts[:'code_location'] if opts[:'code_location']
235
+ query_params[:'grUnit'] = opts[:'gr_unit'] if opts[:'gr_unit']
236
+ query_params[:'autoSize'] = opts[:'auto_size'] if opts[:'auto_size']
237
+ query_params[:'barHeight'] = opts[:'bar_height'] if opts[:'bar_height']
238
+ query_params[:'imageHeight'] = opts[:'image_height'] if opts[:'image_height']
239
+ query_params[:'imageWidth'] = opts[:'image_width'] if opts[:'image_width']
240
+ query_params[:'imageQuality'] = opts[:'image_quality'] if opts[:'image_quality']
241
+ query_params[:'rotAngle'] = opts[:'rot_angle'] if opts[:'rot_angle']
242
+ query_params[:'topMargin'] = opts[:'top_margin'] if opts[:'top_margin']
243
+ query_params[:'bottomMargin'] = opts[:'bottom_margin'] if opts[:'bottom_margin']
244
+ query_params[:'leftMargin'] = opts[:'left_margin'] if opts[:'left_margin']
245
+ query_params[:'rightMargin'] = opts[:'right_margin'] if opts[:'right_margin']
246
+ query_params[:'enableChecksum'] = opts[:'enable_checksum'] if opts[:'enable_checksum']
247
+ query_params[:'storage'] = opts[:'storage'] if opts[:'storage']
248
+ query_params[:'folder'] = opts[:'folder'] if opts[:'folder']
249
+
250
+ # header parameters
251
+ header_params = {}
252
+
253
+ # HTTP header 'Accept' (if needed)
254
+ _header_accept = ['application/json']
255
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
256
+
257
+ # HTTP header 'Content-Type'
258
+ _header_content_type = []
259
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
260
+
261
+ # form parameters
262
+ form_params = {}
263
+ form_params["file"] = opts[:'file'] if opts[:'file']
264
+
265
+ # http body (model)
266
+ post_body = nil
267
+
268
+
269
+ auth_names = []
270
+ result = @api_client.call_api(:PUT, path,
271
+ :header_params => header_params,
272
+ :query_params => query_params,
273
+ :form_params => form_params,
274
+ :body => post_body,
275
+ :auth_names => auth_names,
276
+ :return_type => 'BaseResponse')
277
+ if Configuration.debugging
278
+ Configuration.logger.debug "API called: BarcodeApi#put_barcode_generate_file. Result: #{result.inspect}"
279
+ end
280
+ return result
281
+ end
282
+
283
+ # Generate image with multiple barcodes and put new file on server
284
+ #
285
+ # @param name New filename
286
+ # @param dto List of barcodes
287
+ # @param [Hash] opts the optional parameters
288
+ # @option opts [String] :format Format of file
289
+ # @option opts [String] :folder Folder to place file to
290
+ # @return [BaseResponse]
291
+ def put_generate_multiple(name, dto, opts = {})
292
+ if Configuration.debugging
293
+ Configuration.logger.debug "Calling API: BarcodeApi#put_generate_multiple ..."
294
+ end
295
+
296
+ # verify the required parameter 'name' is set
297
+ fail "Missing the required parameter 'name' when calling put_generate_multiple" if name.nil?
298
+
299
+ # verify the required parameter 'dto' is set
300
+ fail "Missing the required parameter 'dto' when calling put_generate_multiple" if dto.nil?
301
+
302
+ # resource path
303
+ path = "/barcode/{name}/generateMultiple".sub('{format}','json').sub('{' + 'name' + '}', name.to_s)
304
+
305
+ # query parameters
306
+ query_params = {}
307
+ query_params[:'format'] = opts[:'format'] if opts[:'format']
308
+ query_params[:'folder'] = opts[:'folder'] if opts[:'folder']
309
+
310
+ # header parameters
311
+ header_params = {}
312
+
313
+ # HTTP header 'Accept' (if needed)
314
+ _header_accept = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript']
315
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
316
+
317
+ # HTTP header 'Content-Type'
318
+ _header_content_type = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript', 'application/x-www-form-urlencoded']
319
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
320
+
321
+ # form parameters
322
+ form_params = {}
323
+
324
+ # http body (model)
325
+ post_body = @api_client.object_to_http_body(dto)
326
+
327
+
328
+ auth_names = []
329
+ result = @api_client.call_api(:PUT, path,
330
+ :header_params => header_params,
331
+ :query_params => query_params,
332
+ :form_params => form_params,
333
+ :body => post_body,
334
+ :auth_names => auth_names,
335
+ :return_type => 'BaseResponse')
336
+ if Configuration.debugging
337
+ Configuration.logger.debug "API called: BarcodeApi#put_generate_multiple. Result: #{result.inspect}"
338
+ end
339
+ return result
340
+ end
341
+
342
+ # Recognize barcode from a file on server.
343
+ #
344
+ # @param name The image name.
345
+ # @param [Hash] opts the optional parameters
346
+ # @option opts [String] :type The barcode type.
347
+ # @option opts [String] :checksum_validation Checksum validation parameter.
348
+ # @option opts [BOOLEAN] :strip_fnc Allows to strip FNC symbol in recognition results.
349
+ # @option opts [Integer] :rotation_angle Allows to correct angle of barcode.
350
+ # @option opts [Integer] :barcodes_count Count of barcodes to recognize.
351
+ # @option opts [Integer] :rect_x Top left point X coordinate of {System.Drawing.Rectangle} to recognize barcode inside.
352
+ # @option opts [Integer] :rect_y Top left point Y coordinate of {System.Drawing.Rectangle} to recognize barcode inside.
353
+ # @option opts [Integer] :rect_width Width of {System.Drawing.Rectangle} to recognize barcode inside.
354
+ # @option opts [Integer] :rect_height Height of {System.Drawing.Rectangle} to recognize barcode inside.
355
+ # @option opts [String] :storage The image storage.
356
+ # @option opts [String] :folder The image folder.
357
+ # @return [BarcodeResponseList]
358
+ def get_barcode_recognize(name, opts = {})
359
+ if Configuration.debugging
360
+ Configuration.logger.debug "Calling API: BarcodeApi#get_barcode_recognize ..."
361
+ end
362
+
363
+ # verify the required parameter 'name' is set
364
+ fail "Missing the required parameter 'name' when calling get_barcode_recognize" if name.nil?
365
+
366
+ # resource path
367
+ path = "/barcode/{name}/recognize".sub('{format}','json').sub('{' + 'name' + '}', name.to_s)
368
+
369
+ # query parameters
370
+ query_params = {}
371
+ query_params[:'type'] = opts[:'type'] if opts[:'type']
372
+ query_params[:'checksumValidation'] = opts[:'checksum_validation'] if opts[:'checksum_validation']
373
+ query_params[:'stripFnc'] = opts[:'strip_fnc'] if opts[:'strip_fnc']
374
+ query_params[:'rotationAngle'] = opts[:'rotation_angle'] if opts[:'rotation_angle']
375
+ query_params[:'barcodesCount'] = opts[:'barcodes_count'] if opts[:'barcodes_count']
376
+ query_params[:'rectX'] = opts[:'rect_x'] if opts[:'rect_x']
377
+ query_params[:'rectY'] = opts[:'rect_y'] if opts[:'rect_y']
378
+ query_params[:'rectWidth'] = opts[:'rect_width'] if opts[:'rect_width']
379
+ query_params[:'rectHeight'] = opts[:'rect_height'] if opts[:'rect_height']
380
+ query_params[:'storage'] = opts[:'storage'] if opts[:'storage']
381
+ query_params[:'folder'] = opts[:'folder'] if opts[:'folder']
382
+
383
+ # header parameters
384
+ header_params = {}
385
+
386
+ # HTTP header 'Accept' (if needed)
387
+ _header_accept = ['application/json']
388
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
389
+
390
+ # HTTP header 'Content-Type'
391
+ _header_content_type = []
392
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
393
+
394
+ # form parameters
395
+ form_params = {}
396
+
397
+ # http body (model)
398
+ post_body = nil
399
+
400
+
401
+ auth_names = []
402
+ result = @api_client.call_api(:GET, path,
403
+ :header_params => header_params,
404
+ :query_params => query_params,
405
+ :form_params => form_params,
406
+ :body => post_body,
407
+ :auth_names => auth_names,
408
+ :return_type => 'BarcodeResponseList')
409
+ if Configuration.debugging
410
+ Configuration.logger.debug "API called: BarcodeApi#get_barcode_recognize. Result: #{result.inspect}"
411
+ end
412
+ return result
413
+ end
414
+
415
+ # Recognition of a barcode from file on server with parameters in body.
416
+ #
417
+ # @param name The image name.
418
+ # @param barcode_reader BarcodeReader object with parameters.
419
+ # @param [Hash] opts the optional parameters
420
+ # @option opts [String] :type The barcode type.
421
+ # @option opts [String] :folder The image folder.
422
+ # @return [BarcodeResponseList]
423
+ def put_barcode_recognize_from_body(name, barcode_reader, opts = {})
424
+ if Configuration.debugging
425
+ Configuration.logger.debug "Calling API: BarcodeApi#put_barcode_recognize_from_body ..."
426
+ end
427
+
428
+ # verify the required parameter 'name' is set
429
+ fail "Missing the required parameter 'name' when calling put_barcode_recognize_from_body" if name.nil?
430
+
431
+ # verify the required parameter 'barcode_reader' is set
432
+ fail "Missing the required parameter 'barcode_reader' when calling put_barcode_recognize_from_body" if barcode_reader.nil?
433
+
434
+ # resource path
435
+ path = "/barcode/{name}/recognize".sub('{format}','json').sub('{' + 'name' + '}', name.to_s)
436
+
437
+ # query parameters
438
+ query_params = {}
439
+ query_params[:'type'] = opts[:'type'] if opts[:'type']
440
+ query_params[:'folder'] = opts[:'folder'] if opts[:'folder']
441
+
442
+ # header parameters
443
+ header_params = {}
444
+
445
+ # HTTP header 'Accept' (if needed)
446
+ _header_accept = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript']
447
+ _header_accept_result = @api_client.select_header_accept(_header_accept) and header_params['Accept'] = _header_accept_result
448
+
449
+ # HTTP header 'Content-Type'
450
+ _header_content_type = ['application/json', 'text/json', 'application/xml', 'text/xml', 'text/javascript', 'application/x-www-form-urlencoded']
451
+ header_params['Content-Type'] = @api_client.select_header_content_type(_header_content_type)
452
+
453
+ # form parameters
454
+ form_params = {}
455
+
456
+ # http body (model)
457
+ post_body = @api_client.object_to_http_body(barcode_reader)
458
+
459
+
460
+ auth_names = []
461
+ result = @api_client.call_api(:PUT, path,
462
+ :header_params => header_params,
463
+ :query_params => query_params,
464
+ :form_params => form_params,
465
+ :body => post_body,
466
+ :auth_names => auth_names,
467
+ :return_type => 'BarcodeResponseList')
468
+ if Configuration.debugging
469
+ Configuration.logger.debug "API called: BarcodeApi#put_barcode_recognize_from_body. Result: #{result.inspect}"
470
+ end
471
+ return result
472
+ end
473
+ end
474
+ end
475
+
476
+
477
+
478
+