aspose_pdf_cloud 23.7.0 → 23.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -7
- data/docs/PdfApi.md +39 -0
- data/lib/aspose_pdf_cloud/api/pdf_api.rb +119 -0
- data/lib/aspose_pdf_cloud/version.rb +1 -1
- data/test/pdf_tests.rb +14 -4
- data/test_data/PdfWithImages.pdf +0 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8326de7f92b83f2cecd37acd2ac707f0eff033241020811183cbfcc061409612
|
4
|
+
data.tar.gz: 0d81993338b094970035d2fc95bd2b6e39b4a79d60bc61764ebd01bd56ed87fc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1d67a280e8a64f1e7947e3717134857104cf4764bc99a8170ad7089f61194bf6808330660ab8ed6b581e553ec0dc12f0c1ff26652c9ab6511ffbc6b36d54ff3c
|
7
|
+
data.tar.gz: 4dd4dd021d971971f2954fa7e6edccf14177f7ebb58fdd9837d117ceafc964711ff0d73ed1e2ef60af9acb9d42cc6a83141e487d7e3951d2ccf6b2ccc8cefddb
|
data/README.md
CHANGED
@@ -29,12 +29,13 @@ XLS, XLSX, PPTX, DOC, DOCX, MobiXML, JPEG, EMF, PNG, BMP, GIF, TIFF, Text
|
|
29
29
|
## Read PDF Formats
|
30
30
|
MHT, PCL, PS, XSLFO, MD
|
31
31
|
|
32
|
-
## Enhancements in Version 23.
|
33
|
-
-
|
32
|
+
## Enhancements in Version 23.9
|
33
|
+
- Support to convert password protected PDF documents to PDFA.
|
34
34
|
- A new version of Aspose.PDF Cloud was prepared using the latest version of Aspose.PDF for .NET.
|
35
35
|
|
36
|
-
## Bugs fixed in Version 23.
|
37
|
-
-
|
36
|
+
## Bugs fixed in Version 23.9
|
37
|
+
- Rotate Property not working with FreeTextAnnotation.
|
38
|
+
- PutAnnotationsFlatten not working correctly when passing multiple annotation types.
|
38
39
|
|
39
40
|
## Installation
|
40
41
|
|
@@ -49,15 +50,15 @@ gem build aspose_pdf_cloud.gemspec
|
|
49
50
|
Then either install the gem locally:
|
50
51
|
|
51
52
|
```shell
|
52
|
-
gem install ./aspose_pdf_cloud-23.
|
53
|
+
gem install ./aspose_pdf_cloud-23.9.0.gem
|
53
54
|
```
|
54
|
-
(for development, run `gem install --dev ./aspose_pdf_cloud-23.
|
55
|
+
(for development, run `gem install --dev ./aspose_pdf_cloud-23.9.0.gem` to install the development dependencies)
|
55
56
|
|
56
57
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
57
58
|
|
58
59
|
Finally add this to the Gemfile:
|
59
60
|
|
60
|
-
gem 'aspose_pdf_cloud', '~> 23.
|
61
|
+
gem 'aspose_pdf_cloud', '~> 23.9.0'
|
61
62
|
|
62
63
|
### Install from Git
|
63
64
|
|
data/docs/PdfApi.md
CHANGED
@@ -336,6 +336,7 @@ Method | HTTP request | Description
|
|
336
336
|
[**put_radio_button_field**](PdfApi.md#put_radio_button_field) | **PUT** /pdf/\{name}/fields/radiobutton/\{fieldName} | Replace document RadioButton field
|
337
337
|
[**put_redaction_annotation**](PdfApi.md#put_redaction_annotation) | **PUT** /pdf/\{name}/annotations/redaction/\{annotationId} | Replace document redaction annotation
|
338
338
|
[**put_replace_image**](PdfApi.md#put_replace_image) | **PUT** /pdf/\{name}/images/\{imageId} | Replace document image.
|
339
|
+
[**put_replace_multiple_image**](PdfApi.md#put_replace_multiple_image) | **PUT** /pdf/\{name}/images/replace | Replace document multiple image.
|
339
340
|
[**put_screen_annotation**](PdfApi.md#put_screen_annotation) | **PUT** /pdf/\{name}/annotations/screen/\{annotationId} | Replace document screen annotation
|
340
341
|
[**put_screen_annotation_data_extract**](PdfApi.md#put_screen_annotation_data_extract) | **PUT** /pdf/\{name}/annotations/screen/\{annotationId}/data/extract | Extract document screen annotation content to storage
|
341
342
|
[**put_searchable_document**](PdfApi.md#put_searchable_document) | **PUT** /pdf/\{name}/ocr | Create searchable PDF document. Generate OCR layer for images in input PDF document.
|
@@ -4014,6 +4015,7 @@ Name | Type | Description | Notes
|
|
4014
4015
|
**type** | **String**| Type of PdfA format. |
|
4015
4016
|
**folder** | **String**| The document folder. | [optional]
|
4016
4017
|
**storage** | **String**| The document storage. | [optional]
|
4018
|
+
**password** | **String**| The password (Base64). | [optional]
|
4017
4019
|
|
4018
4020
|
### Return type
|
4019
4021
|
|
@@ -4157,6 +4159,7 @@ Name | Type | Description | Notes
|
|
4157
4159
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
4158
4160
|
**folder** | **String**| The document folder. | [optional]
|
4159
4161
|
**storage** | **String**| The document storage. | [optional]
|
4162
|
+
**password** | **String**| The password (Base64). | [optional]
|
4160
4163
|
|
4161
4164
|
### Return type
|
4162
4165
|
|
@@ -4185,6 +4188,7 @@ Name | Type | Description | Notes
|
|
4185
4188
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
4186
4189
|
**folder** | **String**| The document folder. | [optional]
|
4187
4190
|
**storage** | **String**| The document storage. | [optional]
|
4191
|
+
**password** | **String**| The password (Base64). | [optional]
|
4188
4192
|
|
4189
4193
|
### Return type
|
4190
4194
|
|
@@ -6550,6 +6554,7 @@ Name | Type | Description | Notes
|
|
6550
6554
|
**to** | **Integer**| End page if defined. | [optional]
|
6551
6555
|
**storage** | **String**| The document storage. | [optional]
|
6552
6556
|
**folder** | **String**| The document folder. | [optional]
|
6557
|
+
**password** | **String**| Base64 encoded password. | [optional]
|
6553
6558
|
|
6554
6559
|
### Return type
|
6555
6560
|
|
@@ -6575,6 +6580,7 @@ Name | Type | Description | Notes
|
|
6575
6580
|
**options** | [**SplitRangePdfOptions**](SplitRangePdfOptions.md)| The splitting options. |
|
6576
6581
|
**storage** | **String**| The document storage. | [optional]
|
6577
6582
|
**folder** | **String**| The document folder. | [optional]
|
6583
|
+
**password** | **String**| Base64 encoded password. | [optional]
|
6578
6584
|
|
6579
6585
|
### Return type
|
6580
6586
|
|
@@ -8138,6 +8144,7 @@ Name | Type | Description | Notes
|
|
8138
8144
|
**out_path** | **String**| Full resulting filename (ex. /folder1/folder2/result.pdf) |
|
8139
8145
|
**type** | **String**| Type of PdfA format. |
|
8140
8146
|
**storage** | **String**| The document storage. | [optional]
|
8147
|
+
**password** | **String**| The password (Base64). | [optional]
|
8141
8148
|
**file** | **File**| A file to be converted. | [optional]
|
8142
8149
|
|
8143
8150
|
### Return type
|
@@ -8280,6 +8287,7 @@ Name | Type | Description | Notes
|
|
8280
8287
|
**scale_factor** | **Float**| Scale factor (Obsolete) | [optional]
|
8281
8288
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
8282
8289
|
**storage** | **String**| The document storage. | [optional]
|
8290
|
+
**password** | **String**| The password (Base64). | [optional]
|
8283
8291
|
**file** | **File**| A file to be converted. | [optional]
|
8284
8292
|
|
8285
8293
|
### Return type
|
@@ -8308,6 +8316,7 @@ Name | Type | Description | Notes
|
|
8308
8316
|
**scale_factor** | **Float**| Scale factor (Obsolete) | [optional]
|
8309
8317
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
8310
8318
|
**storage** | **String**| The document storage. | [optional]
|
8319
|
+
**password** | **String**| The password (Base64). | [optional]
|
8311
8320
|
**file** | **File**| A file to be converted. | [optional]
|
8312
8321
|
|
8313
8322
|
### Return type
|
@@ -8523,6 +8532,7 @@ Name | Type | Description | Notes
|
|
8523
8532
|
**type** | **String**| Type of PdfA format. |
|
8524
8533
|
**folder** | **String**| The document folder. | [optional]
|
8525
8534
|
**storage** | **String**| The document storage. | [optional]
|
8535
|
+
**password** | **String**| The password (Base64). | [optional]
|
8526
8536
|
|
8527
8537
|
### Return type
|
8528
8538
|
|
@@ -8670,6 +8680,7 @@ Name | Type | Description | Notes
|
|
8670
8680
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
8671
8681
|
**folder** | **String**| The document folder. | [optional]
|
8672
8682
|
**storage** | **String**| The document storage. | [optional]
|
8683
|
+
**password** | **String**| The password (Base64). | [optional]
|
8673
8684
|
|
8674
8685
|
### Return type
|
8675
8686
|
|
@@ -8699,6 +8710,7 @@ Name | Type | Description | Notes
|
|
8699
8710
|
**uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
|
8700
8711
|
**folder** | **String**| The document folder. | [optional]
|
8701
8712
|
**storage** | **String**| The document storage. | [optional]
|
8713
|
+
**password** | **String**| The password (Base64). | [optional]
|
8702
8714
|
|
8703
8715
|
### Return type
|
8704
8716
|
|
@@ -8969,6 +8981,33 @@ Name | Type | Description | Notes
|
|
8969
8981
|
|
8970
8982
|
|
8971
8983
|
|
8984
|
+
# **put_replace_multiple_image**
|
8985
|
+
> ImagesResponse put_replace_multiple_image(name, image_ids, opts)
|
8986
|
+
|
8987
|
+
Replace document multiple image.
|
8988
|
+
|
8989
|
+
### Parameters
|
8990
|
+
|
8991
|
+
Name | Type | Description | Notes
|
8992
|
+
------------- | ------------- | ------------- | -------------
|
8993
|
+
**name** | **String**| The document name. |
|
8994
|
+
**image_ids** | **Array<String>**| The image IDs. |
|
8995
|
+
**image_file_path** | **String**| Path to image file if specified. Request content is used otherwise. | [optional]
|
8996
|
+
**storage** | **String**| The document storage. | [optional]
|
8997
|
+
**folder** | **String**| The document folder. | [optional]
|
8998
|
+
**image** | **File**| Image file. | [optional]
|
8999
|
+
|
9000
|
+
### Return type
|
9001
|
+
|
9002
|
+
[**ImagesResponse**](ImagesResponse.md)
|
9003
|
+
|
9004
|
+
### HTTP request headers
|
9005
|
+
|
9006
|
+
- **Content-Type**: multipart/form-data
|
9007
|
+
- **Accept**: application/json
|
9008
|
+
|
9009
|
+
|
9010
|
+
|
8972
9011
|
# **put_screen_annotation**
|
8973
9012
|
> ScreenAnnotationResponse put_screen_annotation(name, annotation_id, annotation, opts)
|
8974
9013
|
|
@@ -11248,6 +11248,7 @@ module AsposePdfCloud
|
|
11248
11248
|
# @param [Hash] opts the optional parameters
|
11249
11249
|
# @option opts [String] :folder The document folder.
|
11250
11250
|
# @option opts [String] :storage The document storage.
|
11251
|
+
# @option opts [String] :password The password (Base64).
|
11251
11252
|
# @return [File]
|
11252
11253
|
def get_pdf_in_storage_to_pdf_a(name, type, opts = {})
|
11253
11254
|
@api_client.request_token_if_needed
|
@@ -11269,6 +11270,7 @@ module AsposePdfCloud
|
|
11269
11270
|
# @param [Hash] opts the optional parameters
|
11270
11271
|
# @option opts [String] :folder The document folder.
|
11271
11272
|
# @option opts [String] :storage The document storage.
|
11273
|
+
# @option opts [String] :password The password (Base64).
|
11272
11274
|
# @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers
|
11273
11275
|
def get_pdf_in_storage_to_pdf_a_with_http_info(name, type, opts = {})
|
11274
11276
|
if @api_client.config.debugging
|
@@ -11294,6 +11296,7 @@ module AsposePdfCloud
|
|
11294
11296
|
query_params[:'type'] = type
|
11295
11297
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
11296
11298
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
11299
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
11297
11300
|
|
11298
11301
|
# header parameters
|
11299
11302
|
header_params = {}
|
@@ -11688,6 +11691,7 @@ module AsposePdfCloud
|
|
11688
11691
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
11689
11692
|
# @option opts [String] :folder The document folder.
|
11690
11693
|
# @option opts [String] :storage The document storage.
|
11694
|
+
# @option opts [String] :password The password (Base64).
|
11691
11695
|
# @return [File]
|
11692
11696
|
def get_pdf_in_storage_to_xls(name, opts = {})
|
11693
11697
|
@api_client.request_token_if_needed
|
@@ -11712,6 +11716,7 @@ module AsposePdfCloud
|
|
11712
11716
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
11713
11717
|
# @option opts [String] :folder The document folder.
|
11714
11718
|
# @option opts [String] :storage The document storage.
|
11719
|
+
# @option opts [String] :password The password (Base64).
|
11715
11720
|
# @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers
|
11716
11721
|
def get_pdf_in_storage_to_xls_with_http_info(name, opts = {})
|
11717
11722
|
if @api_client.config.debugging
|
@@ -11732,6 +11737,7 @@ module AsposePdfCloud
|
|
11732
11737
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
11733
11738
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
11734
11739
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
11740
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
11735
11741
|
|
11736
11742
|
# header parameters
|
11737
11743
|
header_params = {}
|
@@ -11772,6 +11778,7 @@ module AsposePdfCloud
|
|
11772
11778
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
11773
11779
|
# @option opts [String] :folder The document folder.
|
11774
11780
|
# @option opts [String] :storage The document storage.
|
11781
|
+
# @option opts [String] :password The password (Base64).
|
11775
11782
|
# @return [File]
|
11776
11783
|
def get_pdf_in_storage_to_xlsx(name, opts = {})
|
11777
11784
|
@api_client.request_token_if_needed
|
@@ -11796,6 +11803,7 @@ module AsposePdfCloud
|
|
11796
11803
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
11797
11804
|
# @option opts [String] :folder The document folder.
|
11798
11805
|
# @option opts [String] :storage The document storage.
|
11806
|
+
# @option opts [String] :password The password (Base64).
|
11799
11807
|
# @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers
|
11800
11808
|
def get_pdf_in_storage_to_xlsx_with_http_info(name, opts = {})
|
11801
11809
|
if @api_client.config.debugging
|
@@ -11816,6 +11824,7 @@ module AsposePdfCloud
|
|
11816
11824
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
11817
11825
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
11818
11826
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
11827
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
11819
11828
|
|
11820
11829
|
# header parameters
|
11821
11830
|
header_params = {}
|
@@ -19235,6 +19244,7 @@ module AsposePdfCloud
|
|
19235
19244
|
# @option opts [Integer] :to End page if defined.
|
19236
19245
|
# @option opts [String] :storage The document storage.
|
19237
19246
|
# @option opts [String] :folder The document folder.
|
19247
|
+
# @option opts [String] :password Base64 encoded password.
|
19238
19248
|
# @return [SplitResultResponse]
|
19239
19249
|
def post_split_document(name, opts = {})
|
19240
19250
|
@api_client.request_token_if_needed
|
@@ -19258,6 +19268,7 @@ module AsposePdfCloud
|
|
19258
19268
|
# @option opts [Integer] :to End page if defined.
|
19259
19269
|
# @option opts [String] :storage The document storage.
|
19260
19270
|
# @option opts [String] :folder The document folder.
|
19271
|
+
# @option opts [String] :password Base64 encoded password.
|
19261
19272
|
# @return [Array<(SplitResultResponse, Fixnum, Hash)>] SplitResultResponse data, response status code and response headers
|
19262
19273
|
def post_split_document_with_http_info(name, opts = {})
|
19263
19274
|
if @api_client.config.debugging
|
@@ -19277,6 +19288,7 @@ module AsposePdfCloud
|
|
19277
19288
|
query_params[:'to'] = opts[:'to'] if !opts[:'to'].nil?
|
19278
19289
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
19279
19290
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
19291
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
19280
19292
|
|
19281
19293
|
# header parameters
|
19282
19294
|
header_params = {}
|
@@ -19314,6 +19326,7 @@ module AsposePdfCloud
|
|
19314
19326
|
# @param [Hash] opts the optional parameters
|
19315
19327
|
# @option opts [String] :storage The document storage.
|
19316
19328
|
# @option opts [String] :folder The document folder.
|
19329
|
+
# @option opts [String] :password Base64 encoded password.
|
19317
19330
|
# @return [SplitResultResponse]
|
19318
19331
|
def post_split_range_pdf_document(name, options, opts = {})
|
19319
19332
|
@api_client.request_token_if_needed
|
@@ -19335,6 +19348,7 @@ module AsposePdfCloud
|
|
19335
19348
|
# @param [Hash] opts the optional parameters
|
19336
19349
|
# @option opts [String] :storage The document storage.
|
19337
19350
|
# @option opts [String] :folder The document folder.
|
19351
|
+
# @option opts [String] :password Base64 encoded password.
|
19338
19352
|
# @return [Array<(SplitResultResponse, Fixnum, Hash)>] SplitResultResponse data, response status code and response headers
|
19339
19353
|
def post_split_range_pdf_document_with_http_info(name, options, opts = {})
|
19340
19354
|
if @api_client.config.debugging
|
@@ -19355,6 +19369,7 @@ module AsposePdfCloud
|
|
19355
19369
|
query_params = {}
|
19356
19370
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
19357
19371
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
19372
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
19358
19373
|
|
19359
19374
|
# header parameters
|
19360
19375
|
header_params = {}
|
@@ -24289,6 +24304,7 @@ module AsposePdfCloud
|
|
24289
24304
|
# @param type Type of PdfA format.
|
24290
24305
|
# @param [Hash] opts the optional parameters
|
24291
24306
|
# @option opts [String] :storage The document storage.
|
24307
|
+
# @option opts [String] :password The password (Base64).
|
24292
24308
|
# @option opts [File] :file A file to be converted.
|
24293
24309
|
# @return [AsposeResponse]
|
24294
24310
|
def put_pdf_in_request_to_pdf_a(out_path, type, opts = {})
|
@@ -24310,6 +24326,7 @@ module AsposePdfCloud
|
|
24310
24326
|
# @param type Type of PdfA format.
|
24311
24327
|
# @param [Hash] opts the optional parameters
|
24312
24328
|
# @option opts [String] :storage The document storage.
|
24329
|
+
# @option opts [String] :password The password (Base64).
|
24313
24330
|
# @option opts [File] :file A file to be converted.
|
24314
24331
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
24315
24332
|
def put_pdf_in_request_to_pdf_a_with_http_info(out_path, type, opts = {})
|
@@ -24336,6 +24353,7 @@ module AsposePdfCloud
|
|
24336
24353
|
query_params[:'outPath'] = out_path
|
24337
24354
|
query_params[:'type'] = type
|
24338
24355
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
24356
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
24339
24357
|
|
24340
24358
|
# header parameters
|
24341
24359
|
header_params = {}
|
@@ -24736,6 +24754,7 @@ module AsposePdfCloud
|
|
24736
24754
|
# @option opts [Float] :scale_factor Scale factor (Obsolete)
|
24737
24755
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
24738
24756
|
# @option opts [String] :storage The document storage.
|
24757
|
+
# @option opts [String] :password The password (Base64).
|
24739
24758
|
# @option opts [File] :file A file to be converted.
|
24740
24759
|
# @return [AsposeResponse]
|
24741
24760
|
def put_pdf_in_request_to_xls(out_path, opts = {})
|
@@ -24760,6 +24779,7 @@ module AsposePdfCloud
|
|
24760
24779
|
# @option opts [Float] :scale_factor Scale factor (Obsolete)
|
24761
24780
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
24762
24781
|
# @option opts [String] :storage The document storage.
|
24782
|
+
# @option opts [String] :password The password (Base64).
|
24763
24783
|
# @option opts [File] :file A file to be converted.
|
24764
24784
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
24765
24785
|
def put_pdf_in_request_to_xls_with_http_info(out_path, opts = {})
|
@@ -24781,6 +24801,7 @@ module AsposePdfCloud
|
|
24781
24801
|
query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
|
24782
24802
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
24783
24803
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
24804
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
24784
24805
|
|
24785
24806
|
# header parameters
|
24786
24807
|
header_params = {}
|
@@ -24822,6 +24843,7 @@ module AsposePdfCloud
|
|
24822
24843
|
# @option opts [Float] :scale_factor Scale factor (Obsolete)
|
24823
24844
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
24824
24845
|
# @option opts [String] :storage The document storage.
|
24846
|
+
# @option opts [String] :password The password (Base64).
|
24825
24847
|
# @option opts [File] :file A file to be converted.
|
24826
24848
|
# @return [AsposeResponse]
|
24827
24849
|
def put_pdf_in_request_to_xlsx(out_path, opts = {})
|
@@ -24846,6 +24868,7 @@ module AsposePdfCloud
|
|
24846
24868
|
# @option opts [Float] :scale_factor Scale factor (Obsolete)
|
24847
24869
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
24848
24870
|
# @option opts [String] :storage The document storage.
|
24871
|
+
# @option opts [String] :password The password (Base64).
|
24849
24872
|
# @option opts [File] :file A file to be converted.
|
24850
24873
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
24851
24874
|
def put_pdf_in_request_to_xlsx_with_http_info(out_path, opts = {})
|
@@ -24867,6 +24890,7 @@ module AsposePdfCloud
|
|
24867
24890
|
query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
|
24868
24891
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
24869
24892
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
24893
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
24870
24894
|
|
24871
24895
|
# header parameters
|
24872
24896
|
header_params = {}
|
@@ -25527,6 +25551,7 @@ module AsposePdfCloud
|
|
25527
25551
|
# @param [Hash] opts the optional parameters
|
25528
25552
|
# @option opts [String] :folder The document folder.
|
25529
25553
|
# @option opts [String] :storage The document storage.
|
25554
|
+
# @option opts [String] :password The password (Base64).
|
25530
25555
|
# @return [AsposeResponse]
|
25531
25556
|
def put_pdf_in_storage_to_pdf_a(name, out_path, type, opts = {})
|
25532
25557
|
@api_client.request_token_if_needed
|
@@ -25549,6 +25574,7 @@ module AsposePdfCloud
|
|
25549
25574
|
# @param [Hash] opts the optional parameters
|
25550
25575
|
# @option opts [String] :folder The document folder.
|
25551
25576
|
# @option opts [String] :storage The document storage.
|
25577
|
+
# @option opts [String] :password The password (Base64).
|
25552
25578
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
25553
25579
|
def put_pdf_in_storage_to_pdf_a_with_http_info(name, out_path, type, opts = {})
|
25554
25580
|
if @api_client.config.debugging
|
@@ -25579,6 +25605,7 @@ module AsposePdfCloud
|
|
25579
25605
|
query_params[:'type'] = type
|
25580
25606
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
25581
25607
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
25608
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
25582
25609
|
|
25583
25610
|
# header parameters
|
25584
25611
|
header_params = {}
|
@@ -25999,6 +26026,7 @@ module AsposePdfCloud
|
|
25999
26026
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
26000
26027
|
# @option opts [String] :folder The document folder.
|
26001
26028
|
# @option opts [String] :storage The document storage.
|
26029
|
+
# @option opts [String] :password The password (Base64).
|
26002
26030
|
# @return [AsposeResponse]
|
26003
26031
|
def put_pdf_in_storage_to_xls(name, out_path, opts = {})
|
26004
26032
|
@api_client.request_token_if_needed
|
@@ -26024,6 +26052,7 @@ module AsposePdfCloud
|
|
26024
26052
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
26025
26053
|
# @option opts [String] :folder The document folder.
|
26026
26054
|
# @option opts [String] :storage The document storage.
|
26055
|
+
# @option opts [String] :password The password (Base64).
|
26027
26056
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
26028
26057
|
def put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts = {})
|
26029
26058
|
if @api_client.config.debugging
|
@@ -26049,6 +26078,7 @@ module AsposePdfCloud
|
|
26049
26078
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
26050
26079
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
26051
26080
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
26081
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
26052
26082
|
|
26053
26083
|
# header parameters
|
26054
26084
|
header_params = {}
|
@@ -26090,6 +26120,7 @@ module AsposePdfCloud
|
|
26090
26120
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
26091
26121
|
# @option opts [String] :folder The document folder.
|
26092
26122
|
# @option opts [String] :storage The document storage.
|
26123
|
+
# @option opts [String] :password The password (Base64).
|
26093
26124
|
# @return [AsposeResponse]
|
26094
26125
|
def put_pdf_in_storage_to_xlsx(name, out_path, opts = {})
|
26095
26126
|
@api_client.request_token_if_needed
|
@@ -26115,6 +26146,7 @@ module AsposePdfCloud
|
|
26115
26146
|
# @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
|
26116
26147
|
# @option opts [String] :folder The document folder.
|
26117
26148
|
# @option opts [String] :storage The document storage.
|
26149
|
+
# @option opts [String] :password The password (Base64).
|
26118
26150
|
# @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
|
26119
26151
|
def put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts = {})
|
26120
26152
|
if @api_client.config.debugging
|
@@ -26140,6 +26172,7 @@ module AsposePdfCloud
|
|
26140
26172
|
query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
|
26141
26173
|
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
26142
26174
|
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
26175
|
+
query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
|
26143
26176
|
|
26144
26177
|
# header parameters
|
26145
26178
|
header_params = {}
|
@@ -26987,6 +27020,92 @@ module AsposePdfCloud
|
|
26987
27020
|
return data, status_code, headers
|
26988
27021
|
end
|
26989
27022
|
|
27023
|
+
# Replace document multiple image.
|
27024
|
+
#
|
27025
|
+
# @param name The document name.
|
27026
|
+
# @param image_ids The image IDs.
|
27027
|
+
# @param [Hash] opts the optional parameters
|
27028
|
+
# @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise.
|
27029
|
+
# @option opts [String] :storage The document storage.
|
27030
|
+
# @option opts [String] :folder The document folder.
|
27031
|
+
# @option opts [File] :image Image file.
|
27032
|
+
# @return [ImagesResponse]
|
27033
|
+
def put_replace_multiple_image(name, image_ids, opts = {})
|
27034
|
+
@api_client.request_token_if_needed
|
27035
|
+
data, _status_code, _headers = put_replace_multiple_image_with_http_info(name, image_ids, opts)
|
27036
|
+
rescue ApiError => error
|
27037
|
+
if error.code == 401
|
27038
|
+
@api_client.request_token_if_needed
|
27039
|
+
data, _status_code, _headers = put_replace_multiple_image_with_http_info(name, image_ids, opts)
|
27040
|
+
else
|
27041
|
+
raise
|
27042
|
+
end
|
27043
|
+
return data
|
27044
|
+
end
|
27045
|
+
|
27046
|
+
# Replace document multiple image.
|
27047
|
+
#
|
27048
|
+
# @param name The document name.
|
27049
|
+
# @param image_ids The image IDs.
|
27050
|
+
# @param [Hash] opts the optional parameters
|
27051
|
+
# @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise.
|
27052
|
+
# @option opts [String] :storage The document storage.
|
27053
|
+
# @option opts [String] :folder The document folder.
|
27054
|
+
# @option opts [File] :image Image file.
|
27055
|
+
# @return [Array<(ImagesResponse, Fixnum, Hash)>] ImagesResponse data, response status code and response headers
|
27056
|
+
def put_replace_multiple_image_with_http_info(name, image_ids, opts = {})
|
27057
|
+
if @api_client.config.debugging
|
27058
|
+
@api_client.config.logger.debug "Calling API: PdfApi.put_replace_multiple_image ..."
|
27059
|
+
end
|
27060
|
+
# verify the required parameter 'name' is set
|
27061
|
+
if @api_client.config.client_side_validation && name.nil?
|
27062
|
+
fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_replace_multiple_image"
|
27063
|
+
end
|
27064
|
+
# verify the required parameter 'image_ids' is set
|
27065
|
+
if @api_client.config.client_side_validation && image_ids.nil?
|
27066
|
+
fail ArgumentError, "Missing the required parameter 'image_ids' when calling PdfApi.put_replace_multiple_image"
|
27067
|
+
end
|
27068
|
+
# resource path
|
27069
|
+
local_var_path = "/pdf/{name}/images/replace".sub('{' + 'name' + '}', name.to_s)
|
27070
|
+
|
27071
|
+
# query parameters
|
27072
|
+
query_params = {}
|
27073
|
+
query_params[:'imageIds'] = @api_client.build_collection_param(image_ids, :csv)
|
27074
|
+
query_params[:'imageFilePath'] = opts[:'image_file_path'] if !opts[:'image_file_path'].nil?
|
27075
|
+
query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
|
27076
|
+
query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
|
27077
|
+
|
27078
|
+
# header parameters
|
27079
|
+
header_params = {}
|
27080
|
+
# HTTP header 'Accept' (if needed)
|
27081
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
27082
|
+
# HTTP header 'Content-Type'
|
27083
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
|
27084
|
+
|
27085
|
+
# form parameters
|
27086
|
+
form_params = {}
|
27087
|
+
# Fix header in file
|
27088
|
+
post_body = nil
|
27089
|
+
post_body = opts[:'image'] if !opts[:'image'].nil?
|
27090
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])
|
27091
|
+
|
27092
|
+
# http body (model)
|
27093
|
+
# Fix header in file
|
27094
|
+
# post_body = nil
|
27095
|
+
auth_names = ['JWT']
|
27096
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
|
27097
|
+
:header_params => header_params,
|
27098
|
+
:query_params => query_params,
|
27099
|
+
:form_params => form_params,
|
27100
|
+
:body => post_body,
|
27101
|
+
:auth_names => auth_names,
|
27102
|
+
:return_type => 'ImagesResponse')
|
27103
|
+
if @api_client.config.debugging
|
27104
|
+
@api_client.config.logger.debug "API called: PdfApi#put_replace_multiple_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
27105
|
+
end
|
27106
|
+
return data, status_code, headers
|
27107
|
+
end
|
27108
|
+
|
26990
27109
|
# Replace document screen annotation
|
26991
27110
|
#
|
26992
27111
|
# @param name The document name.
|
data/test/pdf_tests.rb
CHANGED
@@ -4882,24 +4882,34 @@ class PdfTests < Minitest::Test
|
|
4882
4882
|
def test_put_replace_image
|
4883
4883
|
file_name = 'PdfWithImages2.pdf'
|
4884
4884
|
upload_file(file_name)
|
4885
|
-
|
4886
4885
|
image_file_name = 'Koala.jpg'
|
4887
4886
|
upload_file(image_file_name)
|
4888
|
-
|
4889
4887
|
opts = {
|
4890
4888
|
:image_file_path => @temp_folder + '/' + image_file_name,
|
4891
4889
|
:folder => @temp_folder
|
4892
4890
|
}
|
4893
|
-
|
4894
4891
|
page_number = 1
|
4895
4892
|
responseImages = @pdf_api.get_images(file_name, page_number, opts)
|
4896
4893
|
assert(responseImages, 'Failed to read document images.')
|
4897
4894
|
image_id = responseImages[0].images.list[0].id
|
4898
|
-
|
4899
4895
|
response = @pdf_api.put_replace_image(file_name, image_id, opts)
|
4900
4896
|
assert(response, 'Failed to replace document image.')
|
4901
4897
|
end
|
4902
4898
|
|
4899
|
+
def test_put_replace_multiple_image
|
4900
|
+
file_name = 'PdfWithImages.pdf'
|
4901
|
+
upload_file(file_name)
|
4902
|
+
image_file_name = 'butterfly.jpg'
|
4903
|
+
upload_file(image_file_name)
|
4904
|
+
image_ids = ['GE5TENJVGQZTWMJYGQWDINRUFQ2DCMRMGY4TC', 'GE5TIMJSGY3TWMJXG4WDIMBZFQ2DCOJMGQ3DK']
|
4905
|
+
opts = {
|
4906
|
+
:image_file_path => @temp_folder + '/' + image_file_name,
|
4907
|
+
:folder => @temp_folder
|
4908
|
+
}
|
4909
|
+
response = @pdf_api.put_replace_multiple_image(file_name, image_ids, opts)
|
4910
|
+
assert(response, 'Failed to replace document images.')
|
4911
|
+
end
|
4912
|
+
|
4903
4913
|
def test_post_insert_image
|
4904
4914
|
file_name = 'PdfWithImages2.pdf'
|
4905
4915
|
upload_file(file_name)
|
Binary file
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aspose_pdf_cloud
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 23.
|
4
|
+
version: 23.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aspose PDF Cloud
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-09-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|
@@ -785,6 +785,7 @@ files:
|
|
785
785
|
- test_data/PdfWithAnnotations1.pdf
|
786
786
|
- test_data/PdfWithBookmarks.pdf
|
787
787
|
- test_data/PdfWithEmbeddedFiles.pdf
|
788
|
+
- test_data/PdfWithImages.pdf
|
788
789
|
- test_data/PdfWithImages2.pdf
|
789
790
|
- test_data/PdfWithLinks.pdf
|
790
791
|
- test_data/PdfWithScreenAnnotations.pdf
|