aspose_words_cloud 25.10 → 25.12
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/lib/aspose_words_cloud/api/words_api.rb +6 -132
- data/lib/aspose_words_cloud/models/azw3_save_options_data.rb +4 -4
- data/lib/aspose_words_cloud/models/bmp_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/comment.rb +2 -2
- data/lib/aspose_words_cloud/models/comment_insert.rb +2 -2
- data/lib/aspose_words_cloud/models/comment_update.rb +2 -2
- data/lib/aspose_words_cloud/models/compress_options.rb +2 -2
- data/lib/aspose_words_cloud/models/custom_xml_part.rb +1 -1
- data/lib/aspose_words_cloud/models/custom_xml_part_insert.rb +1 -1
- data/lib/aspose_words_cloud/models/custom_xml_part_update.rb +1 -1
- data/lib/aspose_words_cloud/models/doc_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/docm_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/document.rb +11 -1
- data/lib/aspose_words_cloud/models/docx_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/dot_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/dotm_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/dotx_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/emf_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/eps_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/epub_save_options_data.rb +4 -4
- data/lib/aspose_words_cloud/models/field_options.rb +1 -1
- data/lib/aspose_words_cloud/models/flat_opc_macro_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/flat_opc_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/flat_opc_template_macro_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/flat_opc_template_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/footnote.rb +1 -1
- data/lib/aspose_words_cloud/models/footnote_insert.rb +1 -1
- data/lib/aspose_words_cloud/models/footnote_update.rb +1 -1
- data/lib/aspose_words_cloud/models/form_field_checkbox.rb +1 -1
- data/lib/aspose_words_cloud/models/form_field_drop_down.rb +1 -1
- data/lib/aspose_words_cloud/models/form_field_text_input.rb +1 -1
- data/lib/aspose_words_cloud/models/gif_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/html_fixed_save_options_data.rb +4 -4
- data/lib/aspose_words_cloud/models/html_save_options_data.rb +4 -4
- data/lib/aspose_words_cloud/models/jpeg_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/list_level.rb +1 -1
- data/lib/aspose_words_cloud/models/list_level_update.rb +1 -1
- data/lib/aspose_words_cloud/models/markdown_save_options_data.rb +2 -2
- data/lib/aspose_words_cloud/models/mhtml_save_options_data.rb +4 -4
- data/lib/aspose_words_cloud/models/odt_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/open_xps_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/ott_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/pcl_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/pdf_save_options_data.rb +19 -6
- data/lib/aspose_words_cloud/models/png_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/ps_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/requests/build_report_online_request.rb +4 -4
- data/lib/aspose_words_cloud/models/requests/build_report_request.rb +4 -4
- data/lib/aspose_words_cloud/models/requests/sign_document_online_request.rb +2 -2
- data/lib/aspose_words_cloud/models/requests/sign_document_request.rb +2 -2
- data/lib/aspose_words_cloud/models/rtf_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/sign_options.rb +6 -6
- data/lib/aspose_words_cloud/models/signature.rb +1 -1
- data/lib/aspose_words_cloud/models/structured_document_tag.rb +21 -21
- data/lib/aspose_words_cloud/models/structured_document_tag_insert.rb +21 -21
- data/lib/aspose_words_cloud/models/structured_document_tag_update.rb +21 -21
- data/lib/aspose_words_cloud/models/style.rb +1 -1
- data/lib/aspose_words_cloud/models/style_update.rb +1 -1
- data/lib/aspose_words_cloud/models/svg_save_options_data.rb +2 -2
- data/lib/aspose_words_cloud/models/text_save_options_data.rb +30 -3
- data/lib/aspose_words_cloud/models/tiff_save_options_data.rb +2 -2
- data/lib/aspose_words_cloud/models/word_ml_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/xaml_fixed_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/models/xaml_flow_pack_save_options_data.rb +2 -2
- data/lib/aspose_words_cloud/models/xaml_flow_save_options_data.rb +2 -2
- data/lib/aspose_words_cloud/models/xps_save_options_data.rb +1 -1
- data/lib/aspose_words_cloud/version.rb +1 -1
- data/lib/aspose_words_cloud.rb +0 -5
- metadata +2 -7
- data/lib/aspose_words_cloud/models/classification_response.rb +0 -246
- data/lib/aspose_words_cloud/models/classification_result.rb +0 -215
- data/lib/aspose_words_cloud/models/requests/classify_document_online_request.rb +0 -193
- data/lib/aspose_words_cloud/models/requests/classify_document_request.rb +0 -192
- data/lib/aspose_words_cloud/models/requests/classify_request.rb +0 -158
|
@@ -1,158 +0,0 @@
|
|
|
1
|
-
# ------------------------------------------------------------------------------------
|
|
2
|
-
# <copyright company="Aspose" file="classify_request.rb">
|
|
3
|
-
# Copyright (c) 2025 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 classify operation.
|
|
30
|
-
#
|
|
31
|
-
class ClassifyRequest
|
|
32
|
-
# The text to classify.
|
|
33
|
-
attr_accessor :text
|
|
34
|
-
|
|
35
|
-
# The number of the best classes to return.
|
|
36
|
-
attr_accessor :best_classes_count
|
|
37
|
-
|
|
38
|
-
#
|
|
39
|
-
# Initializes a new instance.
|
|
40
|
-
# @param text The text to classify.
|
|
41
|
-
# @param best_classes_count The number of the best classes to return.
|
|
42
|
-
|
|
43
|
-
def initialize(text:, best_classes_count: nil)
|
|
44
|
-
self.text = text
|
|
45
|
-
self.best_classes_count = best_classes_count
|
|
46
|
-
end
|
|
47
|
-
|
|
48
|
-
# Creating batch part from request
|
|
49
|
-
def to_batch_part(api_client, requestId, parentRequestId = nil)
|
|
50
|
-
# verify the required parameter 'text' is set
|
|
51
|
-
raise ArgumentError, 'Missing the required parameter text when calling WordsApi.classify' if api_client.config.client_side_validation && self.text.nil?
|
|
52
|
-
|
|
53
|
-
# resource path
|
|
54
|
-
local_var_path = '/words/classify'[7..-1]
|
|
55
|
-
local_var_path = local_var_path.sub('//', '/')
|
|
56
|
-
|
|
57
|
-
# query parameters
|
|
58
|
-
query_params = {}
|
|
59
|
-
query_params[downcase_first_letter('BestClassesCount')] = self.best_classes_count unless self.best_classes_count.nil?
|
|
60
|
-
|
|
61
|
-
if query_params
|
|
62
|
-
query_params.each { |key, value| local_var_path = api_client.add_param_to_query(local_var_path, key, value) }
|
|
63
|
-
end
|
|
64
|
-
|
|
65
|
-
header_params = {}
|
|
66
|
-
# header parameters
|
|
67
|
-
# HTTP header 'Content-Type'
|
|
68
|
-
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
|
69
|
-
header_params['RequestId'] = requestId
|
|
70
|
-
|
|
71
|
-
if parentRequestId != nil
|
|
72
|
-
header_params['DependsOn'] = parentRequestId
|
|
73
|
-
end
|
|
74
|
-
|
|
75
|
-
# form parameters
|
|
76
|
-
form_params = []
|
|
77
|
-
files_content = []
|
|
78
|
-
if self.text.nil?
|
|
79
|
-
raise "Parameter Text is required."
|
|
80
|
-
end
|
|
81
|
-
unless self.text.nil?
|
|
82
|
-
form_params.push({:'Name' => 'text', :'Data' => self.text, :'MimeType' =>'text/plain'})
|
|
83
|
-
end
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
# http body (model)
|
|
87
|
-
body = api_client.build_request_body_batch(header_params, form_params, files_content)
|
|
88
|
-
part = ""
|
|
89
|
-
part.concat("PUT".force_encoding('UTF-8'))
|
|
90
|
-
part.concat(" ".force_encoding('UTF-8'))
|
|
91
|
-
part.concat(local_var_path.force_encoding('UTF-8'))
|
|
92
|
-
part.concat(" \r\n".force_encoding('UTF-8'))
|
|
93
|
-
|
|
94
|
-
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')) }
|
|
95
|
-
part.concat("\r\n".force_encoding('UTF-8'))
|
|
96
|
-
if body
|
|
97
|
-
if body.is_a?(Hash)
|
|
98
|
-
body.each do |key, value|
|
|
99
|
-
part.concat(value, "\r\n")
|
|
100
|
-
end
|
|
101
|
-
else
|
|
102
|
-
part.concat(body)
|
|
103
|
-
end
|
|
104
|
-
end
|
|
105
|
-
part
|
|
106
|
-
end
|
|
107
|
-
|
|
108
|
-
def create_http_request(api_client)
|
|
109
|
-
# verify the required parameter 'text' is set
|
|
110
|
-
raise ArgumentError, 'Missing the required parameter text when calling WordsApi.classify' if api_client.config.client_side_validation && self.text.nil?
|
|
111
|
-
|
|
112
|
-
# resource path
|
|
113
|
-
local_var_path = '/words/classify'[1..-1]
|
|
114
|
-
local_var_path = local_var_path.sub('//', '/')
|
|
115
|
-
|
|
116
|
-
# query parameters
|
|
117
|
-
query_params = {}
|
|
118
|
-
query_params[downcase_first_letter('BestClassesCount')] = self.best_classes_count unless self.best_classes_count.nil?
|
|
119
|
-
|
|
120
|
-
# header parameters
|
|
121
|
-
header_params = {}
|
|
122
|
-
# HTTP header 'Content-Type'
|
|
123
|
-
header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
|
|
124
|
-
|
|
125
|
-
# form parameters
|
|
126
|
-
form_params = []
|
|
127
|
-
files_content = []
|
|
128
|
-
if self.text.nil?
|
|
129
|
-
raise "Parameter Text is required."
|
|
130
|
-
end
|
|
131
|
-
unless self.text.nil?
|
|
132
|
-
form_params.push({:'Name' => 'text', :'Data' => self.text, :'MimeType' =>'text/plain'})
|
|
133
|
-
end
|
|
134
|
-
|
|
135
|
-
body = api_client.build_request_body(header_params, form_params, files_content)
|
|
136
|
-
{
|
|
137
|
-
'method': :PUT,
|
|
138
|
-
'path': local_var_path,
|
|
139
|
-
'header_params': header_params,
|
|
140
|
-
'query_params': query_params,
|
|
141
|
-
'body': body,
|
|
142
|
-
'auth_names': ['JWT']
|
|
143
|
-
}
|
|
144
|
-
end
|
|
145
|
-
|
|
146
|
-
#
|
|
147
|
-
# Helper method to convert first letter to downcase
|
|
148
|
-
#
|
|
149
|
-
def downcase_first_letter(str)
|
|
150
|
-
str[0].downcase + str[1..-1]
|
|
151
|
-
end
|
|
152
|
-
|
|
153
|
-
# Get response type
|
|
154
|
-
def get_response_type
|
|
155
|
-
'ClassificationResponse'
|
|
156
|
-
end
|
|
157
|
-
end
|
|
158
|
-
end
|