aspose_cells_cloud 23.10 → 23.11

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.
@@ -1,1304 +0,0 @@
1
- =begin
2
- --------------------------------------------------------------------------------------------------------------------
3
- Copyright (c) 2022 Aspose.Cells Cloud
4
- Permission is hereby granted, free of charge, to any person obtaining a copy
5
- of this software and associated documentation files (the "Software"), to deal
6
- in the Software without restriction, including without limitation the rights
7
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
- copies of the Software, and to permit persons to whom the Software is
9
- furnished to do so, subject to the following conditions:
10
- The above copyright notice and this permission notice shall be included in all
11
- copies or substantial portions of the Software.
12
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
17
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
18
- SOFTWARE.
19
- --------------------------------------------------------------------------------------------------------------------
20
-
21
- =end
22
-
23
- require "uri"
24
-
25
- module AsposeCellsCloud
26
- class LightCellsApi
27
- attr_accessor :api_client
28
-
29
- def initialize(client_id,client_secret, app_version = 'v3.0', app_host = 'api.aspose.cloud', api_client = ApiClient.default)
30
- warn "Warning: #initialize() is deprecated."
31
- @api_client = api_client
32
- @api_client.config.client_secret = client_secret
33
- @api_client.config.client_id = client_id
34
- @api_client.config.api_version = app_version
35
- @api_client.config.host = app_host
36
- end
37
-
38
- #
39
- #
40
- # @param file File to upload
41
- # @param [Hash] opts the optional parameters
42
- # @option opts [String] :type (default to all)
43
- # @return [FilesResult]
44
- def delete_metadata(file, opts = {})
45
- warn "Warning: #delete_metadata() is deprecated."
46
- data, _status_code, _headers = delete_metadata_with_http_info(file, opts)
47
- return data
48
- end
49
-
50
- #
51
- #
52
- # @param file File to upload
53
- # @param [Hash] opts the optional parameters
54
- # @option opts [String] :type
55
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
56
- def delete_metadata_with_http_info(file, opts = {})
57
- warn "Warning: #delete_metadata_with_http_info() is deprecated."
58
- if @api_client.config.debugging
59
- @api_client.config.logger.debug "Calling API: LightCellsApi.delete_metadata ..."
60
- end
61
- @api_client.request_token_if_needed
62
- # verify the required parameter 'file' is set
63
- if @api_client.config.client_side_validation && file.nil?
64
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.delete_metadata"
65
- end
66
- # resource path
67
- local_var_path = "/cells/metadata/delete"
68
-
69
- # query parameters
70
- query_params = {}
71
- query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
72
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
73
-
74
- # header parameters
75
- header_params = {}
76
- # HTTP header 'Accept' (if needed)
77
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
78
- # HTTP header 'Content-Type'
79
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
80
-
81
- # form parameters
82
- form_params = {}
83
- file.each do |filename , context|
84
- form_params[filename] = context
85
- end
86
-
87
- # http body (model)
88
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
89
- post_body = ""
90
- #auth_names = []
91
- auth_names = ['JWT']
92
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
93
- :header_params => header_params,
94
- :query_params => query_params,
95
- :form_params => form_params,
96
- :body => post_body,
97
- :auth_names => auth_names,
98
- :return_type => 'FilesResult')
99
- if @api_client.config.debugging
100
- @api_client.config.logger.debug "API called: LightCellsApi#delete_metadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
101
- end
102
- return data, status_code, headers
103
- end
104
-
105
- #
106
- #
107
- # @param file File to upload
108
- # @param [Hash] opts the optional parameters
109
- # @option opts [String] :type (default to all)
110
- # @return [Array<CellsDocumentProperty>]
111
- def get_metadata(file, opts = {})
112
- warn "Warning: #get_metadata() is deprecated."
113
- data, _status_code, _headers = get_metadata_with_http_info(file, opts)
114
- return data
115
- end
116
-
117
- #
118
- #
119
- # @param file File to upload
120
- # @param [Hash] opts the optional parameters
121
- # @option opts [String] :type
122
- # @return [Array<(Array<CellsDocumentProperty>, Fixnum, Hash)>] Array<CellsDocumentProperty> data, response status code and response headers
123
- def get_metadata_with_http_info(file, opts = {})
124
- warn "Warning: #get_metadata_with_http_info() is deprecated."
125
- if @api_client.config.debugging
126
- @api_client.config.logger.debug "Calling API: LightCellsApi.get_metadata ..."
127
- end
128
- @api_client.request_token_if_needed
129
- # verify the required parameter 'file' is set
130
- if @api_client.config.client_side_validation && file.nil?
131
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.get_metadata"
132
- end
133
- # resource path
134
- local_var_path = "/cells/metadata/get"
135
-
136
- # query parameters
137
- query_params = {}
138
- query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
139
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
140
-
141
- # header parameters
142
- header_params = {}
143
- # HTTP header 'Accept' (if needed)
144
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
145
- # HTTP header 'Content-Type'
146
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
147
-
148
- # form parameters
149
- form_params = {}
150
- file.each do |filename , context|
151
- form_params[filename] = context
152
- end
153
-
154
- # http body (model)
155
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
156
- post_body = ""
157
- #auth_names = []
158
- auth_names = ['JWT']
159
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
160
- :header_params => header_params,
161
- :query_params => query_params,
162
- :form_params => form_params,
163
- :body => post_body,
164
- :auth_names => auth_names,
165
- :return_type => 'Array<CellsDocumentProperty>')
166
- if @api_client.config.debugging
167
- @api_client.config.logger.debug "API called: LightCellsApi#get_metadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
168
- end
169
- return data, status_code, headers
170
- end
171
-
172
- #
173
- #
174
- # @param file File to upload
175
- # @param datasource
176
- # @param [Hash] opts the optional parameters
177
- # @option opts [String] :format (default to Xlsx)
178
- # @return [FilesResult]
179
- def post_assemble(file, datasource, opts = {})
180
- warn "Warning: #post_assemble() is deprecated."
181
- data, _status_code, _headers = post_assemble_with_http_info(file, datasource, opts)
182
- return data
183
- end
184
-
185
- #
186
- #
187
- # @param file File to upload
188
- # @param datasource
189
- # @param [Hash] opts the optional parameters
190
- # @option opts [String] :format
191
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
192
- def post_assemble_with_http_info(file, datasource, opts = {})
193
- warn "Warning: #post_assemble_with_http_info() is deprecated."
194
- if @api_client.config.debugging
195
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_assemble ..."
196
- end
197
- @api_client.request_token_if_needed
198
- # verify the required parameter 'file' is set
199
- if @api_client.config.client_side_validation && file.nil?
200
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_assemble"
201
- end
202
- # verify the required parameter 'datasource' is set
203
- if @api_client.config.client_side_validation && datasource.nil?
204
- fail ArgumentError, "Missing the required parameter 'datasource' when calling LightCellsApi.post_assemble"
205
- end
206
- # resource path
207
- local_var_path = "/cells/assemble"
208
-
209
- # query parameters
210
- query_params = {}
211
- query_params[:'datasource'] = datasource
212
- query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
213
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
214
-
215
- # header parameters
216
- header_params = {}
217
- # HTTP header 'Accept' (if needed)
218
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
219
- # HTTP header 'Content-Type'
220
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
221
- # header_params['Content-Type'] == 'multipart/form-data'
222
- # form parameters
223
- form_params = {}
224
- file.each do |filename , context|
225
- form_params[filename] = context
226
- end
227
-
228
- # http body (model)
229
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
230
- post_body = ""
231
- #auth_names = []
232
- auth_names = ['JWT']
233
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
234
- :header_params => header_params,
235
- :query_params => query_params,
236
- :form_params => form_params,
237
- :body => post_body,
238
- :auth_names => auth_names,
239
- :return_type => 'FilesResult')
240
- if @api_client.config.debugging
241
- @api_client.config.logger.debug "API called: LightCellsApi#post_assemble\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
242
- end
243
- return data, status_code, headers
244
- end
245
-
246
- #
247
- #
248
- # @param file File to upload
249
- # @param objecttype
250
- # @param [Hash] opts the optional parameters
251
- # @return [FilesResult]
252
- def post_clear_objects(file, objecttype, opts = {})
253
- warn "Warning: #post_clear_objects() is deprecated."
254
- data, _status_code, _headers = post_clear_objects_with_http_info(file, objecttype, opts)
255
- return data
256
- end
257
-
258
- #
259
- #
260
- # @param file File to upload
261
- # @param objecttype
262
- # @param [Hash] opts the optional parameters
263
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
264
- def post_clear_objects_with_http_info(file, objecttype, opts = {})
265
- warn "Warning: #post_clear_objects_with_http_info() is deprecated."
266
- if @api_client.config.debugging
267
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_clear_objects ..."
268
- end
269
- @api_client.request_token_if_needed
270
- # verify the required parameter 'file' is set
271
- if @api_client.config.client_side_validation && file.nil?
272
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_clear_objects"
273
- end
274
- # verify the required parameter 'objecttype' is set
275
- if @api_client.config.client_side_validation && objecttype.nil?
276
- fail ArgumentError, "Missing the required parameter 'objecttype' when calling LightCellsApi.post_clear_objects"
277
- end
278
- # resource path
279
- local_var_path = "/cells/clearobjects"
280
-
281
- # query parameters
282
- query_params = {}
283
- query_params[:'objecttype'] = objecttype
284
- query_params[:'sheetname'] = opts[:'sheetname'] if !opts[:'sheetname'].nil?
285
- query_params[:'outFormat'] = opts[:'out_format'] if !opts[:'out_format'].nil?
286
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
287
- # header parameters
288
- header_params = {}
289
- # HTTP header 'Accept' (if needed)
290
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
291
- # HTTP header 'Content-Type'
292
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
293
-
294
- # form parameters
295
- form_params = {}
296
- file.each do |filename , context|
297
- form_params[filename] = context
298
- end
299
-
300
- # http body (model)
301
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
302
- post_body = ""
303
- #auth_names = []
304
- auth_names = ['JWT']
305
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
306
- :header_params => header_params,
307
- :query_params => query_params,
308
- :form_params => form_params,
309
- :body => post_body,
310
- :auth_names => auth_names,
311
- :return_type => 'FilesResult')
312
- if @api_client.config.debugging
313
- @api_client.config.logger.debug "API called: LightCellsApi#post_clear_objects\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
314
- end
315
- return data, status_code, headers
316
- end
317
-
318
- #
319
- #
320
- # @param file File to upload
321
- # @param object_type
322
- # @param format
323
- # @param [Hash] opts the optional parameters
324
- # @return [FilesResult]
325
- def post_export(file, object_type, format, opts = {})
326
- warn "Warning: #post_export() is deprecated."
327
- data, _status_code, _headers = post_export_with_http_info(file, object_type, format, opts)
328
- return data
329
- end
330
-
331
- #
332
- #
333
- # @param file File to upload
334
- # @param object_type
335
- # @param format
336
- # @param [Hash] opts the optional parameters
337
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
338
- def post_export_with_http_info(file, object_type, format, opts = {})
339
- warn "Warning: #post_export_with_http_info() is deprecated."
340
- if @api_client.config.debugging
341
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_export ..."
342
- end
343
- @api_client.request_token_if_needed
344
- # verify the required parameter 'file' is set
345
- if @api_client.config.client_side_validation && file.nil?
346
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_export"
347
- end
348
- # verify the required parameter 'object_type' is set
349
- if @api_client.config.client_side_validation && object_type.nil?
350
- fail ArgumentError, "Missing the required parameter 'object_type' when calling LightCellsApi.post_export"
351
- end
352
- # verify the required parameter 'format' is set
353
- if @api_client.config.client_side_validation && format.nil?
354
- fail ArgumentError, "Missing the required parameter 'format' when calling LightCellsApi.post_export"
355
- end
356
- # resource path
357
- local_var_path = "/cells/export"
358
-
359
- # query parameters
360
- query_params = {}
361
- query_params[:'objectType'] = object_type
362
- query_params[:'format'] = format
363
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
364
- if opts[:'extendedQueryParameters']
365
- opts[:'extendedQueryParameters'].each do |key , value|
366
- query_params[key] = value
367
- end
368
- end
369
-
370
- # header parameters
371
- header_params = {}
372
- # HTTP header 'Accept' (if needed)
373
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
374
- # HTTP header 'Content-Type'
375
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
376
-
377
- # form parameters
378
- form_params = {}
379
- file.each do |filename , context|
380
- form_params[filename] = context
381
- end
382
-
383
- # http body (model)
384
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
385
- post_body = ""
386
- #auth_names = []
387
- auth_names = ['JWT']
388
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
389
- :header_params => header_params,
390
- :query_params => query_params,
391
- :form_params => form_params,
392
- :body => post_body,
393
- :auth_names => auth_names,
394
- :return_type => 'FilesResult')
395
- if @api_client.config.debugging
396
- @api_client.config.logger.debug "API called: LightCellsApi#post_export\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
397
- end
398
- return data, status_code, headers
399
- end
400
-
401
- #
402
- #
403
- # @param file File to upload
404
- # @param import_data
405
- # @param [Hash] opts the optional parameters
406
- # @return [FilesResult]
407
- def post_import(file, import_data, opts = {})
408
- warn "Warning: #post_import() is deprecated."
409
- data, _status_code, _headers = post_import_with_http_info(file, import_data, opts)
410
- return data
411
- end
412
-
413
- #
414
- #
415
- # @param file File to upload
416
- # @param import_data
417
- # @param [Hash] opts the optional parameters
418
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
419
- def post_import_with_http_info(file, import_data, opts = {})
420
- warn "Warning: #post_import_with_http_info() is deprecated."
421
- if @api_client.config.debugging
422
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_import ..."
423
- end
424
- @api_client.request_token_if_needed
425
- # verify the required parameter 'file' is set
426
- if @api_client.config.client_side_validation && file.nil?
427
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_import"
428
- end
429
- # verify the required parameter 'import_data' is set
430
- if @api_client.config.client_side_validation && import_data.nil?
431
- fail ArgumentError, "Missing the required parameter 'import_data' when calling LightCellsApi.post_import"
432
- end
433
- # resource path
434
- local_var_path = "/cells/import"
435
-
436
- # query parameters
437
- query_params = {}
438
-
439
- # header parameters
440
- header_params = {}
441
- # HTTP header 'Accept' (if needed)
442
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
443
- # HTTP header 'Content-Type'
444
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
445
-
446
- # form parameters
447
- form_params = {}
448
- file.each do |filename , context|
449
- form_params[filename] = context
450
- end
451
-
452
- # http body (model)
453
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
454
- post_body = ""
455
-
456
- # http body (model)
457
- post_body = @api_client.object_to_http_body(import_data)
458
- if post_body
459
- form_params['documentproperties'] = post_body.to_json
460
- end
461
-
462
- #auth_names = []
463
- auth_names = ['JWT']
464
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
465
- :header_params => header_params,
466
- :query_params => query_params,
467
- :form_params => form_params,
468
- :body => post_body,
469
- :auth_names => auth_names,
470
- :return_type => 'FilesResult')
471
- if @api_client.config.debugging
472
- @api_client.config.logger.debug "API called: LightCellsApi#post_import\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
473
- end
474
- return data, status_code, headers
475
- end
476
-
477
- #
478
- #
479
- # @param file File to upload
480
- # @param [Hash] opts the optional parameters
481
- # @option opts [String] :format (default to xlsx)
482
- # @option opts [BOOLEAN] :merge_to_one_sheet (default to false)
483
- # @return [FileInfo]
484
- def post_merge(file, opts = {})
485
- warn "Warning: #post_merge() is deprecated."
486
- data, _status_code, _headers = post_merge_with_http_info(file, opts)
487
- return data
488
- end
489
-
490
- #
491
- #
492
- # @param file File to upload
493
- # @param [Hash] opts the optional parameters
494
- # @option opts [String] :format
495
- # @option opts [BOOLEAN] :merge_to_one_sheet
496
- # @return [Array<(FileInfo, Fixnum, Hash)>] FileInfo data, response status code and response headers
497
- def post_merge_with_http_info(file, opts = {})
498
- warn "Warning: #post_merge_with_http_info() is deprecated."
499
- if @api_client.config.debugging
500
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_merge ..."
501
- end
502
- @api_client.request_token_if_needed
503
- # verify the required parameter 'file' is set
504
- if @api_client.config.client_side_validation && file.nil?
505
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_merge"
506
- end
507
- # resource path
508
- local_var_path = "/cells/merge"
509
-
510
- # query parameters
511
- query_params = {}
512
- query_params[:'format'] = opts[:'format'] if !opts[:'format'].nil?
513
- query_params[:'mergeToOneSheet'] = opts[:'merge_to_one_sheet'] if !opts[:'merge_to_one_sheet'].nil?
514
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
515
-
516
- # header parameters
517
- header_params = {}
518
- # HTTP header 'Accept' (if needed)
519
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
520
- # HTTP header 'Content-Type'
521
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
522
-
523
- # form parameters
524
- form_params = {}
525
- file.each do |filename , context|
526
- form_params[filename] = context
527
- end
528
-
529
- # http body (model)
530
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
531
- post_body = ""
532
- #auth_names = []
533
- auth_names = ['JWT']
534
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
535
- :header_params => header_params,
536
- :query_params => query_params,
537
- :form_params => form_params,
538
- :body => post_body,
539
- :auth_names => auth_names,
540
- :return_type => 'FileInfo')
541
- if @api_client.config.debugging
542
- @api_client.config.logger.debug "API called: LightCellsApi#post_merge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
543
- end
544
- return data, status_code, headers
545
- end
546
-
547
- #
548
- #
549
- # @param file File to upload
550
- # @param document_properties Cells document property.
551
- # @param [Hash] opts the optional parameters
552
- # @return [FilesResult]
553
- def post_metadata(file, document_properties, opts = {})
554
- warn "Warning: #post_metadata() is deprecated."
555
- data, _status_code, _headers = post_metadata_with_http_info(file, document_properties, opts)
556
- return data
557
- end
558
-
559
- #
560
- #
561
- # @param file File to upload
562
- # @param document_properties Cells document property.
563
- # @param [Hash] opts the optional parameters
564
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
565
- def post_metadata_with_http_info(file, document_properties, opts = {})
566
- warn "Warning: #post_metadata_with_http_info() is deprecated."
567
- if @api_client.config.debugging
568
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_metadata ..."
569
- end
570
- @api_client.request_token_if_needed
571
- # verify the required parameter 'file' is set
572
- if @api_client.config.client_side_validation && file.nil?
573
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_metadata"
574
- end
575
- # verify the required parameter 'document_properties' is set
576
- if @api_client.config.client_side_validation && document_properties.nil?
577
- fail ArgumentError, "Missing the required parameter 'document_properties' when calling LightCellsApi.post_metadata"
578
- end
579
- # resource path
580
- local_var_path = "/cells/metadata/update"
581
-
582
- # query parameters
583
- query_params = {}
584
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
585
-
586
- # header parameters
587
- header_params = {}
588
- # HTTP header 'Accept' (if needed)
589
- header_params['Accept'] = @api_client.select_header_accept(['multipart/form-data'])
590
- # HTTP header 'Content-Type'
591
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
592
-
593
- # form parameters
594
- form_params = {}
595
- file.each do |filename , context|
596
- form_params[filename] = context
597
- end
598
-
599
- # http body (model)
600
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
601
- post_body = ""
602
-
603
- # http body (model)
604
- post_body = @api_client.object_to_http_body(document_properties)
605
- if post_body
606
- form_params['documentproperties'] = post_body.to_json
607
- end
608
- #auth_names = []
609
- auth_names = ['JWT']
610
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
611
- :header_params => header_params,
612
- :query_params => query_params,
613
- :form_params => form_params,
614
- :body => post_body,
615
- :auth_names => auth_names,
616
- :return_type => 'FilesResult')
617
- if @api_client.config.debugging
618
- @api_client.config.logger.debug "API called: LightCellsApi#post_metadata\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
619
- end
620
- return data, status_code, headers
621
- end
622
-
623
- #
624
- #
625
- # @param file File to upload
626
- # @param password
627
- # @param [Hash] opts the optional parameters
628
- # @return [FilesResult]
629
- def post_protect(file, password, opts = {})
630
- warn "Warning: #post_protect() is deprecated."
631
- data, _status_code, _headers = post_protect_with_http_info(file, password, opts)
632
- return data
633
- end
634
-
635
- #
636
- #
637
- # @param file File to upload
638
- # @param password
639
- # @param [Hash] opts the optional parameters
640
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
641
- def post_protect_with_http_info(file, password, opts = {})
642
- warn "Warning: #post_protect_with_http_info() is deprecated."
643
- if @api_client.config.debugging
644
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_protect ..."
645
- end
646
- @api_client.request_token_if_needed
647
- # verify the required parameter 'file' is set
648
- if @api_client.config.client_side_validation && file.nil?
649
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_protect"
650
- end
651
- # verify the required parameter 'password' is set
652
- if @api_client.config.client_side_validation && password.nil?
653
- fail ArgumentError, "Missing the required parameter 'password' when calling LightCellsApi.post_protect"
654
- end
655
- # resource path
656
- local_var_path = "/cells/protect"
657
-
658
- # query parameters
659
- query_params = {}
660
- query_params[:'password'] = password
661
-
662
- # header parameters
663
- header_params = {}
664
- # HTTP header 'Accept' (if needed)
665
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
666
- # HTTP header 'Content-Type'
667
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
668
-
669
- # form parameters
670
- form_params = {}
671
- file.each do |filename , context|
672
- form_params[filename] = context
673
- end
674
-
675
- # http body (model)
676
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
677
- post_body = ""
678
- #auth_names = []
679
- auth_names = ['JWT']
680
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
681
- :header_params => header_params,
682
- :query_params => query_params,
683
- :form_params => form_params,
684
- :body => post_body,
685
- :auth_names => auth_names,
686
- :return_type => 'FilesResult')
687
- if @api_client.config.debugging
688
- @api_client.config.logger.debug "API called: LightCellsApi#post_protect\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
689
- end
690
- return data, status_code, headers
691
- end
692
-
693
- #
694
- #
695
- # @param file File to upload
696
- # @param text
697
- # @param [Hash] opts the optional parameters
698
- # @option opts [String] :password
699
- # @option opts [String] :sheetname
700
- # @return [Array<TextItem>]
701
- def post_search(file, text, opts = {})
702
- warn "Warning: #post_search() is deprecated."
703
- data, _status_code, _headers = post_search_with_http_info(file, text, opts)
704
- return data
705
- end
706
-
707
- #
708
- #
709
- # @param file File to upload
710
- # @param text
711
- # @param [Hash] opts the optional parameters
712
- # @option opts [String] :password
713
- # @option opts [String] :sheetname
714
- # @return [Array<(Array<TextItem>, Fixnum, Hash)>] Array<TextItem> data, response status code and response headers
715
- def post_search_with_http_info(file, text, opts = {})
716
- warn "Warning: #post_search_with_http_info() is deprecated."
717
- if @api_client.config.debugging
718
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_search ..."
719
- end
720
- @api_client.request_token_if_needed
721
- # verify the required parameter 'file' is set
722
- if @api_client.config.client_side_validation && file.nil?
723
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_search"
724
- end
725
- # verify the required parameter 'text' is set
726
- if @api_client.config.client_side_validation && text.nil?
727
- fail ArgumentError, "Missing the required parameter 'text' when calling LightCellsApi.post_search"
728
- end
729
- # resource path
730
- local_var_path = "/cells/search"
731
-
732
- # query parameters
733
- query_params = {}
734
- query_params[:'text'] = text
735
- query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
736
- query_params[:'sheetname'] = opts[:'sheetname'] if !opts[:'sheetname'].nil?
737
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
738
-
739
- # header parameters
740
- header_params = {}
741
- # HTTP header 'Accept' (if needed)
742
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
743
- # HTTP header 'Content-Type'
744
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
745
-
746
- # form parameters
747
- form_params = {}
748
- file.each do |filename , context|
749
- form_params[filename] = context
750
- end
751
-
752
- # http body (model)
753
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
754
- post_body = ""
755
- #auth_names = []
756
- auth_names = ['JWT']
757
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
758
- :header_params => header_params,
759
- :query_params => query_params,
760
- :form_params => form_params,
761
- :body => post_body,
762
- :auth_names => auth_names,
763
- :return_type => 'Array<TextItem>')
764
- if @api_client.config.debugging
765
- @api_client.config.logger.debug "API called: LightCellsApi#post_search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
766
- end
767
- return data, status_code, headers
768
- end
769
-
770
- #
771
- #
772
- # @param file File to upload
773
- # @param format
774
- # @param [Hash] opts the optional parameters
775
- # @option opts [String] :password
776
- # @option opts [Integer] :from
777
- # @option opts [Integer] :to
778
- # @return [FilesResult]
779
- def post_split(file, format, opts = {})
780
- warn "Warning: #post_split() is deprecated."
781
- data, _status_code, _headers = post_split_with_http_info(file, format, opts)
782
- return data
783
- end
784
-
785
- #
786
- #
787
- # @param file File to upload
788
- # @param format
789
- # @param [Hash] opts the optional parameters
790
- # @option opts [String] :password
791
- # @option opts [Integer] :from
792
- # @option opts [Integer] :to
793
- # @option opts [String] :path
794
- # @option opts [String] :storage_name
795
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
796
- def post_split_with_http_info(file, format, opts = {})
797
- warn "Warning: #post_split_with_http_info() is deprecated."
798
- if @api_client.config.debugging
799
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_split ..."
800
- end
801
- @api_client.request_token_if_needed
802
- # verify the required parameter 'file' is set
803
- if @api_client.config.client_side_validation && file.nil?
804
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_split"
805
- end
806
- # verify the required parameter 'format' is set
807
- if @api_client.config.client_side_validation && format.nil?
808
- fail ArgumentError, "Missing the required parameter 'format' when calling LightCellsApi.post_split"
809
- end
810
- # resource path
811
- local_var_path = "/cells/split"
812
-
813
- # query parameters
814
- query_params = {}
815
- query_params[:'format'] = format
816
- query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
817
- query_params[:'from'] = opts[:'from'] if !opts[:'from'].nil?
818
- query_params[:'to'] = opts[:'to'] if !opts[:'to'].nil?
819
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
820
-
821
- # header parameters
822
- header_params = {}
823
- # HTTP header 'Accept' (if needed)
824
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
825
- # HTTP header 'Content-Type'
826
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
827
-
828
- # form parameters
829
- form_params = {}
830
- file.each do |filename , context|
831
- form_params[filename] = context
832
- end
833
-
834
- # http body (model)
835
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
836
- post_body = ""
837
- #auth_names = []
838
- auth_names = ['JWT']
839
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
840
- :header_params => header_params,
841
- :query_params => query_params,
842
- :form_params => form_params,
843
- :body => post_body,
844
- :auth_names => auth_names,
845
- :return_type => 'FilesResult')
846
- if @api_client.config.debugging
847
- @api_client.config.logger.debug "API called: LightCellsApi#post_split\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
848
- end
849
- return data, status_code, headers
850
- end
851
-
852
- #
853
- #
854
- # @param file File to upload
855
- # @param password
856
- # @param [Hash] opts the optional parameters
857
- # @return [FilesResult]
858
- def post_unlock(file, password, opts = {})
859
- warn "Warning: #post_unlock() is deprecated."
860
- data, _status_code, _headers = post_unlock_with_http_info(file, password, opts)
861
- return data
862
- end
863
-
864
- #
865
- #
866
- # @param file File to upload
867
- # @param password
868
- # @param [Hash] opts the optional parameters
869
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
870
- def post_unlock_with_http_info(file, password, opts = {})
871
- warn "Warning: #post_unlock_with_http_info() is deprecated."
872
- if @api_client.config.debugging
873
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_unlock ..."
874
- end
875
- @api_client.request_token_if_needed
876
- # verify the required parameter 'file' is set
877
- if @api_client.config.client_side_validation && file.nil?
878
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_unlock"
879
- end
880
- # verify the required parameter 'password' is set
881
- if @api_client.config.client_side_validation && password.nil?
882
- fail ArgumentError, "Missing the required parameter 'password' when calling LightCellsApi.post_unlock"
883
- end
884
- # resource path
885
- local_var_path = "/cells/unlock"
886
-
887
- # query parameters
888
- query_params = {}
889
- query_params[:'password'] = password
890
-
891
- # header parameters
892
- header_params = {}
893
- # HTTP header 'Accept' (if needed)
894
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
895
- # HTTP header 'Content-Type'
896
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
897
-
898
- # form parameters
899
- form_params = {}
900
- file.each do |filename , context|
901
- form_params[filename] = context
902
- end
903
-
904
- # http body (model)
905
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
906
- post_body = ""
907
- #auth_names = []
908
- auth_names = ['JWT']
909
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
910
- :header_params => header_params,
911
- :query_params => query_params,
912
- :form_params => form_params,
913
- :body => post_body,
914
- :auth_names => auth_names,
915
- :return_type => 'FilesResult')
916
- if @api_client.config.debugging
917
- @api_client.config.logger.debug "API called: LightCellsApi#post_unlock\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
918
- end
919
- return data, status_code, headers
920
- end
921
-
922
- #
923
- #
924
- # @param file File to upload
925
- # @param text
926
- # @param color
927
- # @param [Hash] opts the optional parameters
928
- # @return [FilesResult]
929
- def post_watermark(file, text, color, opts = {})
930
- warn "Warning: #post_watermark() is deprecated."
931
- data, _status_code, _headers = post_watermark_with_http_info(file, text, color, opts)
932
- return data
933
- end
934
-
935
- #
936
- #
937
- # @param file File to upload
938
- # @param text
939
- # @param color
940
- # @param [Hash] opts the optional parameters
941
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
942
- def post_watermark_with_http_info(file, text, color, opts = {})
943
- warn "Warning: #post_watermark_with_http_info() is deprecated."
944
- if @api_client.config.debugging
945
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_watermark ..."
946
- end
947
- @api_client.request_token_if_needed
948
- # verify the required parameter 'file' is set
949
- if @api_client.config.client_side_validation && file.nil?
950
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_watermark"
951
- end
952
- # verify the required parameter 'text' is set
953
- if @api_client.config.client_side_validation && text.nil?
954
- fail ArgumentError, "Missing the required parameter 'text' when calling LightCellsApi.post_watermark"
955
- end
956
- # verify the required parameter 'color' is set
957
- if @api_client.config.client_side_validation && color.nil?
958
- fail ArgumentError, "Missing the required parameter 'color' when calling LightCellsApi.post_watermark"
959
- end
960
- # resource path
961
- local_var_path = "/cells/watermark"
962
-
963
- # query parameters
964
- query_params = {}
965
- query_params[:'text'] = text
966
- query_params[:'color'] = color
967
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
968
-
969
- # header parameters
970
- header_params = {}
971
- # HTTP header 'Accept' (if needed)
972
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
973
- # HTTP header 'Content-Type'
974
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
975
-
976
- # form parameters
977
- form_params = {}
978
- file.each do |filename , context|
979
- form_params[filename] = context
980
- end
981
-
982
- # http body (model)
983
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
984
- post_body = ""
985
- #auth_names = []
986
- auth_names = ['JWT']
987
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
988
- :header_params => header_params,
989
- :query_params => query_params,
990
- :form_params => form_params,
991
- :body => post_body,
992
- :auth_names => auth_names,
993
- :return_type => 'FilesResult')
994
- if @api_client.config.debugging
995
- @api_client.config.logger.debug "API called: LightCellsApi#post_watermark\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
996
- end
997
- return data, status_code, headers
998
- end
999
-
1000
- #
1001
- #
1002
- # @param file File to upload
1003
- # @param compress_level
1004
- # @param [Hash] opts the optional parameters
1005
- # @return [FilesResult]
1006
- def post_compress(file, compress_level, opts = {})
1007
- warn "Warning: #post_compress() is deprecated."
1008
- data, _status_code, _headers = post_compress_with_http_info(file, compress_level, opts)
1009
- return data
1010
- end
1011
-
1012
- #
1013
- #
1014
- # @param file File to upload
1015
- # @param compress_level
1016
- # @param [Hash] opts the optional parameters
1017
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
1018
- def post_compress_with_http_info(file, compress_level, opts = {})
1019
- warn "Warning: #post_compress_with_http_info() is deprecated."
1020
- if @api_client.config.debugging
1021
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_compress ..."
1022
- end
1023
- @api_client.request_token_if_needed
1024
- # verify the required parameter 'file' is set
1025
- if @api_client.config.client_side_validation && file.nil?
1026
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_compress"
1027
- end
1028
- # verify the required parameter 'compress_level' is set
1029
- if @api_client.config.client_side_validation && compress_level.nil?
1030
- fail ArgumentError, "Missing the required parameter 'compress_level' when calling LightCellsApi.post_compress"
1031
- end
1032
-
1033
- # resource path
1034
- local_var_path = "/cells/compress"
1035
-
1036
- # query parameters
1037
- query_params = {}
1038
- query_params[:'compressLevel'] = compress_level
1039
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
1040
-
1041
- # header parameters
1042
- header_params = {}
1043
- # HTTP header 'Accept' (if needed)
1044
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1045
- # HTTP header 'Content-Type'
1046
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1047
-
1048
- # form parameters
1049
- form_params = {}
1050
- file.each do |filename , context|
1051
- form_params[filename] = context
1052
- end
1053
-
1054
- # http body (model)
1055
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1056
- post_body = ""
1057
- #auth_names = []
1058
- auth_names = ['JWT']
1059
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1060
- :header_params => header_params,
1061
- :query_params => query_params,
1062
- :form_params => form_params,
1063
- :body => post_body,
1064
- :auth_names => auth_names,
1065
- :return_type => 'FilesResult')
1066
- if @api_client.config.debugging
1067
- @api_client.config.logger.debug "API called: LightCellsApi#post_compress\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1068
- end
1069
- return data, status_code, headers
1070
- end
1071
-
1072
- #
1073
- #
1074
- # @param file File to upload
1075
- # @param text
1076
- # @param newtext
1077
- # @param [Hash] opts the optional parameters
1078
- # @param password
1079
- # @param sheet_name
1080
- # @return [FilesResult]
1081
- def post_replace(file, text, newtext, opts = {})
1082
- warn "Warning: #post_replace() is deprecated."
1083
- data, _status_code, _headers = post_replace_with_http_info(file, text, newtext, opts)
1084
- return data
1085
- end
1086
-
1087
- #
1088
- #
1089
- # @param file File to upload
1090
- # @param text
1091
- # @param newtext
1092
- # @param [Hash] opts the optional parameters
1093
- # @param password
1094
- # @param sheet_name
1095
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
1096
- def post_replace_with_http_info(file, text, newtext, opts = {})
1097
- warn "Warning: #post_replace_with_http_info() is deprecated."
1098
- if @api_client.config.debugging
1099
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_replace ..."
1100
- end
1101
- @api_client.request_token_if_needed
1102
- # verify the required parameter 'file' is set
1103
- if @api_client.config.client_side_validation && file.nil?
1104
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_replace"
1105
- end
1106
- # verify the required parameter 'text' is set
1107
- if @api_client.config.client_side_validation && text.nil?
1108
- fail ArgumentError, "Missing the required parameter 'text' when calling LightCellsApi.post_replace"
1109
- end
1110
- # verify the required parameter 'color' is set
1111
- if @api_client.config.client_side_validation && newtext.nil?
1112
- fail ArgumentError, "Missing the required parameter 'newtext' when calling LightCellsApi.post_replace"
1113
- end
1114
- # resource path
1115
- local_var_path = "/cells/replace"
1116
-
1117
- # query parameters
1118
- query_params = {}
1119
- query_params[:'text'] = text
1120
- query_params[:'newtext'] = newtext
1121
- query_params[:'password'] = opts[:'password'] if !opts[:'storagpassworde_name'].nil?
1122
- query_params[:'sheetName'] = opts[:'sheet_name'] if !opts[:'sheet_name'].nil?
1123
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
1124
- # header parameters
1125
- header_params = {}
1126
- # HTTP header 'Accept' (if needed)
1127
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1128
- # HTTP header 'Content-Type'
1129
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1130
-
1131
- # form parameters
1132
- form_params = {}
1133
- file.each do |filename , context|
1134
- form_params[filename] = context
1135
- end
1136
-
1137
- # http body (model)
1138
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1139
- post_body = ""
1140
- #auth_names = []
1141
- auth_names = ['JWT']
1142
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1143
- :header_params => header_params,
1144
- :query_params => query_params,
1145
- :form_params => form_params,
1146
- :body => post_body,
1147
- :auth_names => auth_names,
1148
- :return_type => 'FilesResult')
1149
- if @api_client.config.debugging
1150
- @api_client.config.logger.debug "API called: LightCellsApi#post_replace\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1151
- end
1152
- return data, status_code, headers
1153
- end
1154
- #
1155
- #
1156
- # @param file File to upload
1157
- # @param rotate_type
1158
- # @param format
1159
- # @return [FilesResult]
1160
- def post_reverse(file, rotate_type, format, opts = {})
1161
- warn "Warning: #post_reverse() is deprecated."
1162
- data, _status_code, _headers = post_reverse_with_http_info(file, rotate_type, format, opts)
1163
- return data
1164
- end
1165
-
1166
- #
1167
- #
1168
- # @param file File to upload
1169
- # @param rotate_type
1170
- # @param format
1171
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
1172
- def post_reverse_with_http_info(file, rotate_type, format, opts = {})
1173
- warn "Warning: #post_reverse_with_http_info() is deprecated."
1174
- if @api_client.config.debugging
1175
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_reverse ..."
1176
- end
1177
- @api_client.request_token_if_needed
1178
- # verify the required parameter 'file' is set
1179
- if @api_client.config.client_side_validation && file.nil?
1180
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_reverse"
1181
- end
1182
- # verify the required parameter 'rotate_type' is set
1183
- if @api_client.config.client_side_validation && rotate_type.nil?
1184
- fail ArgumentError, "Missing the required parameter 'rotate_type' when calling LightCellsApi.post_reverse"
1185
- end
1186
- # verify the required parameter 'color' is set
1187
- if @api_client.config.client_side_validation && format.nil?
1188
- fail ArgumentError, "Missing the required parameter 'format' when calling LightCellsApi.post_reverse"
1189
- end
1190
- # resource path
1191
- local_var_path = "/cells/reverse"
1192
-
1193
- # query parameters
1194
- query_params = {}
1195
- query_params[:'rotateType'] = rotate_type
1196
- query_params[:'format'] = format
1197
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
1198
- # header parameters
1199
- header_params = {}
1200
- # HTTP header 'Accept' (if needed)
1201
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1202
- # HTTP header 'Content-Type'
1203
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1204
-
1205
- # form parameters
1206
- form_params = {}
1207
- file.each do |filename , context|
1208
- form_params[filename] = context
1209
- end
1210
-
1211
- # http body (model)
1212
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1213
- post_body = ""
1214
- #auth_names = []
1215
- auth_names = ['JWT']
1216
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1217
- :header_params => header_params,
1218
- :query_params => query_params,
1219
- :form_params => form_params,
1220
- :body => post_body,
1221
- :auth_names => auth_names,
1222
- :return_type => 'FilesResult')
1223
- if @api_client.config.debugging
1224
- @api_client.config.logger.debug "API called: LightCellsApi#post_reverse\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1225
- end
1226
- return data, status_code, headers
1227
- end
1228
- #
1229
- #
1230
- # @param file File to upload
1231
- # @param rotate_type
1232
- # @param format
1233
- # @return [FilesResult]
1234
- def post_rotate(file, rotate_type, format, opts = {})
1235
- warn "Warning: #post_rotate() is deprecated."
1236
- data, _status_code, _headers = post_rotate_with_http_info(file, rotate_type, format, opts)
1237
- return data
1238
- end
1239
-
1240
- #
1241
- #
1242
- # @param file File to upload
1243
- # @param rotate_type
1244
- # @param format
1245
- # @return [Array<(FilesResult, Fixnum, Hash)>] FilesResult data, response status code and response headers
1246
- def post_rotate_with_http_info(file, rotate_type, format, opts = {})
1247
- warn "Warning: #post_rotate_with_http_info() is deprecated."
1248
- if @api_client.config.debugging
1249
- @api_client.config.logger.debug "Calling API: LightCellsApi.post_rotate ..."
1250
- end
1251
- @api_client.request_token_if_needed
1252
- # verify the required parameter 'file' is set
1253
- if @api_client.config.client_side_validation && file.nil?
1254
- fail ArgumentError, "Missing the required parameter 'file' when calling LightCellsApi.post_rotate"
1255
- end
1256
- # verify the required parameter 'rotate_type' is set
1257
- if @api_client.config.client_side_validation && rotate_type.nil?
1258
- fail ArgumentError, "Missing the required parameter 'rotate_type' when calling LightCellsApi.post_rotate"
1259
- end
1260
- # verify the required parameter 'color' is set
1261
- if @api_client.config.client_side_validation && format.nil?
1262
- fail ArgumentError, "Missing the required parameter 'format' when calling LightCellsApi.post_rotate"
1263
- end
1264
- # resource path
1265
- local_var_path = "/cells/rotate"
1266
-
1267
- # query parameters
1268
- query_params = {}
1269
- query_params[:'rotateType'] = rotate_type
1270
- query_params[:'format'] = format
1271
- query_params[:'checkExcelRestriction'] = opts[:'check_excel_restriction'] if !opts[:'check_excel_restriction'].nil?
1272
- # header parameters
1273
- header_params = {}
1274
- # HTTP header 'Accept' (if needed)
1275
- header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1276
- # HTTP header 'Content-Type'
1277
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1278
-
1279
- # form parameters
1280
- form_params = {}
1281
- file.each do |filename , context|
1282
- form_params[filename] = context
1283
- end
1284
-
1285
- # http body (model)
1286
- header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
1287
- post_body = ""
1288
- #auth_names = []
1289
- auth_names = ['JWT']
1290
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1291
- :header_params => header_params,
1292
- :query_params => query_params,
1293
- :form_params => form_params,
1294
- :body => post_body,
1295
- :auth_names => auth_names,
1296
- :return_type => 'FilesResult')
1297
- if @api_client.config.debugging
1298
- @api_client.config.logger.debug "API called: LightCellsApi#post_reverse\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1299
- end
1300
- return data, status_code, headers
1301
- end
1302
-
1303
- end
1304
- end