groupdocs_conversion_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.
Files changed (62) hide show
  1. checksums.yaml +4 -4
  2. data/lib/groupdocs_conversion_cloud/models/{tsv_convert_options.rb → cad_convert_options.rb} +74 -32
  3. data/lib/groupdocs_conversion_cloud/models/{pps_convert_options.rb → compression_convert_options.rb} +7 -22
  4. data/lib/groupdocs_conversion_cloud/models/{odp_convert_options.rb → diagram_convert_options.rb} +14 -24
  5. data/lib/groupdocs_conversion_cloud/models/{otp_convert_options.rb → email_convert_options.rb} +7 -32
  6. data/lib/groupdocs_conversion_cloud/models/{ppt_convert_options.rb → finance_convert_options.rb} +7 -32
  7. data/lib/groupdocs_conversion_cloud/models/{potm_convert_options.rb → font_convert_options.rb} +7 -32
  8. data/lib/groupdocs_conversion_cloud/models/{txt_convert_options.rb → gis_convert_options.rb} +3 -3
  9. data/lib/groupdocs_conversion_cloud/models/image_convert_options.rb +44 -4
  10. data/lib/groupdocs_conversion_cloud/models/jpg_convert_options.rb +1 -265
  11. data/lib/groupdocs_conversion_cloud/models/pdl_convert_options.rb +35 -5
  12. data/lib/groupdocs_conversion_cloud/models/project_management_convert_options.rb +256 -0
  13. data/lib/groupdocs_conversion_cloud/models/psd_convert_options.rb +1 -244
  14. data/lib/groupdocs_conversion_cloud/models/rtf_convert_options.rb +1 -237
  15. data/lib/groupdocs_conversion_cloud/models/spreadsheet_convert_options.rb +4 -19
  16. data/lib/groupdocs_conversion_cloud/models/three_d_convert_options.rb +256 -0
  17. data/lib/groupdocs_conversion_cloud/models/tiff_convert_options.rb +1 -244
  18. data/lib/groupdocs_conversion_cloud/models/webp_convert_options.rb +1 -265
  19. data/lib/groupdocs_conversion_cloud/models/word_processing_convert_options.rb +14 -4
  20. data/lib/groupdocs_conversion_cloud/version.rb +1 -1
  21. data/lib/groupdocs_conversion_cloud.rb +14 -52
  22. metadata +11 -49
  23. data/lib/groupdocs_conversion_cloud/models/bmp_convert_options.rb +0 -468
  24. data/lib/groupdocs_conversion_cloud/models/dcm_convert_options.rb +0 -468
  25. data/lib/groupdocs_conversion_cloud/models/djvu_convert_options.rb +0 -468
  26. data/lib/groupdocs_conversion_cloud/models/dng_convert_options.rb +0 -468
  27. data/lib/groupdocs_conversion_cloud/models/doc_convert_options.rb +0 -440
  28. data/lib/groupdocs_conversion_cloud/models/docm_convert_options.rb +0 -440
  29. data/lib/groupdocs_conversion_cloud/models/docx_convert_options.rb +0 -440
  30. data/lib/groupdocs_conversion_cloud/models/dot_convert_options.rb +0 -440
  31. data/lib/groupdocs_conversion_cloud/models/dotm_convert_options.rb +0 -440
  32. data/lib/groupdocs_conversion_cloud/models/dotx_convert_options.rb +0 -440
  33. data/lib/groupdocs_conversion_cloud/models/emf_convert_options.rb +0 -468
  34. data/lib/groupdocs_conversion_cloud/models/gif_convert_options.rb +0 -468
  35. data/lib/groupdocs_conversion_cloud/models/ico_convert_options.rb +0 -468
  36. data/lib/groupdocs_conversion_cloud/models/j2c_convert_options.rb +0 -483
  37. data/lib/groupdocs_conversion_cloud/models/j2k_convert_options.rb +0 -483
  38. data/lib/groupdocs_conversion_cloud/models/jp2_convert_options.rb +0 -483
  39. data/lib/groupdocs_conversion_cloud/models/jpeg_convert_options.rb +0 -483
  40. data/lib/groupdocs_conversion_cloud/models/jpf_convert_options.rb +0 -483
  41. data/lib/groupdocs_conversion_cloud/models/jpm_convert_options.rb +0 -483
  42. data/lib/groupdocs_conversion_cloud/models/jpx_convert_options.rb +0 -483
  43. data/lib/groupdocs_conversion_cloud/models/odg_convert_options.rb +0 -468
  44. data/lib/groupdocs_conversion_cloud/models/ods_convert_options.rb +0 -296
  45. data/lib/groupdocs_conversion_cloud/models/odt_convert_options.rb +0 -440
  46. data/lib/groupdocs_conversion_cloud/models/ots_convert_options.rb +0 -296
  47. data/lib/groupdocs_conversion_cloud/models/ott_convert_options.rb +0 -440
  48. data/lib/groupdocs_conversion_cloud/models/png_convert_options.rb +0 -468
  49. data/lib/groupdocs_conversion_cloud/models/potx_convert_options.rb +0 -281
  50. data/lib/groupdocs_conversion_cloud/models/ppsm_convert_options.rb +0 -281
  51. data/lib/groupdocs_conversion_cloud/models/ppsx_convert_options.rb +0 -281
  52. data/lib/groupdocs_conversion_cloud/models/pptm_convert_options.rb +0 -281
  53. data/lib/groupdocs_conversion_cloud/models/pptx_convert_options.rb +0 -281
  54. data/lib/groupdocs_conversion_cloud/models/tif_convert_options.rb +0 -494
  55. data/lib/groupdocs_conversion_cloud/models/wmf_convert_options.rb +0 -468
  56. data/lib/groupdocs_conversion_cloud/models/xls2003_convert_options.rb +0 -296
  57. data/lib/groupdocs_conversion_cloud/models/xls_convert_options.rb +0 -296
  58. data/lib/groupdocs_conversion_cloud/models/xlsb_convert_options.rb +0 -296
  59. data/lib/groupdocs_conversion_cloud/models/xlsm_convert_options.rb +0 -296
  60. data/lib/groupdocs_conversion_cloud/models/xlsx_convert_options.rb +0 -296
  61. data/lib/groupdocs_conversion_cloud/models/xltm_convert_options.rb +0 -296
  62. data/lib/groupdocs_conversion_cloud/models/xltx_convert_options.rb +0 -296
