aspose_cells_cloud 26.1 → 26.3.1

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.
Files changed (21) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +43 -11
  3. data/lib/aspose_cells_cloud/api/cells_api.rb +83 -4
  4. data/lib/aspose_cells_cloud/requests/accept_all_revisions_in_remote_spreadsheet_request.rb +158 -0
  5. data/lib/aspose_cells_cloud/requests/accept_all_revisions_request.rb +146 -0
  6. data/lib/aspose_cells_cloud/requests/convert_worksheet_to_csv_request.rb +158 -0
  7. data/lib/aspose_cells_cloud/requests/convert_worksheet_to_json_request.rb +158 -0
  8. data/lib/aspose_cells_cloud/requests/decompose_user_task_request.rb +1 -1
  9. data/lib/aspose_cells_cloud/requests/get_merged_cells_in_remoted_worksheet_request.rb +145 -0
  10. data/lib/aspose_cells_cloud/requests/get_merged_cells_in_worksheet_request.rb +134 -0
  11. data/lib/aspose_cells_cloud/requests/get_worksheets_with_local_spreadsheet_request.rb +122 -0
  12. data/lib/aspose_cells_cloud/requests/put_workbook_background_request.rb +3 -3
  13. data/lib/aspose_cells_cloud/requests/put_worksheet_background_request.rb +2 -2
  14. data/lib/aspose_cells_cloud/requests/search_all_text_items_in_remote_spreadsheet_request.rb +138 -0
  15. data/lib/aspose_cells_cloud/requests/search_spreadsheet_all_text_items_request.rb +122 -0
  16. data/lib/aspose_cells_cloud/requests/split_table_request.rb +12 -0
  17. data/lib/aspose_cells_cloud/requests/{translation_spreadsheet_request.rb → translate_spreadsheet_request.rb} +6 -6
  18. data/lib/aspose_cells_cloud/requests/translate_text_file_request.rb +2 -3
  19. data/lib/aspose_cells_cloud/version.rb +1 -1
  20. data/lib/aspose_cells_cloud.rb +10 -1
  21. metadata +12 -3
