aspose_words_cloud 22.1.0 → 22.2.0
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_client.rb +1 -0
- data/lib/aspose_words_cloud/models/bmp_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/doc_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/{ooxml_save_options_data.rb → docm_save_options_data.rb} +15 -17
- data/lib/aspose_words_cloud/models/docx_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/dot_save_options_data.rb +426 -0
- data/lib/aspose_words_cloud/models/dotm_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/dotx_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/emf_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/epub_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/flat_opc_macro_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/{txt_save_options_base_data.rb → flat_opc_save_options_data.rb} +50 -54
- data/lib/aspose_words_cloud/models/flat_opc_template_macro_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/flat_opc_template_save_options_data.rb +440 -0
- data/lib/aspose_words_cloud/models/gif_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/html_fixed_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/html_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/jpeg_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/markdown_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/mhtml_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/odt_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/{fixed_page_save_options_data.rb → open_xps_save_options_data.rb} +55 -17
- data/lib/aspose_words_cloud/models/ott_save_options_data.rb +441 -0
- data/lib/aspose_words_cloud/models/pcl_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/pdf_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/png_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/ps_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/rtf_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/svg_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/text_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/tiff_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/models/word_ml_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/xaml_fixed_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/{save_options_data.rb → xaml_flow_pack_save_options_data.rb} +35 -17
- data/lib/aspose_words_cloud/models/xaml_flow_save_options_data.rb +12 -14
- data/lib/aspose_words_cloud/models/xps_save_options_data.rb +9 -11
- data/lib/aspose_words_cloud/version.rb +1 -1
- data/lib/aspose_words_cloud.rb +12 -10
- metadata +14 -12
- data/lib/aspose_words_cloud/models/comment_base.rb +0 -251
- data/lib/aspose_words_cloud/models/document_property_base.rb +0 -201
- data/lib/aspose_words_cloud/models/field_base.rb +0 -211
- data/lib/aspose_words_cloud/models/footnote_base.rb +0 -273
- data/lib/aspose_words_cloud/models/image_save_options_data.rb +0 -585
- data/lib/aspose_words_cloud/models/run_base.rb +0 -201
@@ -0,0 +1,440 @@
|
|
1
|
+
# ------------------------------------------------------------------------------------
|
2
|
+
# <copyright company="Aspose" file="dotx_save_options_data.rb">
|
3
|
+
# Copyright (c) 2022 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
|
+
require 'date'
|
27
|
+
|
28
|
+
module AsposeWordsCloud
|
29
|
+
|
30
|
+
# Container class for dotx save options.
|
31
|
+
class DotxSaveOptionsData
|
32
|
+
# Gets or sets a boolean value indicating whether to allow embedding fonts with PostScript outlines when embedding TrueType fonts in a document upon it is saved. The default value is false..
|
33
|
+
attr_accessor :allow_embedding_post_script_fonts
|
34
|
+
|
35
|
+
# Gets or sets CustomTimeZoneInfo.
|
36
|
+
attr_accessor :custom_time_zone_info_data
|
37
|
+
|
38
|
+
# Gets or sets the value determining how 3D effects are rendered.
|
39
|
+
attr_accessor :dml3_d_effects_rendering_mode
|
40
|
+
|
41
|
+
# Gets or sets the value determining how DrawingML effects are rendered.
|
42
|
+
# { Simplified | None | Fine }.
|
43
|
+
attr_accessor :dml_effects_rendering_mode
|
44
|
+
|
45
|
+
# Gets or sets the option that controls how DrawingML shapes are rendered.
|
46
|
+
attr_accessor :dml_rendering_mode
|
47
|
+
|
48
|
+
# Gets or sets the name of destination file.
|
49
|
+
attr_accessor :file_name
|
50
|
+
|
51
|
+
# Gets or sets value determining which document formats are allowed to be mapped by Aspose.Words.Markup.StructuredDocumentTag.XmlMapping.
|
52
|
+
# By default only Aspose.Words.LoadFormat.FlatOpc document format is allowed to be mapped.
|
53
|
+
attr_accessor :flat_opc_xml_mapping_only
|
54
|
+
|
55
|
+
# Gets or sets the value determining how ink (InkML) objects are rendered.
|
56
|
+
attr_accessor :iml_rendering_mode
|
57
|
+
|
58
|
+
# Gets or sets a value determining whether the Aspose.Words.Properties.BuiltInDocumentProperties.CreatedTime property is updated before saving.
|
59
|
+
# Default value is false.
|
60
|
+
attr_accessor :update_created_time_property
|
61
|
+
|
62
|
+
# Gets or sets a value indicating whether fields should be updated before saving the document to a fixed page format. The default value is true.
|
63
|
+
attr_accessor :update_fields
|
64
|
+
|
65
|
+
# Gets or sets a value indicating whether the Aspose.Words.Properties.BuiltInDocumentProperties.LastPrinted property is updated before saving.
|
66
|
+
attr_accessor :update_last_printed_property
|
67
|
+
|
68
|
+
# Gets or sets a value indicating whether the Aspose.Words.Properties.BuiltInDocumentProperties.LastSavedTime property is updated before saving.
|
69
|
+
attr_accessor :update_last_saved_time_property
|
70
|
+
|
71
|
+
# Gets or sets a value indicating whether content of StructuredDocumentTag is updated before saving.
|
72
|
+
attr_accessor :update_sdt_content
|
73
|
+
|
74
|
+
# Gets or sets a value indicating whether to zip output or not.
|
75
|
+
# The default value is false.
|
76
|
+
attr_accessor :zip_output
|
77
|
+
|
78
|
+
# Gets or sets the oOXML version for the output document.
|
79
|
+
attr_accessor :compliance
|
80
|
+
|
81
|
+
# Gets or sets the compression level.
|
82
|
+
attr_accessor :compression_level
|
83
|
+
|
84
|
+
# Gets or sets the password to encrypt document using ECMA376 Standard encryption algorithm.
|
85
|
+
attr_accessor :password
|
86
|
+
|
87
|
+
# Gets or sets a value indicating whether to use pretty formats output.
|
88
|
+
attr_accessor :pretty_format
|
89
|
+
|
90
|
+
# Gets the format of save.
|
91
|
+
attr_accessor :save_format
|
92
|
+
|
93
|
+
class EnumAttributeValidator
|
94
|
+
attr_reader :datatype
|
95
|
+
attr_reader :allowable_values
|
96
|
+
|
97
|
+
def initialize(datatype, allowable_values)
|
98
|
+
@allowable_values = allowable_values.map do |value|
|
99
|
+
case datatype.to_s
|
100
|
+
when /Integer/i
|
101
|
+
value.to_i
|
102
|
+
when /Float/i
|
103
|
+
value.to_f
|
104
|
+
else
|
105
|
+
value
|
106
|
+
end
|
107
|
+
end
|
108
|
+
end
|
109
|
+
|
110
|
+
def valid?(value)
|
111
|
+
!value || allowable_values.include?(value)
|
112
|
+
end
|
113
|
+
end
|
114
|
+
|
115
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
116
|
+
def self.attribute_map
|
117
|
+
{
|
118
|
+
:'allow_embedding_post_script_fonts' => :'AllowEmbeddingPostScriptFonts',
|
119
|
+
:'custom_time_zone_info_data' => :'CustomTimeZoneInfoData',
|
120
|
+
:'dml3_d_effects_rendering_mode' => :'Dml3DEffectsRenderingMode',
|
121
|
+
:'dml_effects_rendering_mode' => :'DmlEffectsRenderingMode',
|
122
|
+
:'dml_rendering_mode' => :'DmlRenderingMode',
|
123
|
+
:'file_name' => :'FileName',
|
124
|
+
:'flat_opc_xml_mapping_only' => :'FlatOpcXmlMappingOnly',
|
125
|
+
:'iml_rendering_mode' => :'ImlRenderingMode',
|
126
|
+
:'update_created_time_property' => :'UpdateCreatedTimeProperty',
|
127
|
+
:'update_fields' => :'UpdateFields',
|
128
|
+
:'update_last_printed_property' => :'UpdateLastPrintedProperty',
|
129
|
+
:'update_last_saved_time_property' => :'UpdateLastSavedTimeProperty',
|
130
|
+
:'update_sdt_content' => :'UpdateSdtContent',
|
131
|
+
:'zip_output' => :'ZipOutput',
|
132
|
+
:'compliance' => :'Compliance',
|
133
|
+
:'compression_level' => :'CompressionLevel',
|
134
|
+
:'password' => :'Password',
|
135
|
+
:'pretty_format' => :'PrettyFormat',
|
136
|
+
:'save_format' => :'SaveFormat'
|
137
|
+
}
|
138
|
+
end
|
139
|
+
|
140
|
+
# Attribute type mapping.
|
141
|
+
def self.swagger_types
|
142
|
+
{
|
143
|
+
:'allow_embedding_post_script_fonts' => :'BOOLEAN',
|
144
|
+
:'custom_time_zone_info_data' => :'TimeZoneInfoData',
|
145
|
+
:'dml3_d_effects_rendering_mode' => :'String',
|
146
|
+
:'dml_effects_rendering_mode' => :'String',
|
147
|
+
:'dml_rendering_mode' => :'String',
|
148
|
+
:'file_name' => :'String',
|
149
|
+
:'flat_opc_xml_mapping_only' => :'BOOLEAN',
|
150
|
+
:'iml_rendering_mode' => :'String',
|
151
|
+
:'update_created_time_property' => :'BOOLEAN',
|
152
|
+
:'update_fields' => :'BOOLEAN',
|
153
|
+
:'update_last_printed_property' => :'BOOLEAN',
|
154
|
+
:'update_last_saved_time_property' => :'BOOLEAN',
|
155
|
+
:'update_sdt_content' => :'BOOLEAN',
|
156
|
+
:'zip_output' => :'BOOLEAN',
|
157
|
+
:'compliance' => :'String',
|
158
|
+
:'compression_level' => :'String',
|
159
|
+
:'password' => :'String',
|
160
|
+
:'pretty_format' => :'BOOLEAN',
|
161
|
+
:'save_format' => :'String'
|
162
|
+
}
|
163
|
+
end
|
164
|
+
|
165
|
+
# Initializes the object
|
166
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
167
|
+
def initialize(attributes = {})
|
168
|
+
return unless attributes.is_a?(Hash)
|
169
|
+
|
170
|
+
# convert string to symbol for hash key
|
171
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
172
|
+
|
173
|
+
self.save_format = 'dotx'
|
174
|
+
|
175
|
+
if attributes.key?(:'AllowEmbeddingPostScriptFonts')
|
176
|
+
self.allow_embedding_post_script_fonts = attributes[:'AllowEmbeddingPostScriptFonts']
|
177
|
+
end
|
178
|
+
|
179
|
+
if attributes.key?(:'CustomTimeZoneInfoData')
|
180
|
+
self.custom_time_zone_info_data = attributes[:'CustomTimeZoneInfoData']
|
181
|
+
end
|
182
|
+
|
183
|
+
if attributes.key?(:'Dml3DEffectsRenderingMode')
|
184
|
+
self.dml3_d_effects_rendering_mode = attributes[:'Dml3DEffectsRenderingMode']
|
185
|
+
end
|
186
|
+
|
187
|
+
if attributes.key?(:'DmlEffectsRenderingMode')
|
188
|
+
self.dml_effects_rendering_mode = attributes[:'DmlEffectsRenderingMode']
|
189
|
+
end
|
190
|
+
|
191
|
+
if attributes.key?(:'DmlRenderingMode')
|
192
|
+
self.dml_rendering_mode = attributes[:'DmlRenderingMode']
|
193
|
+
end
|
194
|
+
|
195
|
+
if attributes.key?(:'FileName')
|
196
|
+
self.file_name = attributes[:'FileName']
|
197
|
+
end
|
198
|
+
|
199
|
+
if attributes.key?(:'FlatOpcXmlMappingOnly')
|
200
|
+
self.flat_opc_xml_mapping_only = attributes[:'FlatOpcXmlMappingOnly']
|
201
|
+
end
|
202
|
+
|
203
|
+
if attributes.key?(:'ImlRenderingMode')
|
204
|
+
self.iml_rendering_mode = attributes[:'ImlRenderingMode']
|
205
|
+
end
|
206
|
+
|
207
|
+
if attributes.key?(:'UpdateCreatedTimeProperty')
|
208
|
+
self.update_created_time_property = attributes[:'UpdateCreatedTimeProperty']
|
209
|
+
end
|
210
|
+
|
211
|
+
if attributes.key?(:'UpdateFields')
|
212
|
+
self.update_fields = attributes[:'UpdateFields']
|
213
|
+
end
|
214
|
+
|
215
|
+
if attributes.key?(:'UpdateLastPrintedProperty')
|
216
|
+
self.update_last_printed_property = attributes[:'UpdateLastPrintedProperty']
|
217
|
+
end
|
218
|
+
|
219
|
+
if attributes.key?(:'UpdateLastSavedTimeProperty')
|
220
|
+
self.update_last_saved_time_property = attributes[:'UpdateLastSavedTimeProperty']
|
221
|
+
end
|
222
|
+
|
223
|
+
if attributes.key?(:'UpdateSdtContent')
|
224
|
+
self.update_sdt_content = attributes[:'UpdateSdtContent']
|
225
|
+
end
|
226
|
+
|
227
|
+
if attributes.key?(:'ZipOutput')
|
228
|
+
self.zip_output = attributes[:'ZipOutput']
|
229
|
+
end
|
230
|
+
|
231
|
+
if attributes.key?(:'Compliance')
|
232
|
+
self.compliance = attributes[:'Compliance']
|
233
|
+
end
|
234
|
+
|
235
|
+
if attributes.key?(:'CompressionLevel')
|
236
|
+
self.compression_level = attributes[:'CompressionLevel']
|
237
|
+
end
|
238
|
+
|
239
|
+
if attributes.key?(:'Password')
|
240
|
+
self.password = attributes[:'Password']
|
241
|
+
end
|
242
|
+
|
243
|
+
if attributes.key?(:'PrettyFormat')
|
244
|
+
self.pretty_format = attributes[:'PrettyFormat']
|
245
|
+
end
|
246
|
+
end
|
247
|
+
|
248
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
249
|
+
# @return Array for valid properies with the reasons
|
250
|
+
def list_invalid_properties
|
251
|
+
invalid_properties = []
|
252
|
+
return invalid_properties
|
253
|
+
end
|
254
|
+
|
255
|
+
# Check to see if the all the properties in the model are valid
|
256
|
+
# @return true if the model is valid
|
257
|
+
def valid?
|
258
|
+
dml3_d_effects_rendering_mode_validator = EnumAttributeValidator.new('String', ["Basic", "Advanced"])
|
259
|
+
return false unless dml3_d_effects_rendering_mode_validator.valid?(@dml3_d_effects_rendering_mode)
|
260
|
+
compression_level_validator = EnumAttributeValidator.new('String', ["Normal", "Maximum", "Fast", "SuperFast"])
|
261
|
+
return false unless compression_level_validator.valid?(@compression_level)
|
262
|
+
|
263
|
+
return true
|
264
|
+
end
|
265
|
+
|
266
|
+
# Custom attribute writer method checking allowed values (enum).
|
267
|
+
# @param [Object] dml3_d_effects_rendering_mode Object to be assigned
|
268
|
+
def dml3_d_effects_rendering_mode=(dml3_d_effects_rendering_mode)
|
269
|
+
validator = EnumAttributeValidator.new('String', ["Basic", "Advanced"])
|
270
|
+
if dml3_d_effects_rendering_mode.to_i == 0
|
271
|
+
unless validator.valid?(dml3_d_effects_rendering_mode)
|
272
|
+
raise ArgumentError, "invalid value for 'dml3_d_effects_rendering_mode', must be one of #{validator.allowable_values}."
|
273
|
+
end
|
274
|
+
@dml3_d_effects_rendering_mode = dml3_d_effects_rendering_mode
|
275
|
+
else
|
276
|
+
@dml3_d_effects_rendering_mode = validator.allowable_values[dml3_d_effects_rendering_mode.to_i]
|
277
|
+
end
|
278
|
+
end
|
279
|
+
|
280
|
+
# Custom attribute writer method checking allowed values (enum).
|
281
|
+
# @param [Object] compression_level Object to be assigned
|
282
|
+
def compression_level=(compression_level)
|
283
|
+
validator = EnumAttributeValidator.new('String', ["Normal", "Maximum", "Fast", "SuperFast"])
|
284
|
+
if compression_level.to_i == 0
|
285
|
+
unless validator.valid?(compression_level)
|
286
|
+
raise ArgumentError, "invalid value for 'compression_level', must be one of #{validator.allowable_values}."
|
287
|
+
end
|
288
|
+
@compression_level = compression_level
|
289
|
+
else
|
290
|
+
@compression_level = validator.allowable_values[compression_level.to_i]
|
291
|
+
end
|
292
|
+
end
|
293
|
+
|
294
|
+
|
295
|
+
# Checks equality by comparing each attribute.
|
296
|
+
# @param [Object] Object to be compared
|
297
|
+
def ==(other)
|
298
|
+
return true if self.equal?(other)
|
299
|
+
self.class == other.class &&
|
300
|
+
allow_embedding_post_script_fonts == other.allow_embedding_post_script_fonts &&
|
301
|
+
custom_time_zone_info_data == other.custom_time_zone_info_data &&
|
302
|
+
dml3_d_effects_rendering_mode == other.dml3_d_effects_rendering_mode &&
|
303
|
+
dml_effects_rendering_mode == other.dml_effects_rendering_mode &&
|
304
|
+
dml_rendering_mode == other.dml_rendering_mode &&
|
305
|
+
file_name == other.file_name &&
|
306
|
+
flat_opc_xml_mapping_only == other.flat_opc_xml_mapping_only &&
|
307
|
+
iml_rendering_mode == other.iml_rendering_mode &&
|
308
|
+
update_created_time_property == other.update_created_time_property &&
|
309
|
+
update_fields == other.update_fields &&
|
310
|
+
update_last_printed_property == other.update_last_printed_property &&
|
311
|
+
update_last_saved_time_property == other.update_last_saved_time_property &&
|
312
|
+
update_sdt_content == other.update_sdt_content &&
|
313
|
+
zip_output == other.zip_output &&
|
314
|
+
compliance == other.compliance &&
|
315
|
+
compression_level == other.compression_level &&
|
316
|
+
password == other.password &&
|
317
|
+
pretty_format == other.pretty_format &&
|
318
|
+
save_format == other.save_format
|
319
|
+
end
|
320
|
+
|
321
|
+
# @see the `==` method
|
322
|
+
# @param [Object] Object to be compared
|
323
|
+
def eql?(other)
|
324
|
+
self == other
|
325
|
+
end
|
326
|
+
|
327
|
+
# Calculates hash code according to all attributes.
|
328
|
+
# @return [Fixnum] Hash code
|
329
|
+
def hash
|
330
|
+
[allow_embedding_post_script_fonts, custom_time_zone_info_data, dml3_d_effects_rendering_mode, dml_effects_rendering_mode, dml_rendering_mode, file_name, flat_opc_xml_mapping_only, iml_rendering_mode, update_created_time_property, update_fields, update_last_printed_property, update_last_saved_time_property, update_sdt_content, zip_output, compliance, compression_level, password, pretty_format, save_format].hash
|
331
|
+
end
|
332
|
+
|
333
|
+
# Builds the object from hash
|
334
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
335
|
+
# @return [Object] Returns the model itself
|
336
|
+
def build_from_hash(attributes)
|
337
|
+
return nil unless attributes.is_a?(Hash)
|
338
|
+
self.class.swagger_types.each_pair do |key, type|
|
339
|
+
if type =~ /\AArray<(.*)>/i
|
340
|
+
# check to ensure the input is an array given that the the attribute
|
341
|
+
# is documented as an array but the input is not
|
342
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
343
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
344
|
+
end
|
345
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
346
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
347
|
+
end
|
348
|
+
# or else data not found in attributes(hash), not an issue as the data can be optional
|
349
|
+
end
|
350
|
+
|
351
|
+
self
|
352
|
+
end
|
353
|
+
|
354
|
+
# Deserializes the data based on type
|
355
|
+
# @param string type Data type
|
356
|
+
# @param string value Value to be deserialized
|
357
|
+
# @return [Object] Deserialized data
|
358
|
+
def _deserialize(type, value)
|
359
|
+
case type.to_sym
|
360
|
+
when :DateTime
|
361
|
+
Time.at(/\d/.match(value)[0].to_f).to_datetime
|
362
|
+
when :Date
|
363
|
+
Time.at(/\d/.match(value)[0].to_f).to_date
|
364
|
+
when :String
|
365
|
+
value.to_s
|
366
|
+
when :Integer
|
367
|
+
value.to_i
|
368
|
+
when :Float
|
369
|
+
value.to_f
|
370
|
+
when :BOOLEAN
|
371
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
372
|
+
true
|
373
|
+
else
|
374
|
+
false
|
375
|
+
end
|
376
|
+
when :Object
|
377
|
+
# generic object (usually a Hash), return directly
|
378
|
+
value
|
379
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
380
|
+
inner_type = Regexp.last_match[:inner_type]
|
381
|
+
value.map { |v| _deserialize(inner_type, v) }
|
382
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
383
|
+
k_type = Regexp.last_match[:k_type]
|
384
|
+
v_type = Regexp.last_match[:v_type]
|
385
|
+
{}.tap do |hash|
|
386
|
+
value.each do |k, v|
|
387
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
388
|
+
end
|
389
|
+
end
|
390
|
+
else
|
391
|
+
# model
|
392
|
+
temp_model = AsposeWordsCloud.const_get(type).new
|
393
|
+
temp_model.build_from_hash(value)
|
394
|
+
end
|
395
|
+
end
|
396
|
+
|
397
|
+
# Returns the string representation of the object
|
398
|
+
# @return [String] String presentation of the object
|
399
|
+
def to_s
|
400
|
+
to_hash.to_s
|
401
|
+
end
|
402
|
+
|
403
|
+
# to_body is an alias to to_hash (backward compatibility)
|
404
|
+
# @return [Hash] Returns the object in the form of hash
|
405
|
+
def to_body
|
406
|
+
to_hash
|
407
|
+
end
|
408
|
+
|
409
|
+
# Returns the object in the form of hash
|
410
|
+
# @return [Hash] Returns the object in the form of hash
|
411
|
+
def to_hash
|
412
|
+
hash = {}
|
413
|
+
self.class.attribute_map.each_pair do |attr, param|
|
414
|
+
value = self.send(attr)
|
415
|
+
next if value.nil?
|
416
|
+
hash[param] = _to_hash(value)
|
417
|
+
end
|
418
|
+
hash
|
419
|
+
end
|
420
|
+
|
421
|
+
# Outputs non-array value in the form of hash
|
422
|
+
# For object, use to_hash. Otherwise, just return the value
|
423
|
+
# @param [Object] value Any valid value
|
424
|
+
# @return [Hash] Returns the value in the form of hash
|
425
|
+
def _to_hash(value)
|
426
|
+
if value.is_a?(Array)
|
427
|
+
value.compact.map { |v| _to_hash(v) }
|
428
|
+
elsif value.is_a?(Hash)
|
429
|
+
{}.tap do |hash|
|
430
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
431
|
+
end
|
432
|
+
elsif value.respond_to? :to_hash
|
433
|
+
value.to_hash
|
434
|
+
else
|
435
|
+
value
|
436
|
+
end
|
437
|
+
end
|
438
|
+
|
439
|
+
end
|
440
|
+
end
|
@@ -55,9 +55,6 @@ module AsposeWordsCloud
|
|
55
55
|
# Gets or sets the value determining how ink (InkML) objects are rendered.
|
56
56
|
attr_accessor :iml_rendering_mode
|
57
57
|
|
58
|
-
# Gets or sets the format of save.
|
59
|
-
attr_accessor :save_format
|
60
|
-
|
61
58
|
# Gets or sets a value determining whether the Aspose.Words.Properties.BuiltInDocumentProperties.CreatedTime property is updated before saving.
|
62
59
|
# Default value is false.
|
63
60
|
attr_accessor :update_created_time_property
|
@@ -144,6 +141,9 @@ module AsposeWordsCloud
|
|
144
141
|
# The default value is 96.
|
145
142
|
attr_accessor :vertical_resolution
|
146
143
|
|
144
|
+
# Gets the format of save.
|
145
|
+
attr_accessor :save_format
|
146
|
+
|
147
147
|
class EnumAttributeValidator
|
148
148
|
attr_reader :datatype
|
149
149
|
attr_reader :allowable_values
|
@@ -177,7 +177,6 @@ module AsposeWordsCloud
|
|
177
177
|
:'file_name' => :'FileName',
|
178
178
|
:'flat_opc_xml_mapping_only' => :'FlatOpcXmlMappingOnly',
|
179
179
|
:'iml_rendering_mode' => :'ImlRenderingMode',
|
180
|
-
:'save_format' => :'SaveFormat',
|
181
180
|
:'update_created_time_property' => :'UpdateCreatedTimeProperty',
|
182
181
|
:'update_fields' => :'UpdateFields',
|
183
182
|
:'update_last_printed_property' => :'UpdateLastPrintedProperty',
|
@@ -202,7 +201,8 @@ module AsposeWordsCloud
|
|
202
201
|
:'use_anti_aliasing' => :'UseAntiAliasing',
|
203
202
|
:'use_gdi_emf_renderer' => :'UseGdiEmfRenderer',
|
204
203
|
:'use_high_quality_rendering' => :'UseHighQualityRendering',
|
205
|
-
:'vertical_resolution' => :'VerticalResolution'
|
204
|
+
:'vertical_resolution' => :'VerticalResolution',
|
205
|
+
:'save_format' => :'SaveFormat'
|
206
206
|
}
|
207
207
|
end
|
208
208
|
|
@@ -217,7 +217,6 @@ module AsposeWordsCloud
|
|
217
217
|
:'file_name' => :'String',
|
218
218
|
:'flat_opc_xml_mapping_only' => :'BOOLEAN',
|
219
219
|
:'iml_rendering_mode' => :'String',
|
220
|
-
:'save_format' => :'String',
|
221
220
|
:'update_created_time_property' => :'BOOLEAN',
|
222
221
|
:'update_fields' => :'BOOLEAN',
|
223
222
|
:'update_last_printed_property' => :'BOOLEAN',
|
@@ -242,7 +241,8 @@ module AsposeWordsCloud
|
|
242
241
|
:'use_anti_aliasing' => :'BOOLEAN',
|
243
242
|
:'use_gdi_emf_renderer' => :'BOOLEAN',
|
244
243
|
:'use_high_quality_rendering' => :'BOOLEAN',
|
245
|
-
:'vertical_resolution' => :'Float'
|
244
|
+
:'vertical_resolution' => :'Float',
|
245
|
+
:'save_format' => :'String'
|
246
246
|
}
|
247
247
|
end
|
248
248
|
|
@@ -254,6 +254,8 @@ module AsposeWordsCloud
|
|
254
254
|
# convert string to symbol for hash key
|
255
255
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
256
256
|
|
257
|
+
self.save_format = 'emf'
|
258
|
+
|
257
259
|
if attributes.key?(:'AllowEmbeddingPostScriptFonts')
|
258
260
|
self.allow_embedding_post_script_fonts = attributes[:'AllowEmbeddingPostScriptFonts']
|
259
261
|
end
|
@@ -286,10 +288,6 @@ module AsposeWordsCloud
|
|
286
288
|
self.iml_rendering_mode = attributes[:'ImlRenderingMode']
|
287
289
|
end
|
288
290
|
|
289
|
-
if attributes.key?(:'SaveFormat')
|
290
|
-
self.save_format = attributes[:'SaveFormat']
|
291
|
-
end
|
292
|
-
|
293
291
|
if attributes.key?(:'UpdateCreatedTimeProperty')
|
294
292
|
self.update_created_time_property = attributes[:'UpdateCreatedTimeProperty']
|
295
293
|
end
|
@@ -435,7 +433,6 @@ module AsposeWordsCloud
|
|
435
433
|
file_name == other.file_name &&
|
436
434
|
flat_opc_xml_mapping_only == other.flat_opc_xml_mapping_only &&
|
437
435
|
iml_rendering_mode == other.iml_rendering_mode &&
|
438
|
-
save_format == other.save_format &&
|
439
436
|
update_created_time_property == other.update_created_time_property &&
|
440
437
|
update_fields == other.update_fields &&
|
441
438
|
update_last_printed_property == other.update_last_printed_property &&
|
@@ -460,7 +457,8 @@ module AsposeWordsCloud
|
|
460
457
|
use_anti_aliasing == other.use_anti_aliasing &&
|
461
458
|
use_gdi_emf_renderer == other.use_gdi_emf_renderer &&
|
462
459
|
use_high_quality_rendering == other.use_high_quality_rendering &&
|
463
|
-
vertical_resolution == other.vertical_resolution
|
460
|
+
vertical_resolution == other.vertical_resolution &&
|
461
|
+
save_format == other.save_format
|
464
462
|
end
|
465
463
|
|
466
464
|
# @see the `==` method
|
@@ -472,7 +470,7 @@ module AsposeWordsCloud
|
|
472
470
|
# Calculates hash code according to all attributes.
|
473
471
|
# @return [Fixnum] Hash code
|
474
472
|
def hash
|
475
|
-
[allow_embedding_post_script_fonts, custom_time_zone_info_data, dml3_d_effects_rendering_mode, dml_effects_rendering_mode, dml_rendering_mode, file_name, flat_opc_xml_mapping_only, iml_rendering_mode,
|
473
|
+
[allow_embedding_post_script_fonts, custom_time_zone_info_data, dml3_d_effects_rendering_mode, dml_effects_rendering_mode, dml_rendering_mode, file_name, flat_opc_xml_mapping_only, iml_rendering_mode, update_created_time_property, update_fields, update_last_printed_property, update_last_saved_time_property, update_sdt_content, zip_output, color_mode, jpeg_quality, metafile_rendering_options, numeral_format, optimize_output, page_count, page_index, horizontal_resolution, image_brightness, image_color_mode, image_contrast, paper_color, pixel_format, resolution, scale, use_anti_aliasing, use_gdi_emf_renderer, use_high_quality_rendering, vertical_resolution, save_format].hash
|
476
474
|
end
|
477
475
|
|
478
476
|
# Builds the object from hash
|
@@ -55,9 +55,6 @@ module AsposeWordsCloud
|
|
55
55
|
# Gets or sets the value determining how ink (InkML) objects are rendered.
|
56
56
|
attr_accessor :iml_rendering_mode
|
57
57
|
|
58
|
-
# Gets or sets the format of save.
|
59
|
-
attr_accessor :save_format
|
60
|
-
|
61
58
|
# Gets or sets a value determining whether the Aspose.Words.Properties.BuiltInDocumentProperties.CreatedTime property is updated before saving.
|
62
59
|
# Default value is false.
|
63
60
|
attr_accessor :update_created_time_property
|
@@ -209,6 +206,9 @@ module AsposeWordsCloud
|
|
209
206
|
# Gets or sets the maximum level of headings populated to the navigation map when exporting.
|
210
207
|
attr_accessor :epub_navigation_map_level
|
211
208
|
|
209
|
+
# Gets the format of save.
|
210
|
+
attr_accessor :save_format
|
211
|
+
|
212
212
|
class EnumAttributeValidator
|
213
213
|
attr_reader :datatype
|
214
214
|
attr_reader :allowable_values
|
@@ -242,7 +242,6 @@ module AsposeWordsCloud
|
|
242
242
|
:'file_name' => :'FileName',
|
243
243
|
:'flat_opc_xml_mapping_only' => :'FlatOpcXmlMappingOnly',
|
244
244
|
:'iml_rendering_mode' => :'ImlRenderingMode',
|
245
|
-
:'save_format' => :'SaveFormat',
|
246
245
|
:'update_created_time_property' => :'UpdateCreatedTimeProperty',
|
247
246
|
:'update_fields' => :'UpdateFields',
|
248
247
|
:'update_last_printed_property' => :'UpdateLastPrintedProperty',
|
@@ -288,7 +287,8 @@ module AsposeWordsCloud
|
|
288
287
|
:'resource_folder_alias' => :'ResourceFolderAlias',
|
289
288
|
:'scale_image_to_shape_size' => :'ScaleImageToShapeSize',
|
290
289
|
:'table_width_output_mode' => :'TableWidthOutputMode',
|
291
|
-
:'epub_navigation_map_level' => :'EpubNavigationMapLevel'
|
290
|
+
:'epub_navigation_map_level' => :'EpubNavigationMapLevel',
|
291
|
+
:'save_format' => :'SaveFormat'
|
292
292
|
}
|
293
293
|
end
|
294
294
|
|
@@ -303,7 +303,6 @@ module AsposeWordsCloud
|
|
303
303
|
:'file_name' => :'String',
|
304
304
|
:'flat_opc_xml_mapping_only' => :'BOOLEAN',
|
305
305
|
:'iml_rendering_mode' => :'String',
|
306
|
-
:'save_format' => :'String',
|
307
306
|
:'update_created_time_property' => :'BOOLEAN',
|
308
307
|
:'update_fields' => :'BOOLEAN',
|
309
308
|
:'update_last_printed_property' => :'BOOLEAN',
|
@@ -349,7 +348,8 @@ module AsposeWordsCloud
|
|
349
348
|
:'resource_folder_alias' => :'String',
|
350
349
|
:'scale_image_to_shape_size' => :'BOOLEAN',
|
351
350
|
:'table_width_output_mode' => :'String',
|
352
|
-
:'epub_navigation_map_level' => :'Integer'
|
351
|
+
:'epub_navigation_map_level' => :'Integer',
|
352
|
+
:'save_format' => :'String'
|
353
353
|
}
|
354
354
|
end
|
355
355
|
|
@@ -361,6 +361,8 @@ module AsposeWordsCloud
|
|
361
361
|
# convert string to symbol for hash key
|
362
362
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
363
363
|
|
364
|
+
self.save_format = 'epub'
|
365
|
+
|
364
366
|
if attributes.key?(:'AllowEmbeddingPostScriptFonts')
|
365
367
|
self.allow_embedding_post_script_fonts = attributes[:'AllowEmbeddingPostScriptFonts']
|
366
368
|
end
|
@@ -393,10 +395,6 @@ module AsposeWordsCloud
|
|
393
395
|
self.iml_rendering_mode = attributes[:'ImlRenderingMode']
|
394
396
|
end
|
395
397
|
|
396
|
-
if attributes.key?(:'SaveFormat')
|
397
|
-
self.save_format = attributes[:'SaveFormat']
|
398
|
-
end
|
399
|
-
|
400
398
|
if attributes.key?(:'UpdateCreatedTimeProperty')
|
401
399
|
self.update_created_time_property = attributes[:'UpdateCreatedTimeProperty']
|
402
400
|
end
|
@@ -674,7 +672,6 @@ module AsposeWordsCloud
|
|
674
672
|
file_name == other.file_name &&
|
675
673
|
flat_opc_xml_mapping_only == other.flat_opc_xml_mapping_only &&
|
676
674
|
iml_rendering_mode == other.iml_rendering_mode &&
|
677
|
-
save_format == other.save_format &&
|
678
675
|
update_created_time_property == other.update_created_time_property &&
|
679
676
|
update_fields == other.update_fields &&
|
680
677
|
update_last_printed_property == other.update_last_printed_property &&
|
@@ -720,7 +717,8 @@ module AsposeWordsCloud
|
|
720
717
|
resource_folder_alias == other.resource_folder_alias &&
|
721
718
|
scale_image_to_shape_size == other.scale_image_to_shape_size &&
|
722
719
|
table_width_output_mode == other.table_width_output_mode &&
|
723
|
-
epub_navigation_map_level == other.epub_navigation_map_level
|
720
|
+
epub_navigation_map_level == other.epub_navigation_map_level &&
|
721
|
+
save_format == other.save_format
|
724
722
|
end
|
725
723
|
|
726
724
|
# @see the `==` method
|
@@ -732,7 +730,7 @@ module AsposeWordsCloud
|
|
732
730
|
# Calculates hash code according to all attributes.
|
733
731
|
# @return [Fixnum] Hash code
|
734
732
|
def hash
|
735
|
-
[allow_embedding_post_script_fonts, custom_time_zone_info_data, dml3_d_effects_rendering_mode, dml_effects_rendering_mode, dml_rendering_mode, file_name, flat_opc_xml_mapping_only, iml_rendering_mode,
|
733
|
+
[allow_embedding_post_script_fonts, custom_time_zone_info_data, dml3_d_effects_rendering_mode, dml_effects_rendering_mode, dml_rendering_mode, file_name, flat_opc_xml_mapping_only, iml_rendering_mode, update_created_time_property, update_fields, update_last_printed_property, update_last_saved_time_property, update_sdt_content, zip_output, allow_negative_indent, css_class_name_prefix, css_style_sheet_file_name, css_style_sheet_type, document_split_criteria, document_split_heading_level, encoding, export_document_properties, export_drop_down_form_field_as_text, export_font_resources, export_fonts_as_base64, export_headers_footers_mode, export_images_as_base64, export_language_information, export_list_labels, export_original_url_for_linked_images, export_page_margins, export_page_setup, export_relative_font_size, export_roundtrip_information, export_text_box_as_svg, export_text_input_form_field_as_text, export_toc_page_numbers, export_xhtml_transitional, font_resources_subsetting_size_threshold, fonts_folder, fonts_folder_alias, html_version, image_resolution, images_folder, images_folder_alias, metafile_format, office_math_output_mode, pretty_format, resolve_font_names, resource_folder, resource_folder_alias, scale_image_to_shape_size, table_width_output_mode, epub_navigation_map_level, save_format].hash
|
736
734
|
end
|
737
735
|
|
738
736
|
# Builds the object from hash
|