aspose_words_cloud 23.1.0 → 23.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (24) hide show
  1. checksums.yaml +4 -4
  2. data/lib/aspose_words_cloud/api/words_api.rb +428 -0
  3. data/lib/aspose_words_cloud/models/requests/delete_structured_document_tag_online_request.rb +211 -0
  4. data/lib/aspose_words_cloud/models/requests/delete_structured_document_tag_request.rb +210 -0
  5. data/lib/aspose_words_cloud/models/requests/get_structured_document_tag_online_request.rb +190 -0
  6. data/lib/aspose_words_cloud/models/requests/get_structured_document_tag_request.rb +189 -0
  7. data/lib/aspose_words_cloud/models/requests/get_structured_document_tags_online_request.rb +179 -0
  8. data/lib/aspose_words_cloud/models/requests/get_structured_document_tags_request.rb +178 -0
  9. data/lib/aspose_words_cloud/models/requests/insert_structured_document_tag_online_request.rb +223 -0
  10. data/lib/aspose_words_cloud/models/requests/insert_structured_document_tag_request.rb +225 -0
  11. data/lib/aspose_words_cloud/models/requests/update_structured_document_tag_online_request.rb +234 -0
  12. data/lib/aspose_words_cloud/models/requests/update_structured_document_tag_request.rb +236 -0
  13. data/lib/aspose_words_cloud/models/responses/insert_structured_document_tag_online_response.rb +46 -0
  14. data/lib/aspose_words_cloud/models/responses/update_structured_document_tag_online_response.rb +46 -0
  15. data/lib/aspose_words_cloud/models/structured_document_tag.rb +564 -0
  16. data/lib/aspose_words_cloud/models/structured_document_tag_collection.rb +216 -0
  17. data/lib/aspose_words_cloud/models/structured_document_tag_insert.rb +564 -0
  18. data/lib/aspose_words_cloud/models/structured_document_tag_list_item.rb +214 -0
  19. data/lib/aspose_words_cloud/models/structured_document_tag_response.rb +214 -0
  20. data/lib/aspose_words_cloud/models/structured_document_tag_update.rb +564 -0
  21. data/lib/aspose_words_cloud/models/structured_document_tags_response.rb +214 -0
  22. data/lib/aspose_words_cloud/version.rb +1 -1
  23. data/lib/aspose_words_cloud.rb +17 -0
  24. metadata +21 -2