@@ -0,0 +1,158 @@
1
+ =begin
2
+ --------------------------------------------------------------------------------------------------------------------
3
+ <copyright company="Aspose" file="ConvertWorksheetToCsv_request.rb.cs">
4
+ Copyright (c) 2026 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 ConvertWorksheetToCsvRequest
33
+
34
+ attr_accessor :spreadsheet
35
+ attr_accessor :worksheet
36
+ attr_accessor :out_path
37
+ attr_accessor :out_storage_name
38
+ attr_accessor :fonts_location
39
+ attr_accessor :region
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?(:'outPath')
57
+ self.out_path = attributes[:'outPath']
58
+ end
59
+
60
+ if attributes.has_key?(:'outStorageName')
61
+ self.out_storage_name = attributes[:'outStorageName']
62
+ end
63
+
64
+ if attributes.has_key?(:'fontsLocation')
65
+ self.fonts_location = attributes[:'fontsLocation']
66
+ end
67
+
68
+ if attributes.has_key?(:'region')
69
+ self.region = attributes[:'region']
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
+ :'out_path' => :'outPath',
83
+ :'out_storage_name' => :'outStorageName',
84
+ :'fonts_location' => :'fontsLocation',
85
+ :'region' => :'region',
86
+ :'password' => :'password'
87
+ }
88
+ end
89
+
90
+ # Attribute type mapping.
91
+ def self.swagger_types
92
+ {
93
+ :'spreadsheet' => :'String',
94
+ :'worksheet' => :'String',
95
+ :'out_path' => :'String',
96
+ :'out_storage_name' => :'String',
97
+ :'fonts_location' => :'String',
98
+ :'region' => :'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.convert_worksheet_to_csv ..."
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.convert_worksheet_to_csv "
111
+ end
112
+ # verify the required parameter 'worksheet' is set
113
+ if api_client.config.client_side_validation && worksheet.nil?
114
+ fail ArgumentError, "Missing the required parameter 'worksheet' when calling CellsApi.convert_worksheet_to_csv "
115
+ end
116
+
117
+ # resource path
118
+ local_var_path = "v4.0/cells/convert/worksheet/csv"
119
+ # query parameters
120
+ query_params = {}
121
+ query_params[:'worksheet'] = self.worksheet if !self.worksheet.nil?
122
+ query_params[:'outPath'] = self.out_path if !self.out_path.nil?
123
+ query_params[:'outStorageName'] = self.out_storage_name if !self.out_storage_name.nil?
124
+ query_params[:'fontsLocation'] = self.fonts_location if !self.fonts_location.nil?
125
+ query_params[:'region'] = self.region if !self.region.nil?
126
+ query_params[:'password'] = self.password if !self.password.nil?
127
+
128
+ # header parameters
129
+ header_params = {}
130
+ # HTTP header 'Accept' (if needed)
131
+ header_params['Accept'] = api_client.select_header_accept(['application/json'])
132
+ # HTTP header 'Content-Type'
133
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
134
+
135
+ # form parameters
136
+ form_params = {}
137
+ post_body = nil
138
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
139
+ if !spreadsheet.empty? && File.exist?(spreadsheet )
140
+ form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
141
+ end
142
+
143
+ #auth_names = []
144
+ auth_names = ['JWT']
145
+ data, status_code, headers = api_client.call_api(:PUT, local_var_path,
146
+ :header_params => header_params,
147
+ :query_params => query_params,
148
+ :form_params => form_params,
149
+ :body => post_body,
150
+ :auth_names => auth_names,
151
+ :return_type => 'File')
152
+ if api_client.config.debugging
153
+ api_client.config.logger.debug "API called: Specification.Name>Api.convert_worksheet_to_csv\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
154
+ end
155
+ return data, status_code, headers
156
+ end
157
+ end
158
+ end
@@ -0,0 +1,158 @@
1
+ =begin
2
+ --------------------------------------------------------------------------------------------------------------------
3
+ <copyright company="Aspose" file="ConvertWorksheetToJson_request.rb.cs">
4
+ Copyright (c) 2026 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 ConvertWorksheetToJsonRequest
33
+
34
+ attr_accessor :spreadsheet
35
+ attr_accessor :worksheet
36
+ attr_accessor :out_path
37
+ attr_accessor :out_storage_name
38
+ attr_accessor :fonts_location
39
+ attr_accessor :region
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?(:'outPath')
57
+ self.out_path = attributes[:'outPath']
58
+ end
59
+
60
+ if attributes.has_key?(:'outStorageName')
61
+ self.out_storage_name = attributes[:'outStorageName']
62
+ end
63
+
64
+ if attributes.has_key?(:'fontsLocation')
65
+ self.fonts_location = attributes[:'fontsLocation']
66
+ end
67
+
68
+ if attributes.has_key?(:'region')
69
+ self.region = attributes[:'region']
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
+ :'out_path' => :'outPath',
83
+ :'out_storage_name' => :'outStorageName',
84
+ :'fonts_location' => :'fontsLocation',
85
+ :'region' => :'region',
86
+ :'password' => :'password'
87
+ }
88
+ end
89
+
90
+ # Attribute type mapping.
91
+ def self.swagger_types
92
+ {
93
+ :'spreadsheet' => :'String',
94
+ :'worksheet' => :'String',
95
+ :'out_path' => :'String',
96
+ :'out_storage_name' => :'String',
97
+ :'fonts_location' => :'String',
98
+ :'region' => :'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.convert_worksheet_to_json ..."
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.convert_worksheet_to_json "
111
+ end
112
+ # verify the required parameter 'worksheet' is set
113
+ if api_client.config.client_side_validation && worksheet.nil?
114
+ fail ArgumentError, "Missing the required parameter 'worksheet' when calling CellsApi.convert_worksheet_to_json "
115
+ end
116
+
117
+ # resource path
118
+ local_var_path = "v4.0/cells/convert/worksheet/json"
119
+ # query parameters
120
+ query_params = {}
121
+ query_params[:'worksheet'] = self.worksheet if !self.worksheet.nil?
122
+ query_params[:'outPath'] = self.out_path if !self.out_path.nil?
123
+ query_params[:'outStorageName'] = self.out_storage_name if !self.out_storage_name.nil?
124
+ query_params[:'fontsLocation'] = self.fonts_location if !self.fonts_location.nil?
125
+ query_params[:'region'] = self.region if !self.region.nil?
126
+ query_params[:'password'] = self.password if !self.password.nil?
127
+
128
+ # header parameters
129
+ header_params = {}
130
+ # HTTP header 'Accept' (if needed)
131
+ header_params['Accept'] = api_client.select_header_accept(['application/json'])
132
+ # HTTP header 'Content-Type'
133
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
134
+
135
+ # form parameters
136
+ form_params = {}
137
+ post_body = nil
138
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
139
+ if !spreadsheet.empty? && File.exist?(spreadsheet )
140
+ form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
141
+ end
142
+
143
+ #auth_names = []
144
+ auth_names = ['JWT']
145
+ data, status_code, headers = api_client.call_api(:PUT, local_var_path,
146
+ :header_params => header_params,
147
+ :query_params => query_params,
148
+ :form_params => form_params,
149
+ :body => post_body,
150
+ :auth_names => auth_names,
151
+ :return_type => 'File')
152
+ if api_client.config.debugging
153
+ api_client.config.logger.debug "API called: Specification.Name>Api.convert_worksheet_to_json\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
154
+ end
155
+ return data, status_code, headers
156
+ end
157
+ end
158
+ end
@@ -86,7 +86,6 @@ module AsposeCellsCloud
86
86
  local_var_path = "v4.0/cells/ai/task/decompose"
87
87
  # query parameters
88
88
  query_params = {}
89
- query_params[:'TaskDescription'] = self.task_description if !self.task_description.nil?
90
89
  query_params[:'region'] = self.region if !self.region.nil?
91
90
  query_params[:'password'] = self.password if !self.password.nil?
92
91
 
@@ -100,6 +99,7 @@ module AsposeCellsCloud
100
99
  # form parameters
101
100
  form_params = {}
102
101
  post_body = nil
102
+ post_body = api_client.object_to_http_body(task_description)
103
103
 
104
104
  #auth_names = []
105
105
  auth_names = ['JWT']
@@ -0,0 +1,145 @@
1
+ =begin
2
+ --------------------------------------------------------------------------------------------------------------------
3
+ <copyright company="Aspose" file="GetMergedCellsInRemotedWorksheet_request.rb.cs">
4
+ Copyright (c) 2026 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 GetMergedCellsInRemotedWorksheetRequest
33
+
34
+ attr_accessor :name
35
+ attr_accessor :worksheet
36
+ attr_accessor :folder
37
+ attr_accessor :storage_name
38
+ attr_accessor :region
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?(:'name')
48
+ self.name = attributes[:'name']
49
+ end
50
+
51
+ if attributes.has_key?(:'worksheet')
52
+ self.worksheet = attributes[:'worksheet']
53
+ end
54
+
55
+ if attributes.has_key?(:'folder')
56
+ self.folder = attributes[:'folder']
57
+ end
58
+
59
+ if attributes.has_key?(:'storageName')
60
+ self.storage_name = attributes[:'storageName']
61
+ end
62
+
63
+ if attributes.has_key?(:'region')
64
+ self.region = attributes[:'region']
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
+ :'name' => :'name',
76
+ :'worksheet' => :'worksheet',
77
+ :'folder' => :'folder',
78
+ :'storage_name' => :'storageName',
79
+ :'region' => :'region',
80
+ :'password' => :'password'
81
+ }
82
+ end
83
+
84
+ # Attribute type mapping.
85
+ def self.swagger_types
86
+ {
87
+ :'name' => :'String',
88
+ :'worksheet' => :'String',
89
+ :'folder' => :'String',
90
+ :'storage_name' => :'String',
91
+ :'region' => :'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.get_merged_cells_in_remoted_worksheet ..."
99
+ end
100
+ api_client.request_token_if_needed
101
+ # verify the required parameter 'name' is set
102
+ if api_client.config.client_side_validation && name.nil?
103
+ fail ArgumentError, "Missing the required parameter 'name' when calling CellsApi.get_merged_cells_in_remoted_worksheet "
104
+ end
105
+ # verify the required parameter 'worksheet' is set
106
+ if api_client.config.client_side_validation && worksheet.nil?
107
+ fail ArgumentError, "Missing the required parameter 'worksheet' when calling CellsApi.get_merged_cells_in_remoted_worksheet "
108
+ end
109
+
110
+ # resource path
111
+ local_var_path = "v4.0/cells/{name}/worksheets/{worksheet}/mergedcells".sub('{' + 'name' + '}', name.to_s).sub('{' + 'worksheet' + '}', worksheet.to_s)
112
+ # query parameters
113
+ query_params = {}
114
+ query_params[:'folder'] = self.folder if !self.folder.nil?
115
+ query_params[:'storageName'] = self.storage_name if !self.storage_name.nil?
116
+ query_params[:'region'] = self.region if !self.region.nil?
117
+ query_params[:'password'] = self.password if !self.password.nil?
118
+
119
+ # header parameters
120
+ header_params = {}
121
+ # HTTP header 'Accept' (if needed)
122
+ header_params['Accept'] = api_client.select_header_accept(['application/json'])
123
+ # HTTP header 'Content-Type'
124
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
125
+
126
+ # form parameters
127
+ form_params = {}
128
+ post_body = nil
129
+
130
+ #auth_names = []
131
+ auth_names = ['JWT']
132
+ data, status_code, headers = api_client.call_api(:GET, local_var_path,
133
+ :header_params => header_params,
134
+ :query_params => query_params,
135
+ :form_params => form_params,
136
+ :body => post_body,
137
+ :auth_names => auth_names,
138
+ :return_type => 'Array<CellArea>')
139
+ if api_client.config.debugging
140
+ api_client.config.logger.debug "API called: Specification.Name>Api.get_merged_cells_in_remoted_worksheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
141
+ end
142
+ return data, status_code, headers
143
+ end
144
+ end
145
+ end
@@ -0,0 +1,134 @@
1
+ =begin
2
+ --------------------------------------------------------------------------------------------------------------------
3
+ <copyright company="Aspose" file="GetMergedCellsInWorksheet_request.rb.cs">
4
+ Copyright (c) 2026 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 GetMergedCellsInWorksheetRequest
33
+
34
+ attr_accessor :spreadsheet
35
+ attr_accessor :worksheet
36
+ attr_accessor :region
37
+ attr_accessor :password
38
+
39
+ def initialize(attributes = {})
40
+ return unless attributes.is_a?(Hash)
41
+
42
+ # convert string to symbol for hash key
43
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
44
+
45
+ if attributes.has_key?(:'Spreadsheet')
46
+ self.spreadsheet = attributes[:'Spreadsheet']
47
+ end
48
+
49
+ if attributes.has_key?(:'worksheet')
50
+ self.worksheet = attributes[:'worksheet']
51
+ end
52
+
53
+ if attributes.has_key?(:'region')
54
+ self.region = attributes[:'region']
55
+ end
56
+
57
+ if attributes.has_key?(:'password')
58
+ self.password = attributes[:'password']
59
+ end
60
+
61
+ end
62
+ # Attribute mapping from ruby-style variable name to JSON key.
63
+ def self.attribute_map
64
+ {
65
+ :'spreadsheet' => :'Spreadsheet',
66
+ :'worksheet' => :'worksheet',
67
+ :'region' => :'region',
68
+ :'password' => :'password'
69
+ }
70
+ end
71
+
72
+ # Attribute type mapping.
73
+ def self.swagger_types
74
+ {
75
+ :'spreadsheet' => :'String',
76
+ :'worksheet' => :'String',
77
+ :'region' => :'String',
78
+ :'password' => :'String'
79
+ }
80
+ end
81
+
82
+ def create_http_request(api_client,opts = {})
83
+ if api_client.config.debugging
84
+ api_client.config.logger.debug "Calling API: CellsApi.get_merged_cells_in_worksheet ..."
85
+ end
86
+ api_client.request_token_if_needed
87
+ # verify the required parameter 'spreadsheet' is set
88
+ if api_client.config.client_side_validation && spreadsheet.nil?
89
+ fail ArgumentError, "Missing the required parameter 'spreadsheet' when calling CellsApi.get_merged_cells_in_worksheet "
90
+ end
91
+ # verify the required parameter 'worksheet' is set
92
+ if api_client.config.client_side_validation && worksheet.nil?
93
+ fail ArgumentError, "Missing the required parameter 'worksheet' when calling CellsApi.get_merged_cells_in_worksheet "
94
+ end
95
+
96
+ # resource path
97
+ local_var_path = "v4.0/cells/spreadsheet/mergedcells"
98
+ # query parameters
99
+ query_params = {}
100
+ query_params[:'worksheet'] = self.worksheet if !self.worksheet.nil?
101
+ query_params[:'region'] = self.region if !self.region.nil?
102
+ query_params[:'password'] = self.password if !self.password.nil?
103
+
104
+ # header parameters
105
+ header_params = {}
106
+ # HTTP header 'Accept' (if needed)
107
+ header_params['Accept'] = api_client.select_header_accept(['application/json'])
108
+ # HTTP header 'Content-Type'
109
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/json'])
110
+
111
+ # form parameters
112
+ form_params = {}
113
+ post_body = nil
114
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
115
+ if !spreadsheet.empty? && File.exist?(spreadsheet )
116
+ form_params[File.basename(spreadsheet)] = ::File.open(spreadsheet,"r")
117
+ end
118
+
119
+ #auth_names = []
120
+ auth_names = ['JWT']
121
+ data, status_code, headers = api_client.call_api(:PUT, local_var_path,
122
+ :header_params => header_params,
123
+ :query_params => query_params,
124
+ :form_params => form_params,
125
+ :body => post_body,
126
+ :auth_names => auth_names,
127
+ :return_type => 'Array<CellArea>')
128
+ if api_client.config.debugging
129
+ api_client.config.logger.debug "API called: Specification.Name>Api.get_merged_cells_in_worksheet\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
130
+ end
131
+ return data, status_code, headers
132
+ end
133
+ end
134
+ end