@@ -1,440 +0,0 @@
1
- #
2
- # --------------------------------------------------------------------------------------------------------------------
3
- # <copyright company="Aspose Pty Ltd" file="ott_convert_options.rb">
4
- # Copyright (c) Aspose Pty Ltd
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
- #
27
-
28
- require 'date'
29
-
30
- module GroupDocsConversionCloud
31
- # Ott convert options
32
- class OttConvertOptions
33
-
34
- # Start conversion from FromPage page
35
- attr_accessor :from_page
36
-
37
- # Number of pages to convert
38
- attr_accessor :pages_count
39
-
40
- # Convert specific pages. The list contains the page indexes of the pages to be converted
41
- attr_accessor :pages
42
-
43
- # Watermark specific options
44
- attr_accessor :watermark_options
45
-
46
- # Desired page width after conversion
47
- attr_accessor :width
48
-
49
- # Desired page height after conversion
50
- attr_accessor :height
51
-
52
- # Desired page DPI after conversion. The default resolution is: 96dpi
53
- attr_accessor :dpi
54
-
55
- # Set this property if you want to protect the converted document with a password
56
- attr_accessor :password
57
-
58
- # Specifies the zoom level in percentage. Default is 100. Default zoom is supported till Microsoft Word 2010. Starting from Microsoft Word 2013 default zoom is no longer set to document, instead it appears to use the zoom factor of the last document that was opened.
59
- attr_accessor :zoom
60
-
61
- # Recognition mode when converting from pdf
62
- attr_accessor :pdf_recognition_mode
63
-
64
- # Page size
65
- attr_accessor :page_size
66
-
67
- # Specifies page orientation
68
- attr_accessor :page_orientation
69
- class EnumAttributeValidator
70
- attr_reader :datatype
71
- attr_reader :allowable_values
72
-
73
- def initialize(datatype, allowable_values)
74
- @allowable_values = allowable_values.map do |value|
75
- case datatype.to_s
76
- when /Integer/i
77
- value.to_i
78
- when /Float/i
79
- value.to_f
80
- else
81
- value
82
- end
83
- end
84
- end
85
-
86
- def valid?(value)
87
- !value || allowable_values.include?(value)
88
- end
89
- end
90
-
91
- # Attribute mapping from ruby-style variable name to JSON key.
92
- def self.attribute_map
93
- {
94
- :'from_page' => :'FromPage',
95
- :'pages_count' => :'PagesCount',
96
- :'pages' => :'Pages',
97
- :'watermark_options' => :'WatermarkOptions',
98
- :'width' => :'Width',
99
- :'height' => :'Height',
100
- :'dpi' => :'Dpi',
101
- :'password' => :'Password',
102
- :'zoom' => :'Zoom',
103
- :'pdf_recognition_mode' => :'PdfRecognitionMode',
104
- :'page_size' => :'PageSize',
105
- :'page_orientation' => :'PageOrientation'
106
- }
107
- end
108
-
109
- # Attribute type mapping.
110
- def self.swagger_types
111
- {
112
- :'from_page' => :'Integer',
113
- :'pages_count' => :'Integer',
114
- :'pages' => :'Array<Integer>',
115
- :'watermark_options' => :'WatermarkOptions',
116
- :'width' => :'Integer',
117
- :'height' => :'Integer',
118
- :'dpi' => :'Integer',
119
- :'password' => :'String',
120
- :'zoom' => :'Integer',
121
- :'pdf_recognition_mode' => :'String',
122
- :'page_size' => :'String',
123
- :'page_orientation' => :'String'
124
- }
125
- end
126
-
127
- # Initializes the object
128
- # @param [Hash] attributes Model attributes in the form of hash
129
- def initialize(attributes = {})
130
- return unless attributes.is_a?(Hash)
131
-
132
- # convert string to symbol for hash key
133
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
134
-
135
- if attributes.key?(:'FromPage')
136
- self.from_page = attributes[:'FromPage']
137
- end
138
-
139
- if attributes.key?(:'PagesCount')
140
- self.pages_count = attributes[:'PagesCount']
141
- end
142
-
143
- if attributes.key?(:'Pages')
144
- if (value = attributes[:'Pages']).is_a?(Array)
145
- self.pages = value
146
- end
147
- end
148
-
149
- if attributes.key?(:'WatermarkOptions')
150
- self.watermark_options = attributes[:'WatermarkOptions']
151
- end
152
-
153
- if attributes.key?(:'Width')
154
- self.width = attributes[:'Width']
155
- end
156
-
157
- if attributes.key?(:'Height')
158
- self.height = attributes[:'Height']
159
- end
160
-
161
- if attributes.key?(:'Dpi')
162
- self.dpi = attributes[:'Dpi']
163
- end
164
-
165
- if attributes.key?(:'Password')
166
- self.password = attributes[:'Password']
167
- end
168
-
169
- if attributes.key?(:'Zoom')
170
- self.zoom = attributes[:'Zoom']
171
- end
172
-
173
- if attributes.key?(:'PdfRecognitionMode')
174
- self.pdf_recognition_mode = attributes[:'PdfRecognitionMode']
175
- end
176
-
177
- if attributes.key?(:'PageSize')
178
- self.page_size = attributes[:'PageSize']
179
- end
180
-
181
- if attributes.key?(:'PageOrientation')
182
- self.page_orientation = attributes[:'PageOrientation']
183
- end
184
-
185
- end
186
-
187
- # Show invalid properties with the reasons. Usually used together with valid?
188
- # @return Array for valid properies with the reasons
189
- def list_invalid_properties
190
- invalid_properties = []
191
- if @from_page.nil?
192
- invalid_properties.push("invalid value for 'from_page', from_page cannot be nil.")
193
- end
194
-
195
- if @pages_count.nil?
196
- invalid_properties.push("invalid value for 'pages_count', pages_count cannot be nil.")
197
- end
198
-
199
- if @width.nil?
200
- invalid_properties.push("invalid value for 'width', width cannot be nil.")
201
- end
202
-
203
- if @height.nil?
204
- invalid_properties.push("invalid value for 'height', height cannot be nil.")
205
- end
206
-
207
- if @dpi.nil?
208
- invalid_properties.push("invalid value for 'dpi', dpi cannot be nil.")
209
- end
210
-
211
- if @zoom.nil?
212
- invalid_properties.push("invalid value for 'zoom', zoom cannot be nil.")
213
- end
214
-
215
- if @pdf_recognition_mode.nil?
216
- invalid_properties.push("invalid value for 'pdf_recognition_mode', pdf_recognition_mode cannot be nil.")
217
- end
218
-
219
- if @page_size.nil?
220
- invalid_properties.push("invalid value for 'page_size', page_size cannot be nil.")
221
- end
222
-
223
- if @page_orientation.nil?
224
- invalid_properties.push("invalid value for 'page_orientation', page_orientation cannot be nil.")
225
- end
226
-
227
- return invalid_properties
228
- end
229
-
230
- # Check to see if the all the properties in the model are valid
231
- # @return true if the model is valid
232
- def valid?
233
- return false if @from_page.nil?
234
- return false if @pages_count.nil?
235
- return false if @width.nil?
236
- return false if @height.nil?
237
- return false if @dpi.nil?
238
- return false if @zoom.nil?
239
- return false if @pdf_recognition_mode.nil?
240
- pdf_recognition_mode_validator = EnumAttributeValidator.new('String', ["Textbox", "Flow"])
241
- return false unless pdf_recognition_mode_validator.valid?(@pdf_recognition_mode)
242
- return false if @page_size.nil?
243
- page_size_validator = EnumAttributeValidator.new('String', ["Default", "A3", "Statement", "Quarto", "Paper11x17", "Paper10x14", "Letter", "Legal", "Ledger", "Folio", "Executive", "EnvelopeDL", "Custom", "B5", "B4", "A5", "A4", "Tabloid"])
244
- return false unless page_size_validator.valid?(@page_size)
245
- return false if @page_orientation.nil?
246
- page_orientation_validator = EnumAttributeValidator.new('String', ["Default", "Landscape", "Portrait"])
247
- return false unless page_orientation_validator.valid?(@page_orientation)
248
- return true
249
- end
250
-
251
- # Custom attribute writer method checking allowed values (enum).
252
- # @param [Object] pdf_recognition_mode Object to be assigned
253
- def pdf_recognition_mode=(pdf_recognition_mode)
254
- validator = EnumAttributeValidator.new('String', ["Textbox", "Flow"])
255
- if pdf_recognition_mode.to_i == 0
256
- unless validator.valid?(pdf_recognition_mode)
257
- raise ArgumentError, "invalid value for 'pdf_recognition_mode', must be one of #{validator.allowable_values}."
258
- end
259
- @pdf_recognition_mode = pdf_recognition_mode
260
- else
261
- @pdf_recognition_mode = validator.allowable_values[pdf_recognition_mode.to_i]
262
- end
263
- end
264
-
265
- # Custom attribute writer method checking allowed values (enum).
266
- # @param [Object] page_size Object to be assigned
267
- def page_size=(page_size)
268
- validator = EnumAttributeValidator.new('String', ["Default", "A3", "Statement", "Quarto", "Paper11x17", "Paper10x14", "Letter", "Legal", "Ledger", "Folio", "Executive", "EnvelopeDL", "Custom", "B5", "B4", "A5", "A4", "Tabloid"])
269
- if page_size.to_i == 0
270
- unless validator.valid?(page_size)
271
- raise ArgumentError, "invalid value for 'page_size', must be one of #{validator.allowable_values}."
272
- end
273
- @page_size = page_size
274
- else
275
- @page_size = validator.allowable_values[page_size.to_i]
276
- end
277
- end
278
-
279
- # Custom attribute writer method checking allowed values (enum).
280
- # @param [Object] page_orientation Object to be assigned
281
- def page_orientation=(page_orientation)
282
- validator = EnumAttributeValidator.new('String', ["Default", "Landscape", "Portrait"])
283
- if page_orientation.to_i == 0
284
- unless validator.valid?(page_orientation)
285
- raise ArgumentError, "invalid value for 'page_orientation', must be one of #{validator.allowable_values}."
286
- end
287
- @page_orientation = page_orientation
288
- else
289
- @page_orientation = validator.allowable_values[page_orientation.to_i]
290
- end
291
- end
292
-
293
- # Checks equality by comparing each attribute.
294
- # @param [Object] Object to be compared
295
- def ==(other)
296
- return true if self.equal?(other)
297
- self.class == other.class &&
298
- from_page == other.from_page &&
299
- pages_count == other.pages_count &&
300
- pages == other.pages &&
301
- watermark_options == other.watermark_options &&
302
- width == other.width &&
303
- height == other.height &&
304
- dpi == other.dpi &&
305
- password == other.password &&
306
- zoom == other.zoom &&
307
- pdf_recognition_mode == other.pdf_recognition_mode &&
308
- page_size == other.page_size &&
309
- page_orientation == other.page_orientation
310
- end
311
-
312
- # @see the `==` method
313
- # @param [Object] Object to be compared
314
- def eql?(other)
315
- self == other
316
- end
317
-
318
- # Calculates hash code according to all attributes.
319
- # @return [Fixnum] Hash code
320
- def hash
321
- [from_page, pages_count, pages, watermark_options, width, height, dpi, password, zoom, pdf_recognition_mode, page_size, page_orientation].hash
322
- end
323
-
324
- # Downcases first letter.
325
- # @return downcased string
326
- def uncap(str)
327
- str[0, 1].downcase + str[1..-1]
328
- end
329
-
330
- # Builds the object from hash
331
- # @param [Hash] attributes Model attributes in the form of hash
332
- # @return [Object] Returns the model itself
333
- def build_from_hash(attributes)
334
- return nil unless attributes.is_a?(Hash)
335
- self.class.swagger_types.each_pair do |key, type|
336
- pname = uncap(self.class.attribute_map[key]).intern
337
- value = attributes[pname]
338
- if type =~ /\AArray<(.*)>/i
339
- # check to ensure the input is an array given that the the attribute
340
- # is documented as an array but the input is not
341
- if value.is_a?(Array)
342
- self.send("#{key}=", value.map { |v| _deserialize($1, v) })
343
- end
344
- elsif !value.nil?
345
- self.send("#{key}=", _deserialize(type, value))
346
- end
347
- # or else data not found in attributes(hash), not an issue as the data can be optional
348
- end
349
-
350
- self
351
- end
352
-
353
- # Deserializes the data based on type
354
- # @param string type Data type
355
- # @param string value Value to be deserialized
356
- # @return [Object] Deserialized data
357
- def _deserialize(type, value)
358
- case type.to_sym
359
- when :DateTime
360
- Date.parse value
361
- when :Date
362
- Date.parse value
363
- when :String
364
- value.to_s
365
- when :Integer
366
- value.to_i
367
- when :Float
368
- value.to_f
369
- when :BOOLEAN
370
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
371
- true
372
- else
373
- false
374
- end
375
- when :Object
376
- # generic object (usually a Hash), return directly
377
- value
378
- when /\AArray<(?<inner_type>.+)>\z/
379
- inner_type = Regexp.last_match[:inner_type]
380
- value.map { |v| _deserialize(inner_type, v) }
381
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
382
- k_type = Regexp.last_match[:k_type]
383
- v_type = Regexp.last_match[:v_type]
384
- {}.tap do |hash|
385
- value.each do |k, v|
386
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
387
- end
388
- end
389
- else
390
- # model
391
- temp_model = GroupDocsConversionCloud.const_get(type).new
392
- temp_model.build_from_hash(value)
393
- end
394
- end
395
-
396
- # Returns the string representation of the object
397
- # @return [String] String presentation of the object
398
- def to_s
399
- to_hash.to_s
400
- end
401
-
402
- # to_body is an alias to to_hash (backward compatibility)
403
- # @return [Hash] Returns the object in the form of hash
404
- def to_body
405
- to_hash
406
- end
407
-
408
- # Returns the object in the form of hash
409
- # @return [Hash] Returns the object in the form of hash
410
- def to_hash
411
- hash = {}
412
- self.class.attribute_map.each_pair do |attr, param|
413
- value = self.send(attr)
414
- next if value.nil?
415
- hash[param] = _to_hash(value)
416
- end
417
- hash
418
- end
419
-
420
- # Outputs non-array value in the form of hash
421
- # For object, use to_hash. Otherwise, just return the value
422
- # @param [Object] value Any valid value
423
- # @return [Hash] Returns the value in the form of hash
424
- def _to_hash(value)
425
- if value.is_a?(Array)
426
- value.compact.map { |v| _to_hash(v) }
427
- elsif value.is_a?(Hash)
428
- {}.tap do |hash|
429
- value.each { |k, v| hash[k] = _to_hash(v) }
430
- end
431
- elsif value.respond_to? :to_hash
432
- value.to_hash
433
- else
434
- value
435
- end
436
- end
437
-
438
- end
439
-
440
- end