aspose_barcode_cloud 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f03ae67f3d87a05e9ded1449fd28beb402a259ca
4
- data.tar.gz: d03b5121ed7eb1e31ab196fb75d9444deb77bea3
3
+ metadata.gz: c49e9b255b976761ddedd8916fb7482ac877229d
4
+ data.tar.gz: 474f353749869a53a720ddb17c705f02adfc3449
5
5
  SHA512:
6
- metadata.gz: e636ede453ec47533644835cd58e993525670c5b455334d1ab903d3e6283ff23eff50f61619b422e0ffa4abbfac7871edce3c1d89e8df8861d6722e64f58fb73
7
- data.tar.gz: 6a16b8b607438c97ef9e22d7acacbe06e9a3bc9d225d80cab3781b123b6d7f94bbf93409bb7a9a91a6f2b90498cfc2ca2c139fb2b8701d07d55b21a8d64ab10e
6
+ metadata.gz: 1ba01d95317e0e34dde4732b604a552b9fed64eaf53b061221c6e42356d891c2b65d2d05203de3e18d054d70da2d7b8e4395123ebd997d157cce9e6ea59c5204
7
+ data.tar.gz: a64d23341f1a89ceb6b085714e0415fc192fe1652fe6c04cab9c79f8c0f299211fbb7c1f65a37f135855caeb19a14f6dfbc164ccb343dfd88a3903261d662fb1
data/README.md CHANGED
@@ -1,42 +1,41 @@
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.
1
+ # Aspose.BarCode Cloud SDK For Ruby
2
+ This SDK lets you use [Aspose Cloud Barcode APIs](http://www.aspose.com/cloud/barcode-api.aspx) in your Ruby web apps.
3
3
 
4
4
  ## Installing
5
- You can simply install Aspose Slides Cloud SDK with gem:
5
+ You can simply install Aspose Barcode Cloud SDK with gem:
6
6
 
7
- `gem install aspose_slides_cloud`
7
+ `gem install aspose_barcode_cloud`
8
8
 
9
9
  ## Usage
10
10
  APIs of this SDK can be called as follows:
11
11
 
12
12
  ```ruby
13
- require 'aspose_slides_cloud'
13
+ require 'aspose_barcode_cloud'
14
14
 
15
- class SlidesUsage
15
+ class BarcodeUsage
16
16
 
17
- include AsposeSlidesCloud
17
+ include AsposeBarcodeCloud
18
18
  include AsposeStorageCloud
19
19
 
20
20
  def initialize
21
21
  #Get App key and App SID from https://cloud.aspose.com
22
22
  AsposeApp.app_key_and_sid("APP_KEY", "APP_SID")
23
- @slides_api = SlidesApi.new
23
+ @barcode_api = BarcodeApi.new
24
24
  end
25
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})
26
+ def get_barcode_generate
27
+ #Generate barcode.
28
+ opts = {text: "Dairy Products", type: "qr", format: "png"}
29
+ response = @barcode_api.get_barcode_generate(opts)
31
30
  end
32
31
 
33
32
  end
34
33
  ```
35
34
  ## 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.
35
+ Aspose Barcode SDK includes a suite of unit tests within the [test](https://github.com/asposebarcode/Aspose_BarCode_Cloud/blob/master/SDKs/Aspose.BarCode_Cloud_SDK_for_Ruby/test/barcode_tests.rb) subdirectory. These Unit Tests also serves as examples of how to use the Aspose Barcode SDK.
37
36
 
38
37
  ## Contact
39
38
  Your feedback is very important to us. Please email us all your queries and feedback at marketplace@aspose.com.
40
39
 
41
40
  ## 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.
41
+ Aspose Barcode SDK is available under the MIT license. See the [LICENSE](https://github.com/asposebarcode/Aspose_BarCode_Cloud/blob/master/SDKs/Aspose.BarCode_Cloud_SDK_for_Ruby/LICENSE) file for more info.
@@ -1,3 +1,3 @@
1
1
  module AsposeBarcodeCloud
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
@@ -9,95 +9,95 @@ class BarcodeTests < Minitest::Test
9
9
  include AsposeStorageCloud
10
10
 
11
11
  def setup
12
- #Get App key and App SID from https://cloud.aspose.com
13
- AsposeApp.app_key_and_sid("53b8b19adffa41a3e87dbbd8858977ae", "0B17F60A-6D69-426B-9ABD-79F35A6E9F7B")
14
- @barcode_api = BarcodeApi.new
12
+ #Get App key and App SID from https://cloud.aspose.com
13
+ AsposeApp.app_key_and_sid("", "")
14
+ @barcode_api = BarcodeApi.new
15
15
  end
16
16
 
17
17
  def teardown
18
18
  end
19
19
 
20
20
  def upload_file(file_name)
21
- @storage_api = StorageApi.new
22
- response = @storage_api.put_create(file_name, File.open("data/" << file_name,"r") { |io| io.read } )
23
- assert(response, message="Failed to upload {file_name} file.")
21
+ @storage_api = StorageApi.new
22
+ response = @storage_api.put_create(file_name, File.open("data/" << file_name,"r") { |io| io.read } )
23
+ assert(response, message="Failed to upload {file_name} file.")
24
24
  end
25
25
 
26
26
  def test_get_barcode_generate
27
- opts = {text: "Dairy Products", type: "qr", format: "png"}
27
+ opts = {text: "Dairy Products", type: "qr", format: "png"}
28
28
 
29
- response = @barcode_api.get_barcode_generate(opts)
30
- assert(response, message="Failed to generate barcode")
29
+ response = @barcode_api.get_barcode_generate(opts)
30
+ assert(response, message="Failed to generate barcode")
31
31
  end
32
32
 
33
33
  def test_post_generate_multiple
34
- barcode_builders_list = BarcodeBuildersList.new
35
- barcode_builders_list.x_step = 1
36
- barcode_builders_list.y_step = 2
37
- barcode_builder_1 = BarcodeBuilder.new
38
- barcode_builder_1.type_of_barcode = "qr"
39
- barcode_builder_1.text = "Aspose Your File Format APIs"
40
- barcode_builder_2 = BarcodeBuilder.new
41
- barcode_builder_2.type_of_barcode = "qr"
42
- barcode_builder_2.text = "Aspose.Barcode for Cloud"
43
- barcode_builders_list.barcode_builders = [barcode_builder_1, barcode_builder_2]
44
- opts = {format: "png"}
45
-
46
- response = @barcode_api.post_generate_multiple(barcode_builders_list, opts)
47
- assert(response, message="Failed to generate multiple barcodes and return in response stream")
34
+ barcode_builders_list = BarcodeBuildersList.new
35
+ barcode_builders_list.x_step = 1
36
+ barcode_builders_list.y_step = 2
37
+ barcode_builder_1 = BarcodeBuilder.new
38
+ barcode_builder_1.type_of_barcode = "qr"
39
+ barcode_builder_1.text = "Aspose Your File Format APIs"
40
+ barcode_builder_2 = BarcodeBuilder.new
41
+ barcode_builder_2.type_of_barcode = "qr"
42
+ barcode_builder_2.text = "Aspose.Barcode for Cloud"
43
+ barcode_builders_list.barcode_builders = [barcode_builder_1, barcode_builder_2]
44
+ opts = {format: "png"}
45
+
46
+ response = @barcode_api.post_generate_multiple(barcode_builders_list, opts)
47
+ assert(response, message="Failed to generate multiple barcodes and return in response stream")
48
48
  end
49
49
 
50
50
  def test_post_barcode_recognize_from_urlor_content
51
- opts = {type: "Code39Standard", url: "http://www.barcoding.com/images/Barcodes/code93.gif"}
51
+ opts = {type: "Code39Standard", url: "http://www.barcoding.com/images/Barcodes/code93.gif"}
52
52
 
53
- response = @barcode_api.post_barcode_recognize_from_urlor_content(opts)
54
- assert(response, message="Failed to recognize barcode from an url.")
53
+ response = @barcode_api.post_barcode_recognize_from_urlor_content(opts)
54
+ assert(response, message="Failed to recognize barcode from an url.")
55
55
  end
56
56
 
57
57
  def test_put_barcode_generate_file
58
- name = "NewBarcode.png"
59
- opts = {text: "Aspose.Barcode for Cloud", type: "qr"}
58
+ name = "NewBarcode.png"
59
+ opts = {text: "Aspose.Barcode for Cloud", type: "qr"}
60
60
 
61
- response = @barcode_api.put_barcode_generate_file(name, opts)
62
- assert(response, message="Failed to generate barcode and save on server.")
61
+ response = @barcode_api.put_barcode_generate_file(name, opts)
62
+ assert(response, message="Failed to generate barcode and save on server.")
63
63
  end
64
64
 
65
65
  def test_put_generate_multiple
66
- name = "AsposeBarcode.png"
67
- barcode_builders_list = BarcodeBuildersList.new
68
- barcode_builders_list.x_step = 1
69
- barcode_builders_list.y_step = 2
70
- barcode_builder_1 = BarcodeBuilder.new
71
- barcode_builder_1.type_of_barcode = "qr"
72
- barcode_builder_1.text = "Aspose Your File Format APIs"
73
- barcode_builder_2 = BarcodeBuilder.new
74
- barcode_builder_2.type_of_barcode = "qr"
75
- barcode_builder_2.text = "Aspose.Barcode for Cloud"
76
- barcode_builders_list.barcode_builders = [barcode_builder_1, barcode_builder_2]
77
-
78
- response = @barcode_api.put_generate_multiple(name, barcode_builders_list)
79
- assert(response, message="Failed to generate image with multiple barcodes and put new file on server")
66
+ name = "AsposeBarcode.png"
67
+ barcode_builders_list = BarcodeBuildersList.new
68
+ barcode_builders_list.x_step = 1
69
+ barcode_builders_list.y_step = 2
70
+ barcode_builder_1 = BarcodeBuilder.new
71
+ barcode_builder_1.type_of_barcode = "qr"
72
+ barcode_builder_1.text = "Aspose Your File Format APIs"
73
+ barcode_builder_2 = BarcodeBuilder.new
74
+ barcode_builder_2.type_of_barcode = "qr"
75
+ barcode_builder_2.text = "Aspose.Barcode for Cloud"
76
+ barcode_builders_list.barcode_builders = [barcode_builder_1, barcode_builder_2]
77
+
78
+ response = @barcode_api.put_generate_multiple(name, barcode_builders_list)
79
+ assert(response, message="Failed to generate image with multiple barcodes and put new file on server")
80
80
  end
81
81
 
82
82
  def test_get_barcode_recognize
83
- file_name = "barcode.png"
84
- upload_file(file_name)
85
- opts = {type: "Code39Standard"}
83
+ file_name = "barcode.png"
84
+ upload_file(file_name)
85
+ opts = {type: "Code39Standard"}
86
86
 
87
- response = @barcode_api.get_barcode_recognize(file_name, opts)
88
- assert(response, message="Failed to recognize barcode from a file on server.")
87
+ response = @barcode_api.get_barcode_recognize(file_name, opts)
88
+ assert(response, message="Failed to recognize barcode from a file on server.")
89
89
  end
90
90
 
91
91
  def test_put_barcode_recognize_from_body
92
- file_name = "sample-barcode.jpeg"
93
- upload_file(file_name)
94
- barcode_reader = BarcodeReader.new
95
- barcode_reader.strip_fnc = true
96
- barcode_reader.checksum_validation = "Off"
97
- opts = {type: "Code39Standard"}
98
-
99
- response = @barcode_api.put_barcode_recognize_from_body(file_name, barcode_reader, opts)
100
- assert(response, message="Failed to recognize barcode from file on server with parameters in body.")
92
+ file_name = "sample-barcode.jpeg"
93
+ upload_file(file_name)
94
+ barcode_reader = BarcodeReader.new
95
+ barcode_reader.strip_fnc = true
96
+ barcode_reader.checksum_validation = "Off"
97
+ opts = {type: "Code39Standard"}
98
+
99
+ response = @barcode_api.put_barcode_recognize_from_body(file_name, barcode_reader, opts)
100
+ assert(response, message="Failed to recognize barcode from file on server with parameters in body.")
101
101
  end
102
102
 
103
- end
103
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aspose_barcode_cloud
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - M. Sohail Ismail