@@ -0,0 +1,234 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="update_structured_document_tag_online_request.rb">
3
+ # Copyright (c) 2023 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Request model for update_structured_document_tag_online operation.
30
+ #
31
+ class UpdateStructuredDocumentTagOnlineRequest
32
+ # The document.
33
+ attr_accessor :document
34
+
35
+ # Structured document tag parameters.
36
+ attr_accessor :structured_document_tag
37
+
38
+ # Object index.
39
+ attr_accessor :index
40
+
41
+ # The path to the node in the document tree.
42
+ attr_accessor :node_path
43
+
44
+ # Encoding that will be used to load an HTML (or TXT) document if the encoding is not specified in HTML.
45
+ attr_accessor :load_encoding
46
+
47
+ # Password of protected Word document. Use the parameter to pass a password via SDK. SDK encrypts it automatically. We don't recommend to use the parameter to pass a plain password for direct call of API.
48
+ attr_accessor :password
49
+
50
+ # Password of protected Word document. Use the parameter to pass an encrypted password for direct calls of API. See SDK code for encyption details.
51
+ attr_accessor :encrypted_password
52
+
53
+ # Result path of the document after the operation. If this parameter is omitted then result of the operation will be saved as the source document.
54
+ attr_accessor :dest_file_name
55
+
56
+ # Initials of the author to use for revisions.If you set this parameter and then make some changes to the document programmatically, save the document and later open the document in MS Word you will see these changes as revisions.
57
+ attr_accessor :revision_author
58
+
59
+ # The date and time to use for revisions.
60
+ attr_accessor :revision_date_time
61
+
62
+ #
63
+ # Initializes a new instance.
64
+ # @param document The document.
65
+ # @param structured_document_tag Structured document tag parameters.
66
+ # @param index Object index.
67
+ # @param node_path The path to the node in the document tree.
68
+ # @param load_encoding Encoding that will be used to load an HTML (or TXT) document if the encoding is not specified in HTML.
69
+ # @param password Password of protected Word document. Use the parameter to pass a password via SDK. SDK encrypts it automatically. We don't recommend to use the parameter to pass a plain password for direct call of API.
70
+ # @param encrypted_password Password of protected Word document. Use the parameter to pass an encrypted password for direct calls of API. See SDK code for encyption details.
71
+ # @param dest_file_name Result path of the document after the operation. If this parameter is omitted then result of the operation will be saved as the source document.
72
+ # @param revision_author Initials of the author to use for revisions.If you set this parameter and then make some changes to the document programmatically, save the document and later open the document in MS Word you will see these changes as revisions.
73
+ # @param revision_date_time The date and time to use for revisions.
74
+
75
+ def initialize(document:, structured_document_tag:, index:, node_path: nil, load_encoding: nil, password: nil, encrypted_password: nil, dest_file_name: nil, revision_author: nil, revision_date_time: nil)
76
+ self.document = document
77
+ self.structured_document_tag = structured_document_tag
78
+ self.index = index
79
+ self.node_path = node_path
80
+ self.load_encoding = load_encoding
81
+ self.password = password
82
+ self.encrypted_password = encrypted_password
83
+ self.dest_file_name = dest_file_name
84
+ self.revision_author = revision_author
85
+ self.revision_date_time = revision_date_time
86
+ end
87
+
88
+ # Creating batch part from request
89
+ def to_batch_part(api_client, requestId, parentRequestId = nil)
90
+ # verify the required parameter 'document' is set
91
+ raise ArgumentError, 'Missing the required parameter document when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.document.nil?
92
+ # verify the required parameter 'structured_document_tag' is set
93
+ raise ArgumentError, 'Missing the required parameter structured_document_tag when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.structured_document_tag.nil?
94
+ # verify the required parameter 'index' is set
95
+ raise ArgumentError, 'Missing the required parameter index when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.index.nil?
96
+
97
+ # resource path
98
+ local_var_path = '/words/online/put/{nodePath}/sdt/{index}'[7..-1]
99
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Index') + '}', self.index.nil? ? '' : self.index.to_s)
100
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('NodePath') + '}', self.node_path.nil? ? '' : self.node_path.to_s)
101
+ local_var_path = local_var_path.sub('//', '/')
102
+
103
+ # query parameters
104
+ query_params = {}
105
+ query_params[downcase_first_letter('LoadEncoding')] = self.load_encoding unless self.load_encoding.nil?
106
+ query_params[downcase_first_letter('Password')] = self.password unless self.password.nil?
107
+ query_params[downcase_first_letter('EncryptedPassword')] = self.encrypted_password unless self.encrypted_password.nil?
108
+ query_params[downcase_first_letter('DestFileName')] = self.dest_file_name unless self.dest_file_name.nil?
109
+ query_params[downcase_first_letter('RevisionAuthor')] = self.revision_author unless self.revision_author.nil?
110
+ query_params[downcase_first_letter('RevisionDateTime')] = self.revision_date_time unless self.revision_date_time.nil?
111
+
112
+ if query_params
113
+ query_params.each { |key, value| local_var_path = api_client.add_param_to_query(local_var_path, key, value) }
114
+ end
115
+
116
+ header_params = {}
117
+ # header parameters
118
+ # HTTP header 'Content-Type'
119
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
120
+ header_params['RequestId'] = requestId
121
+
122
+ if parentRequestId != nil
123
+ header_params['DependsOn'] = parentRequestId
124
+ end
125
+
126
+ # form parameters
127
+ form_params = []
128
+ files_content = []
129
+ if self.document.nil?
130
+ raise "Parameter Document is required."
131
+ end
132
+ unless self.document.nil?
133
+ form_params.push({:'Name' => 'document', :'Data' => self.document, :'MimeType' =>'application/octet-stream'})
134
+ end
135
+
136
+ if self.structured_document_tag.nil?
137
+ raise "Parameter StructuredDocumentTag is required."
138
+ end
139
+ unless self.structured_document_tag.nil?
140
+ form_params.push({:'Name' => 'structuredDocumentTag', :'Data' => self.structured_document_tag.to_body.to_json, :'MimeType' =>'application/json'})
141
+ end
142
+
143
+
144
+ # http body (model)
145
+ body = api_client.build_request_body_batch(header_params, form_params, files_content)
146
+ part = ""
147
+ part.concat("PUT".force_encoding('UTF-8'))
148
+ part.concat(" ".force_encoding('UTF-8'))
149
+ part.concat(local_var_path.force_encoding('UTF-8'))
150
+ part.concat(" \r\n".force_encoding('UTF-8'))
151
+
152
+ header_params.each_pair {|key, value| part.concat(key.dup.force_encoding('UTF-8') , ": ".force_encoding('UTF-8'), value.dup.force_encoding('UTF-8'), "\r\n".force_encoding('UTF-8')) }
153
+ part.concat("\r\n".force_encoding('UTF-8'))
154
+ if body
155
+ if body.is_a?(Hash)
156
+ body.each do |key, value|
157
+ part.concat(value, "\r\n")
158
+ end
159
+ else
160
+ part.concat(body)
161
+ end
162
+ end
163
+ part
164
+ end
165
+
166
+ def create_http_request(api_client)
167
+ # verify the required parameter 'document' is set
168
+ raise ArgumentError, 'Missing the required parameter document when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.document.nil?
169
+ # verify the required parameter 'structured_document_tag' is set
170
+ raise ArgumentError, 'Missing the required parameter structured_document_tag when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.structured_document_tag.nil?
171
+ # verify the required parameter 'index' is set
172
+ raise ArgumentError, 'Missing the required parameter index when calling WordsApi.update_structured_document_tag_online' if api_client.config.client_side_validation && self.index.nil?
173
+
174
+ # resource path
175
+ local_var_path = '/words/online/put/{nodePath}/sdt/{index}'[1..-1]
176
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Index') + '}', self.index.nil? ? '' : self.index.to_s)
177
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('NodePath') + '}', self.node_path.nil? ? '' : self.node_path.to_s)
178
+ local_var_path = local_var_path.sub('//', '/')
179
+
180
+ # query parameters
181
+ query_params = {}
182
+ query_params[downcase_first_letter('LoadEncoding')] = self.load_encoding unless self.load_encoding.nil?
183
+ query_params[downcase_first_letter('Password')] = self.password unless self.password.nil?
184
+ query_params[downcase_first_letter('EncryptedPassword')] = self.encrypted_password unless self.encrypted_password.nil?
185
+ query_params[downcase_first_letter('DestFileName')] = self.dest_file_name unless self.dest_file_name.nil?
186
+ query_params[downcase_first_letter('RevisionAuthor')] = self.revision_author unless self.revision_author.nil?
187
+ query_params[downcase_first_letter('RevisionDateTime')] = self.revision_date_time unless self.revision_date_time.nil?
188
+
189
+ # header parameters
190
+ header_params = {}
191
+ # HTTP header 'Content-Type'
192
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
193
+
194
+ # form parameters
195
+ form_params = []
196
+ files_content = []
197
+ if self.document.nil?
198
+ raise "Parameter Document is required."
199
+ end
200
+ unless self.document.nil?
201
+ form_params.push({:'Name' => 'document', :'Data' => self.document, :'MimeType' =>'application/octet-stream'})
202
+ end
203
+
204
+ if self.structured_document_tag.nil?
205
+ raise "Parameter StructuredDocumentTag is required."
206
+ end
207
+ unless self.structured_document_tag.nil?
208
+ form_params.push({:'Name' => 'structuredDocumentTag', :'Data' => self.structured_document_tag.to_body.to_json, :'MimeType' =>'application/json'})
209
+ end
210
+
211
+ body = api_client.build_request_body(header_params, form_params, files_content)
212
+ {
213
+ 'method': :PUT,
214
+ 'path': local_var_path,
215
+ 'header_params': header_params,
216
+ 'query_params': query_params,
217
+ 'body': body,
218
+ 'auth_names': ['JWT']
219
+ }
220
+ end
221
+
222
+ #
223
+ # Helper method to convert first letter to downcase
224
+ #
225
+ def downcase_first_letter(str)
226
+ str[0].downcase + str[1..-1]
227
+ end
228
+
229
+ # Get response type
230
+ def get_response_type
231
+ 'UpdateStructuredDocumentTagOnlineResponse'
232
+ end
233
+ end
234
+ end
@@ -0,0 +1,236 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="update_structured_document_tag_request.rb">
3
+ # Copyright (c) 2023 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Request model for update_structured_document_tag operation.
30
+ #
31
+ class UpdateStructuredDocumentTagRequest
32
+ # The filename of the input document.
33
+ attr_accessor :name
34
+
35
+ # Object index.
36
+ attr_accessor :index
37
+
38
+ # Structured document tag parameters.
39
+ attr_accessor :structured_document_tag
40
+
41
+ # The path to the node in the document tree.
42
+ attr_accessor :node_path
43
+
44
+ # Original document folder.
45
+ attr_accessor :folder
46
+
47
+ # Original document storage.
48
+ attr_accessor :storage
49
+
50
+ # Encoding that will be used to load an HTML (or TXT) document if the encoding is not specified in HTML.
51
+ attr_accessor :load_encoding
52
+
53
+ # Password of protected Word document. Use the parameter to pass a password via SDK. SDK encrypts it automatically. We don't recommend to use the parameter to pass a plain password for direct call of API.
54
+ attr_accessor :password
55
+
56
+ # Password of protected Word document. Use the parameter to pass an encrypted password for direct calls of API. See SDK code for encyption details.
57
+ attr_accessor :encrypted_password
58
+
59
+ # Result path of the document after the operation. If this parameter is omitted then result of the operation will be saved as the source document.
60
+ attr_accessor :dest_file_name
61
+
62
+ # Initials of the author to use for revisions.If you set this parameter and then make some changes to the document programmatically, save the document and later open the document in MS Word you will see these changes as revisions.
63
+ attr_accessor :revision_author
64
+
65
+ # The date and time to use for revisions.
66
+ attr_accessor :revision_date_time
67
+
68
+ #
69
+ # Initializes a new instance.
70
+ # @param name The filename of the input document.
71
+ # @param index Object index.
72
+ # @param structured_document_tag Structured document tag parameters.
73
+ # @param node_path The path to the node in the document tree.
74
+ # @param folder Original document folder.
75
+ # @param storage Original document storage.
76
+ # @param load_encoding Encoding that will be used to load an HTML (or TXT) document if the encoding is not specified in HTML.
77
+ # @param password Password of protected Word document. Use the parameter to pass a password via SDK. SDK encrypts it automatically. We don't recommend to use the parameter to pass a plain password for direct call of API.
78
+ # @param encrypted_password Password of protected Word document. Use the parameter to pass an encrypted password for direct calls of API. See SDK code for encyption details.
79
+ # @param dest_file_name Result path of the document after the operation. If this parameter is omitted then result of the operation will be saved as the source document.
80
+ # @param revision_author Initials of the author to use for revisions.If you set this parameter and then make some changes to the document programmatically, save the document and later open the document in MS Word you will see these changes as revisions.
81
+ # @param revision_date_time The date and time to use for revisions.
82
+
83
+ def initialize(name:, index:, structured_document_tag:, node_path: nil, folder: nil, storage: nil, load_encoding: nil, password: nil, encrypted_password: nil, dest_file_name: nil, revision_author: nil, revision_date_time: nil)
84
+ self.name = name
85
+ self.index = index
86
+ self.structured_document_tag = structured_document_tag
87
+ self.node_path = node_path
88
+ self.folder = folder
89
+ self.storage = storage
90
+ self.load_encoding = load_encoding
91
+ self.password = password
92
+ self.encrypted_password = encrypted_password
93
+ self.dest_file_name = dest_file_name
94
+ self.revision_author = revision_author
95
+ self.revision_date_time = revision_date_time
96
+ end
97
+
98
+ # Creating batch part from request
99
+ def to_batch_part(api_client, requestId, parentRequestId = nil)
100
+ # verify the required parameter 'name' is set
101
+ raise ArgumentError, 'Missing the required parameter name when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.name.nil?
102
+ # verify the required parameter 'index' is set
103
+ raise ArgumentError, 'Missing the required parameter index when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.index.nil?
104
+ # verify the required parameter 'structured_document_tag' is set
105
+ raise ArgumentError, 'Missing the required parameter structured_document_tag when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.structured_document_tag.nil?
106
+
107
+ # resource path
108
+ local_var_path = '/words/{name}/{nodePath}/sdt/{index}'[7..-1]
109
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Name') + '}', self.name.nil? ? '' : self.name.to_s)
110
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Index') + '}', self.index.nil? ? '' : self.index.to_s)
111
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('NodePath') + '}', self.node_path.nil? ? '' : self.node_path.to_s)
112
+ local_var_path = local_var_path.sub('//', '/')
113
+
114
+ # query parameters
115
+ query_params = {}
116
+ query_params[downcase_first_letter('Folder')] = self.folder unless self.folder.nil?
117
+ query_params[downcase_first_letter('Storage')] = self.storage unless self.storage.nil?
118
+ query_params[downcase_first_letter('LoadEncoding')] = self.load_encoding unless self.load_encoding.nil?
119
+ query_params[downcase_first_letter('Password')] = self.password unless self.password.nil?
120
+ query_params[downcase_first_letter('EncryptedPassword')] = self.encrypted_password unless self.encrypted_password.nil?
121
+ query_params[downcase_first_letter('DestFileName')] = self.dest_file_name unless self.dest_file_name.nil?
122
+ query_params[downcase_first_letter('RevisionAuthor')] = self.revision_author unless self.revision_author.nil?
123
+ query_params[downcase_first_letter('RevisionDateTime')] = self.revision_date_time unless self.revision_date_time.nil?
124
+
125
+ if query_params
126
+ query_params.each { |key, value| local_var_path = api_client.add_param_to_query(local_var_path, key, value) }
127
+ end
128
+
129
+ header_params = {}
130
+ # header parameters
131
+ # HTTP header 'Content-Type'
132
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/xml', 'application/json'])
133
+ header_params['RequestId'] = requestId
134
+
135
+ if parentRequestId != nil
136
+ header_params['DependsOn'] = parentRequestId
137
+ end
138
+
139
+ # form parameters
140
+ form_params = []
141
+ files_content = []
142
+ if self.structured_document_tag.nil?
143
+ raise "Parameter StructuredDocumentTag is required."
144
+ end
145
+ unless self.structured_document_tag.nil?
146
+ form_params.push({:'Name' => 'structuredDocumentTag', :'Data' => self.structured_document_tag.to_body.to_json, :'MimeType' =>'application/json'})
147
+ end
148
+
149
+
150
+ # http body (model)
151
+ body = api_client.build_request_body_batch(header_params, form_params, files_content)
152
+ part = ""
153
+ part.concat("PUT".force_encoding('UTF-8'))
154
+ part.concat(" ".force_encoding('UTF-8'))
155
+ part.concat(local_var_path.force_encoding('UTF-8'))
156
+ part.concat(" \r\n".force_encoding('UTF-8'))
157
+
158
+ header_params.each_pair {|key, value| part.concat(key.dup.force_encoding('UTF-8') , ": ".force_encoding('UTF-8'), value.dup.force_encoding('UTF-8'), "\r\n".force_encoding('UTF-8')) }
159
+ part.concat("\r\n".force_encoding('UTF-8'))
160
+ if body
161
+ if body.is_a?(Hash)
162
+ body.each do |key, value|
163
+ part.concat(value, "\r\n")
164
+ end
165
+ else
166
+ part.concat(body)
167
+ end
168
+ end
169
+ part
170
+ end
171
+
172
+ def create_http_request(api_client)
173
+ # verify the required parameter 'name' is set
174
+ raise ArgumentError, 'Missing the required parameter name when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.name.nil?
175
+ # verify the required parameter 'index' is set
176
+ raise ArgumentError, 'Missing the required parameter index when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.index.nil?
177
+ # verify the required parameter 'structured_document_tag' is set
178
+ raise ArgumentError, 'Missing the required parameter structured_document_tag when calling WordsApi.update_structured_document_tag' if api_client.config.client_side_validation && self.structured_document_tag.nil?
179
+
180
+ # resource path
181
+ local_var_path = '/words/{name}/{nodePath}/sdt/{index}'[1..-1]
182
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Name') + '}', self.name.nil? ? '' : self.name.to_s)
183
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('Index') + '}', self.index.nil? ? '' : self.index.to_s)
184
+ local_var_path = local_var_path.sub('{' + downcase_first_letter('NodePath') + '}', self.node_path.nil? ? '' : self.node_path.to_s)
185
+ local_var_path = local_var_path.sub('//', '/')
186
+
187
+ # query parameters
188
+ query_params = {}
189
+ query_params[downcase_first_letter('Folder')] = self.folder unless self.folder.nil?
190
+ query_params[downcase_first_letter('Storage')] = self.storage unless self.storage.nil?
191
+ query_params[downcase_first_letter('LoadEncoding')] = self.load_encoding unless self.load_encoding.nil?
192
+ query_params[downcase_first_letter('Password')] = self.password unless self.password.nil?
193
+ query_params[downcase_first_letter('EncryptedPassword')] = self.encrypted_password unless self.encrypted_password.nil?
194
+ query_params[downcase_first_letter('DestFileName')] = self.dest_file_name unless self.dest_file_name.nil?
195
+ query_params[downcase_first_letter('RevisionAuthor')] = self.revision_author unless self.revision_author.nil?
196
+ query_params[downcase_first_letter('RevisionDateTime')] = self.revision_date_time unless self.revision_date_time.nil?
197
+
198
+ # header parameters
199
+ header_params = {}
200
+ # HTTP header 'Content-Type'
201
+ header_params['Content-Type'] = api_client.select_header_content_type(['application/xml', 'application/json'])
202
+
203
+ # form parameters
204
+ form_params = []
205
+ files_content = []
206
+ if self.structured_document_tag.nil?
207
+ raise "Parameter StructuredDocumentTag is required."
208
+ end
209
+ unless self.structured_document_tag.nil?
210
+ form_params.push({:'Name' => 'structuredDocumentTag', :'Data' => self.structured_document_tag.to_body.to_json, :'MimeType' =>'application/json'})
211
+ end
212
+
213
+ body = api_client.build_request_body(header_params, form_params, files_content)
214
+ {
215
+ 'method': :PUT,
216
+ 'path': local_var_path,
217
+ 'header_params': header_params,
218
+ 'query_params': query_params,
219
+ 'body': body,
220
+ 'auth_names': ['JWT']
221
+ }
222
+ end
223
+
224
+ #
225
+ # Helper method to convert first letter to downcase
226
+ #
227
+ def downcase_first_letter(str)
228
+ str[0].downcase + str[1..-1]
229
+ end
230
+
231
+ # Get response type
232
+ def get_response_type
233
+ 'StructuredDocumentTagResponse'
234
+ end
235
+ end
236
+ end
@@ -0,0 +1,46 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="insert_structured_document_tag_online_response.rb">
3
+ # Copyright (c) 2023 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Response model for insert_structured_document_tag_online operation.
30
+ #
31
+ class InsertStructuredDocumentTagOnlineResponse
32
+ # The response model.
33
+ attr_accessor :model
34
+
35
+ # The document after modification.
36
+ attr_accessor :document
37
+
38
+ #
39
+ # Initializes a new instance.
40
+ #
41
+ def initialize()
42
+ self.model = nil
43
+ self.document = nil
44
+ end
45
+ end
46
+ end
@@ -0,0 +1,46 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="update_structured_document_tag_online_response.rb">
3
+ # Copyright (c) 2023 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Response model for update_structured_document_tag_online operation.
30
+ #
31
+ class UpdateStructuredDocumentTagOnlineResponse
32
+ # The response model.
33
+ attr_accessor :model
34
+
35
+ # The document after modification.
36
+ attr_accessor :document
37
+
38
+ #
39
+ # Initializes a new instance.
40
+ #
41
+ def initialize()
42
+ self.model = nil
43
+ self.document = nil
44
+ end
45
+ end
46
+ end