aspose_cells_cloud 25.7.1 → 25.8
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.
- checksums.yaml +4 -4
- data/README.md +36 -11
- data/lib/aspose_cells_cloud/api/cells_api.rb +79 -0
- data/lib/aspose_cells_cloud/models/aggregate_result_by_color.rb +294 -0
- data/lib/aspose_cells_cloud/models/aggregate_result_by_color_response.rb +234 -0
- data/lib/aspose_cells_cloud/models/spreadsheet_template.rb +198 -0
- data/lib/aspose_cells_cloud/requests/add_worksheet_to_spreadsheet_request.rb +162 -0
- data/lib/aspose_cells_cloud/requests/aggregate_cells_by_color_request.rb +154 -0
- data/lib/aspose_cells_cloud/requests/compress_spreadsheet_request.rb +150 -0
- data/lib/aspose_cells_cloud/requests/convert_chart_to_image_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_chart_to_pdf_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_range_to_csv_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_range_to_html_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_range_to_image_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_range_to_json_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_range_to_pdf_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_spreadsheet_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_table_to_csv_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_table_to_html_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_table_to_image_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_table_to_json_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_table_to_pdf_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_worksheet_to_image_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/convert_worksheet_to_pdf_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/create_spreadsheet_request.rb +139 -0
- data/lib/aspose_cells_cloud/requests/delete_spreadsheet_blank_columns_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/delete_spreadsheet_blank_rows_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/delete_spreadsheet_blank_worksheets_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/delete_worksheet_from_spreadsheet_request.rb +150 -0
- data/lib/aspose_cells_cloud/requests/import_data_into_spreadsheet_request.rb +208 -0
- data/lib/aspose_cells_cloud/requests/math_calculate_request.rb +162 -0
- data/lib/aspose_cells_cloud/requests/move_worksheet_in_spreadsheet_request.rb +162 -0
- data/lib/aspose_cells_cloud/requests/protect_spreadsheet_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/put_workbook_background_request.rb +4 -2
- data/lib/aspose_cells_cloud/requests/put_worksheet_background_request.rb +2 -2
- data/lib/aspose_cells_cloud/requests/rename_worksheet_in_spreadsheet_request.rb +162 -0
- data/lib/aspose_cells_cloud/requests/replace_spreadsheet_content_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/sawp_range_request.rb +186 -0
- data/lib/aspose_cells_cloud/requests/search_spreadsheet_broken_links_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/search_spreadsheet_content_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/split_spreadsheet_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/unprotect_spreadsheet_request.rb +3 -1
- data/lib/aspose_cells_cloud/requests/upload_file_request.rb +3 -1
- data/lib/aspose_cells_cloud/version.rb +1 -1
- data/lib/aspose_cells_cloud.rb +13 -0
- metadata +15 -2
@@ -0,0 +1,154 @@
|
|
1
|
+
=begin
|
2
|
+
--------------------------------------------------------------------------------------------------------------------
|
3
|
+
<copyright company="Aspose" file="AggregateCellsByColor_request.rb.cs">
|
4
|
+
Copyright (c) 2025 Aspose.Cells Cloud
|
5
|
+
</copyright>
|
6
|
+
<summary>
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
9
|
+
in the Software without restriction, including without limitation the rights
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
12
|
+
furnished to do so, subject to the following conditions:
|
13
|
+
|
14
|
+
The above copyright notice and this permission notice shall be included in all
|
15
|
+
copies or substantial portions of the Software.
|
16
|
+
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
23
|
+
SOFTWARE.
|
24
|
+
</summary>
|
25
|
+
--------------------------------------------------------------------------------------------------------------------
|
26
|
+
=end
|
27
|
+
|
28
|
+
|
29
|
+
require "uri"
|
30
|
+
|
31
|
+
module AsposeCellsCloud
|
32
|
+
class AggregateCellsByColorRequest
|
33
|
+
|
34
|
+
attr_accessor :spreadsheet
|
35
|
+
attr_accessor :worksheet
|
36
|
+
attr_accessor :range
|
37
|
+
attr_accessor :operation
|
38
|
+
attr_accessor :color_position
|
39
|
+
attr_accessor :regoin
|
40
|
+
attr_accessor :password
|
41
|
+
|
42
|
+
def initialize(attributes = {})
|
43
|
+
return unless attributes.is_a?(Hash)
|
44
|
+
|
45
|
+
# convert string to symbol for hash key
|
46
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
47
|
+
|
48
|
+
if attributes.has_key?(:'Spreadsheet')
|
49
|
+
self.spreadsheet = attributes[:'Spreadsheet']
|
50
|
+
end
|
51
|
+
|
52
|
+
if attributes.has_key?(:'worksheet')
|
53
|
+
self.worksheet = attributes[:'worksheet']
|
54
|
+
end
|
55
|
+
|
56
|
+
if attributes.has_key?(:'range')
|
57
|
+
self.range = attributes[:'range']
|
58
|
+
end
|
59
|
+
|
60
|
+
if attributes.has_key?(:'operation')
|
61
|
+
self.operation = attributes[:'operation']
|
62
|
+
end
|
63
|
+
|
64
|
+
if attributes.has_key?(:'colorPosition')
|
65
|
+
self.color_position = attributes[:'colorPosition']
|
66
|
+
end
|
67
|
+
|
68
|
+
if attributes.has_key?(:'regoin')
|
69
|
+
self.regoin = attributes[:'regoin']
|
70
|
+
end
|
71
|
+
|
72
|
+
if attributes.has_key?(:'password')
|
73
|
+
self.password = attributes[:'password']
|
74
|
+
end
|
75
|
+
|
76
|
+
end
|
77
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
78
|
+
def self.attribute_map
|
79
|
+
{
|
80
|
+
:'spreadsheet' => :'Spreadsheet',
|
81
|
+
:'worksheet' => :'worksheet',
|
82
|
+
:'range' => :'range',
|
83
|
+
:'operation' => :'operation',
|
84
|
+
:'color_position' => :'colorPosition',
|
85
|
+
:'regoin' => :'regoin',
|
86
|
+
:'password' => :'password'
|
87
|
+
}
|
88
|
+
end
|
89
|
+
|
90
|
+
# Attribute type mapping.
|
91
|
+
def self.swagger_types
|
92
|
+
{
|
93
|
+
:'spreadsheet' => :'String',
|
94
|
+
:'worksheet' => :'String',
|
95
|
+
:'range' => :'String',
|
96
|
+
:'operation' => :'String',
|
97
|
+
:'color_position' => :'String',
|
98
|
+
:'regoin' => :'String',
|
99
|
+
:'password' => :'String'
|
100
|
+
}
|
101
|
+
end
|
102
|
+
|
103
|
+
def create_http_request(api_client,opts = {})
|
104
|
+
if api_client.config.debugging
|
105
|
+
api_client.config.logger.debug "Calling API: CellsApi.aggregate_cells_by_color ..."
|
106
|
+
end
|
107
|
+
api_client.request_token_if_needed
|
108
|
+
# verify the required parameter 'spreadsheet' is set
|
109
|
+
if api_client.config.client_side_validation && spreadsheet.nil?
|
110
|
+
fail ArgumentError, "Missing the required parameter 'spreadsheet' when calling CellsApi.aggregate_cells_by_color "
|
111
|
+
end
|
112
|
+
|
113
|
+
# resource path
|
114
|
+
local_var_path = "v4.0/cells/calculate/aggergate/color"
|
115
|
+
# query parameters
|
116
|
+
query_params = {}
|
117
|
+
query_params[:'worksheet'] = self.worksheet if !self.worksheet.nil?
|
118
|
+
query_params[:'range'] = self.range if !self.range.nil?
|
119
|
+
query_params[:'operation'] = self.operation if !self.operation.nil?
|
120
|
+
query_params[:'colorPosition'] = self.color_position if !self.color_position.nil?
|
121
|
+
query_params[:'regoin'] = self.regoin if !self.regoin.nil?
|
122
|
+
query_params[:'password'] = self.password if !self.password.nil?
|
123
|
+
|
124
|
+
# header parameters
|
125
|
+
header_params = {}
|
126
|
+
# HTTP header 'Accept' (if needed)
|
127
|
+
header_params['Accept'] = api_client.select_header_accept(['application/json'])
|
128
|
+
# HTTP header 'Content-Type'
|
129
|
+
header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
|
130
|
+
|
131
|
+
# form parameters
|
132
|
+
form_params = {}
|
133
|
+
post_body = nil
|
134
|
+
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
135
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
136
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
137
|
+
end
|
138
|
+
|
139
|
+
#auth_names = []
|
140
|
+
auth_names = ['JWT']
|
141
|
+
data, status_code, headers = api_client.call_api(:PUT, local_var_path,
|
142
|
+
:header_params => header_params,
|
143
|
+
:query_params => query_params,
|
144
|
+
:form_params => form_params,
|
145
|
+
:body => post_body,
|
146
|
+
:auth_names => auth_names,
|
147
|
+
:return_type => 'AggregateResultByColorResponse')
|
148
|
+
if api_client.config.debugging
|
149
|
+
api_client.config.logger.debug "API called: Specification.Name>Api.aggregate_cells_by_color\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
150
|
+
end
|
151
|
+
return data, status_code, headers
|
152
|
+
end
|
153
|
+
end
|
154
|
+
end
|
@@ -0,0 +1,150 @@
|
|
1
|
+
=begin
|
2
|
+
--------------------------------------------------------------------------------------------------------------------
|
3
|
+
<copyright company="Aspose" file="CompressSpreadsheet_request.rb.cs">
|
4
|
+
Copyright (c) 2025 Aspose.Cells Cloud
|
5
|
+
</copyright>
|
6
|
+
<summary>
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
9
|
+
in the Software without restriction, including without limitation the rights
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
12
|
+
furnished to do so, subject to the following conditions:
|
13
|
+
|
14
|
+
The above copyright notice and this permission notice shall be included in all
|
15
|
+
copies or substantial portions of the Software.
|
16
|
+
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
23
|
+
SOFTWARE.
|
24
|
+
</summary>
|
25
|
+
--------------------------------------------------------------------------------------------------------------------
|
26
|
+
=end
|
27
|
+
|
28
|
+
|
29
|
+
require "uri"
|
30
|
+
|
31
|
+
module AsposeCellsCloud
|
32
|
+
class CompressSpreadsheetRequest
|
33
|
+
|
34
|
+
attr_accessor :spreadsheet
|
35
|
+
attr_accessor :level
|
36
|
+
attr_accessor :out_path
|
37
|
+
attr_accessor :out_storage_name
|
38
|
+
attr_accessor :regoin
|
39
|
+
attr_accessor :password
|
40
|
+
|
41
|
+
def initialize(attributes = {})
|
42
|
+
return unless attributes.is_a?(Hash)
|
43
|
+
|
44
|
+
# convert string to symbol for hash key
|
45
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
46
|
+
|
47
|
+
if attributes.has_key?(:'Spreadsheet')
|
48
|
+
self.spreadsheet = attributes[:'Spreadsheet']
|
49
|
+
end
|
50
|
+
|
51
|
+
if attributes.has_key?(:'level')
|
52
|
+
self.level = attributes[:'level']
|
53
|
+
end
|
54
|
+
|
55
|
+
if attributes.has_key?(:'outPath')
|
56
|
+
self.out_path = attributes[:'outPath']
|
57
|
+
end
|
58
|
+
|
59
|
+
if attributes.has_key?(:'outStorageName')
|
60
|
+
self.out_storage_name = attributes[:'outStorageName']
|
61
|
+
end
|
62
|
+
|
63
|
+
if attributes.has_key?(:'regoin')
|
64
|
+
self.regoin = attributes[:'regoin']
|
65
|
+
end
|
66
|
+
|
67
|
+
if attributes.has_key?(:'password')
|
68
|
+
self.password = attributes[:'password']
|
69
|
+
end
|
70
|
+
|
71
|
+
end
|
72
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
73
|
+
def self.attribute_map
|
74
|
+
{
|
75
|
+
:'spreadsheet' => :'Spreadsheet',
|
76
|
+
:'level' => :'level',
|
77
|
+
:'out_path' => :'outPath',
|
78
|
+
:'out_storage_name' => :'outStorageName',
|
79
|
+
:'regoin' => :'regoin',
|
80
|
+
:'password' => :'password'
|
81
|
+
}
|
82
|
+
end
|
83
|
+
|
84
|
+
# Attribute type mapping.
|
85
|
+
def self.swagger_types
|
86
|
+
{
|
87
|
+
:'spreadsheet' => :'String',
|
88
|
+
:'level' => :'Integer',
|
89
|
+
:'out_path' => :'String',
|
90
|
+
:'out_storage_name' => :'String',
|
91
|
+
:'regoin' => :'String',
|
92
|
+
:'password' => :'String'
|
93
|
+
}
|
94
|
+
end
|
95
|
+
|
96
|
+
def create_http_request(api_client,opts = {})
|
97
|
+
if api_client.config.debugging
|
98
|
+
api_client.config.logger.debug "Calling API: CellsApi.compress_spreadsheet ..."
|
99
|
+
end
|
100
|
+
api_client.request_token_if_needed
|
101
|
+
# verify the required parameter 'spreadsheet' is set
|
102
|
+
if api_client.config.client_side_validation && spreadsheet.nil?
|
103
|
+
fail ArgumentError, "Missing the required parameter 'spreadsheet' when calling CellsApi.compress_spreadsheet "
|
104
|
+
end
|
105
|
+
# verify the required parameter 'level' is set
|
106
|
+
if api_client.config.client_side_validation && level.nil?
|
107
|
+
fail ArgumentError, "Missing the required parameter 'level' when calling CellsApi.compress_spreadsheet "
|
108
|
+
end
|
109
|
+
|
110
|
+
# resource path
|
111
|
+
local_var_path = "v4.0/cells/spreadsheet/compress"
|
112
|
+
# query parameters
|
113
|
+
query_params = {}
|
114
|
+
query_params[:'level'] = self.level if !self.level.nil?
|
115
|
+
query_params[:'outPath'] = self.out_path if !self.out_path.nil?
|
116
|
+
query_params[:'outStorageName'] = self.out_storage_name if !self.out_storage_name.nil?
|
117
|
+
query_params[:'regoin'] = self.regoin if !self.regoin.nil?
|
118
|
+
query_params[:'password'] = self.password if !self.password.nil?
|
119
|
+
|
120
|
+
# header parameters
|
121
|
+
header_params = {}
|
122
|
+
# HTTP header 'Accept' (if needed)
|
123
|
+
header_params['Accept'] = api_client.select_header_accept(['application/json'])
|
124
|
+
# HTTP header 'Content-Type'
|
125
|
+
header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
|
126
|
+
|
127
|
+
# form parameters
|
128
|
+
form_params = {}
|
129
|
+
post_body = nil
|
130
|
+
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
131
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
132
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
133
|
+
end
|
134
|
+
|
135
|
+
#auth_names = []
|
136
|
+
auth_names = ['JWT']
|
137
|
+
data, status_code, headers = api_client.call_api(:PUT, local_var_path,
|
138
|
+
:header_params => header_params,
|
139
|
+
:query_params => query_params,
|
140
|
+
:form_params => form_params,
|
141
|
+
:body => post_body,
|
142
|
+
:auth_names => auth_names,
|
143
|
+
:return_type => 'File')
|
144
|
+
if api_client.config.debugging
|
145
|
+
api_client.config.logger.debug "API called: Specification.Name>Api.compress_spreadsheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
146
|
+
end
|
147
|
+
return data, status_code, headers
|
148
|
+
end
|
149
|
+
end
|
150
|
+
end
|
@@ -160,7 +160,9 @@ module AsposeCellsCloud
|
|
160
160
|
form_params = {}
|
161
161
|
post_body = nil
|
162
162
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
163
|
-
|
163
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
164
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
165
|
+
end
|
164
166
|
|
165
167
|
#auth_names = []
|
166
168
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -168,7 +168,9 @@ module AsposeCellsCloud
|
|
168
168
|
form_params = {}
|
169
169
|
post_body = nil
|
170
170
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
171
|
-
|
171
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
172
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
173
|
+
end
|
172
174
|
|
173
175
|
#auth_names = []
|
174
176
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -136,7 +136,9 @@ module AsposeCellsCloud
|
|
136
136
|
form_params = {}
|
137
137
|
post_body = nil
|
138
138
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
139
|
-
|
139
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
140
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
141
|
+
end
|
140
142
|
|
141
143
|
#auth_names = []
|
142
144
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -160,7 +160,9 @@ module AsposeCellsCloud
|
|
160
160
|
form_params = {}
|
161
161
|
post_body = nil
|
162
162
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
163
|
-
|
163
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
164
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
165
|
+
end
|
164
166
|
|
165
167
|
#auth_names = []
|
166
168
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -148,7 +148,9 @@ module AsposeCellsCloud
|
|
148
148
|
form_params = {}
|
149
149
|
post_body = nil
|
150
150
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
151
|
-
|
151
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
152
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
153
|
+
end
|
152
154
|
|
153
155
|
#auth_names = []
|
154
156
|
auth_names = ['JWT']
|
@@ -136,7 +136,9 @@ module AsposeCellsCloud
|
|
136
136
|
form_params = {}
|
137
137
|
post_body = nil
|
138
138
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
139
|
-
|
139
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
140
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
141
|
+
end
|
140
142
|
|
141
143
|
#auth_names = []
|
142
144
|
auth_names = ['JWT']
|
@@ -0,0 +1,139 @@
|
|
1
|
+
=begin
|
2
|
+
--------------------------------------------------------------------------------------------------------------------
|
3
|
+
<copyright company="Aspose" file="CreateSpreadsheet_request.rb.cs">
|
4
|
+
Copyright (c) 2025 Aspose.Cells Cloud
|
5
|
+
</copyright>
|
6
|
+
<summary>
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
9
|
+
in the Software without restriction, including without limitation the rights
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
12
|
+
furnished to do so, subject to the following conditions:
|
13
|
+
|
14
|
+
The above copyright notice and this permission notice shall be included in all
|
15
|
+
copies or substantial portions of the Software.
|
16
|
+
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
23
|
+
SOFTWARE.
|
24
|
+
</summary>
|
25
|
+
--------------------------------------------------------------------------------------------------------------------
|
26
|
+
=end
|
27
|
+
|
28
|
+
|
29
|
+
require "uri"
|
30
|
+
|
31
|
+
module AsposeCellsCloud
|
32
|
+
class CreateSpreadsheetRequest
|
33
|
+
|
34
|
+
attr_accessor :format
|
35
|
+
attr_accessor :template
|
36
|
+
attr_accessor :out_path
|
37
|
+
attr_accessor :out_storage_name
|
38
|
+
attr_accessor :regoin
|
39
|
+
attr_accessor :password
|
40
|
+
|
41
|
+
def initialize(attributes = {})
|
42
|
+
return unless attributes.is_a?(Hash)
|
43
|
+
|
44
|
+
# convert string to symbol for hash key
|
45
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
46
|
+
|
47
|
+
if attributes.has_key?(:'format')
|
48
|
+
self.format = attributes[:'format']
|
49
|
+
end
|
50
|
+
|
51
|
+
if attributes.has_key?(:'template')
|
52
|
+
self.template = attributes[:'template']
|
53
|
+
end
|
54
|
+
|
55
|
+
if attributes.has_key?(:'outPath')
|
56
|
+
self.out_path = attributes[:'outPath']
|
57
|
+
end
|
58
|
+
|
59
|
+
if attributes.has_key?(:'outStorageName')
|
60
|
+
self.out_storage_name = attributes[:'outStorageName']
|
61
|
+
end
|
62
|
+
|
63
|
+
if attributes.has_key?(:'regoin')
|
64
|
+
self.regoin = attributes[:'regoin']
|
65
|
+
end
|
66
|
+
|
67
|
+
if attributes.has_key?(:'password')
|
68
|
+
self.password = attributes[:'password']
|
69
|
+
end
|
70
|
+
|
71
|
+
end
|
72
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
73
|
+
def self.attribute_map
|
74
|
+
{
|
75
|
+
:'format' => :'format',
|
76
|
+
:'template' => :'template',
|
77
|
+
:'out_path' => :'outPath',
|
78
|
+
:'out_storage_name' => :'outStorageName',
|
79
|
+
:'regoin' => :'regoin',
|
80
|
+
:'password' => :'password'
|
81
|
+
}
|
82
|
+
end
|
83
|
+
|
84
|
+
# Attribute type mapping.
|
85
|
+
def self.swagger_types
|
86
|
+
{
|
87
|
+
:'format' => :'String',
|
88
|
+
:'template' => :'String',
|
89
|
+
:'out_path' => :'String',
|
90
|
+
:'out_storage_name' => :'String',
|
91
|
+
:'regoin' => :'String',
|
92
|
+
:'password' => :'String'
|
93
|
+
}
|
94
|
+
end
|
95
|
+
|
96
|
+
def create_http_request(api_client,opts = {})
|
97
|
+
if api_client.config.debugging
|
98
|
+
api_client.config.logger.debug "Calling API: CellsApi.create_spreadsheet ..."
|
99
|
+
end
|
100
|
+
api_client.request_token_if_needed
|
101
|
+
|
102
|
+
# resource path
|
103
|
+
local_var_path = "v4.0/cells/spreadsheet/create"
|
104
|
+
# query parameters
|
105
|
+
query_params = {}
|
106
|
+
query_params[:'format'] = self.format if !self.format.nil?
|
107
|
+
query_params[:'template'] = self.template if !self.template.nil?
|
108
|
+
query_params[:'outPath'] = self.out_path if !self.out_path.nil?
|
109
|
+
query_params[:'outStorageName'] = self.out_storage_name if !self.out_storage_name.nil?
|
110
|
+
query_params[:'regoin'] = self.regoin if !self.regoin.nil?
|
111
|
+
query_params[:'password'] = self.password if !self.password.nil?
|
112
|
+
|
113
|
+
# header parameters
|
114
|
+
header_params = {}
|
115
|
+
# HTTP header 'Accept' (if needed)
|
116
|
+
header_params['Accept'] = api_client.select_header_accept(['application/json'])
|
117
|
+
# HTTP header 'Content-Type'
|
118
|
+
header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
|
119
|
+
|
120
|
+
# form parameters
|
121
|
+
form_params = {}
|
122
|
+
post_body = nil
|
123
|
+
|
124
|
+
#auth_names = []
|
125
|
+
auth_names = ['JWT']
|
126
|
+
data, status_code, headers = api_client.call_api(:PUT, local_var_path,
|
127
|
+
:header_params => header_params,
|
128
|
+
:query_params => query_params,
|
129
|
+
:form_params => form_params,
|
130
|
+
:body => post_body,
|
131
|
+
:auth_names => auth_names,
|
132
|
+
:return_type => 'File')
|
133
|
+
if api_client.config.debugging
|
134
|
+
api_client.config.logger.debug "API called: Specification.Name>Api.create_spreadsheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
135
|
+
end
|
136
|
+
return data, status_code, headers
|
137
|
+
end
|
138
|
+
end
|
139
|
+
end
|
@@ -116,7 +116,9 @@ module AsposeCellsCloud
|
|
116
116
|
form_params = {}
|
117
117
|
post_body = nil
|
118
118
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
119
|
-
|
119
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
120
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
121
|
+
end
|
120
122
|
|
121
123
|
#auth_names = []
|
122
124
|
auth_names = ['JWT']
|
@@ -116,7 +116,9 @@ module AsposeCellsCloud
|
|
116
116
|
form_params = {}
|
117
117
|
post_body = nil
|
118
118
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
119
|
-
|
119
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
120
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
121
|
+
end
|
120
122
|
|
121
123
|
#auth_names = []
|
122
124
|
auth_names = ['JWT']
|
@@ -116,7 +116,9 @@ module AsposeCellsCloud
|
|
116
116
|
form_params = {}
|
117
117
|
post_body = nil
|
118
118
|
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
119
|
-
|
119
|
+
if !spreadsheet.empty? && File.exist?(spreadsheet )
|
120
|
+
form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
|
121
|
+
end
|
120
122
|
|
121
123
|
#auth_names = []
|
122
124
|
auth_names = ['JWT']
|