groupdocs_conversion_cloud 25.6 → 25.9

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 (90) hide show
  1. checksums.yaml +4 -4
  2. data/lib/groupdocs_conversion_cloud/models/cad_load_options.rb +25 -15
  3. data/lib/groupdocs_conversion_cloud/models/csv_load_options.rb +230 -61
  4. data/lib/groupdocs_conversion_cloud/models/email_load_options.rb +142 -77
  5. data/lib/groupdocs_conversion_cloud/models/pdf_load_options.rb +110 -28
  6. data/lib/groupdocs_conversion_cloud/models/spreadsheet_load_options.rb +233 -64
  7. data/lib/groupdocs_conversion_cloud/models/tsv_load_options.rb +233 -64
  8. data/lib/groupdocs_conversion_cloud/models/web_load_options.rb +81 -4
  9. data/lib/groupdocs_conversion_cloud/version.rb +1 -1
  10. data/lib/groupdocs_conversion_cloud.rb +0 -79
  11. metadata +2 -81
  12. data/lib/groupdocs_conversion_cloud/models/bmp_load_options.rb +0 -224
  13. data/lib/groupdocs_conversion_cloud/models/cf2_load_options.rb +0 -288
  14. data/lib/groupdocs_conversion_cloud/models/dcm_load_options.rb +0 -224
  15. data/lib/groupdocs_conversion_cloud/models/dgn_load_options.rb +0 -288
  16. data/lib/groupdocs_conversion_cloud/models/dng_load_options.rb +0 -224
  17. data/lib/groupdocs_conversion_cloud/models/doc_load_options.rb +0 -658
  18. data/lib/groupdocs_conversion_cloud/models/docm_load_options.rb +0 -658
  19. data/lib/groupdocs_conversion_cloud/models/docx_load_options.rb +0 -658
  20. data/lib/groupdocs_conversion_cloud/models/dot_load_options.rb +0 -658
  21. data/lib/groupdocs_conversion_cloud/models/dotm_load_options.rb +0 -658
  22. data/lib/groupdocs_conversion_cloud/models/dotx_load_options.rb +0 -658
  23. data/lib/groupdocs_conversion_cloud/models/dwf_load_options.rb +0 -288
  24. data/lib/groupdocs_conversion_cloud/models/dwfx_load_options.rb +0 -288
  25. data/lib/groupdocs_conversion_cloud/models/dwg_load_options.rb +0 -288
  26. data/lib/groupdocs_conversion_cloud/models/dwt_load_options.rb +0 -288
  27. data/lib/groupdocs_conversion_cloud/models/dxf_load_options.rb +0 -288
  28. data/lib/groupdocs_conversion_cloud/models/emf_load_options.rb +0 -224
  29. data/lib/groupdocs_conversion_cloud/models/eml_load_options.rb +0 -341
  30. data/lib/groupdocs_conversion_cloud/models/emlx_load_options.rb +0 -341
  31. data/lib/groupdocs_conversion_cloud/models/gif_load_options.rb +0 -224
  32. data/lib/groupdocs_conversion_cloud/models/ico_load_options.rb +0 -224
  33. data/lib/groupdocs_conversion_cloud/models/ifc_load_options.rb +0 -288
  34. data/lib/groupdocs_conversion_cloud/models/igs_load_options.rb +0 -288
  35. data/lib/groupdocs_conversion_cloud/models/j2c_load_options.rb +0 -224
  36. data/lib/groupdocs_conversion_cloud/models/j2k_load_options.rb +0 -224
  37. data/lib/groupdocs_conversion_cloud/models/jp2_load_options.rb +0 -224
  38. data/lib/groupdocs_conversion_cloud/models/jpeg_load_options.rb +0 -224
  39. data/lib/groupdocs_conversion_cloud/models/jpf_load_options.rb +0 -224
  40. data/lib/groupdocs_conversion_cloud/models/jpg_load_options.rb +0 -224
  41. data/lib/groupdocs_conversion_cloud/models/jpm_load_options.rb +0 -224
  42. data/lib/groupdocs_conversion_cloud/models/jpx_load_options.rb +0 -224
  43. data/lib/groupdocs_conversion_cloud/models/mht_load_options.rb +0 -341
  44. data/lib/groupdocs_conversion_cloud/models/mobi_load_options.rb +0 -658
  45. data/lib/groupdocs_conversion_cloud/models/msg_load_options.rb +0 -341
  46. data/lib/groupdocs_conversion_cloud/models/odg_load_options.rb +0 -224
  47. data/lib/groupdocs_conversion_cloud/models/odp_load_options.rb +0 -434
  48. data/lib/groupdocs_conversion_cloud/models/ods_load_options.rb +0 -368
  49. data/lib/groupdocs_conversion_cloud/models/odt_load_options.rb +0 -658
  50. data/lib/groupdocs_conversion_cloud/models/ost_load_options.rb +0 -341
  51. data/lib/groupdocs_conversion_cloud/models/otp_load_options.rb +0 -434
  52. data/lib/groupdocs_conversion_cloud/models/ots_load_options.rb +0 -368
  53. data/lib/groupdocs_conversion_cloud/models/ott_load_options.rb +0 -658
  54. data/lib/groupdocs_conversion_cloud/models/plt_load_options.rb +0 -288
  55. data/lib/groupdocs_conversion_cloud/models/png_load_options.rb +0 -224
  56. data/lib/groupdocs_conversion_cloud/models/potm_load_options.rb +0 -434
  57. data/lib/groupdocs_conversion_cloud/models/potx_load_options.rb +0 -434
  58. data/lib/groupdocs_conversion_cloud/models/pps_load_options.rb +0 -434
  59. data/lib/groupdocs_conversion_cloud/models/ppsm_load_options.rb +0 -434
  60. data/lib/groupdocs_conversion_cloud/models/ppsx_load_options.rb +0 -434
  61. data/lib/groupdocs_conversion_cloud/models/ppt_load_options.rb +0 -434
  62. data/lib/groupdocs_conversion_cloud/models/pptm_load_options.rb +0 -434
  63. data/lib/groupdocs_conversion_cloud/models/pptx_load_options.rb +0 -434
  64. data/lib/groupdocs_conversion_cloud/models/psd_load_options.rb +0 -224
  65. data/lib/groupdocs_conversion_cloud/models/pst_load_options.rb +0 -341
  66. data/lib/groupdocs_conversion_cloud/models/stl_load_options.rb +0 -288
  67. data/lib/groupdocs_conversion_cloud/models/tif_load_options.rb +0 -224
  68. data/lib/groupdocs_conversion_cloud/models/tiff_load_options.rb +0 -224
  69. data/lib/groupdocs_conversion_cloud/models/vdw_load_options.rb +0 -224
  70. data/lib/groupdocs_conversion_cloud/models/vdx_load_options.rb +0 -224
  71. data/lib/groupdocs_conversion_cloud/models/vsd_load_options.rb +0 -224
  72. data/lib/groupdocs_conversion_cloud/models/vsdm_load_options.rb +0 -224
  73. data/lib/groupdocs_conversion_cloud/models/vsdx_load_options.rb +0 -224
  74. data/lib/groupdocs_conversion_cloud/models/vss_load_options.rb +0 -224
  75. data/lib/groupdocs_conversion_cloud/models/vssm_load_options.rb +0 -224
  76. data/lib/groupdocs_conversion_cloud/models/vssx_load_options.rb +0 -224
  77. data/lib/groupdocs_conversion_cloud/models/vst_load_options.rb +0 -224
  78. data/lib/groupdocs_conversion_cloud/models/vstm_load_options.rb +0 -224
  79. data/lib/groupdocs_conversion_cloud/models/vstx_load_options.rb +0 -224
  80. data/lib/groupdocs_conversion_cloud/models/vsx_load_options.rb +0 -224
  81. data/lib/groupdocs_conversion_cloud/models/vtx_load_options.rb +0 -224
  82. data/lib/groupdocs_conversion_cloud/models/webp_load_options.rb +0 -224
  83. data/lib/groupdocs_conversion_cloud/models/wmf_load_options.rb +0 -224
  84. data/lib/groupdocs_conversion_cloud/models/xls2003_load_options.rb +0 -368
  85. data/lib/groupdocs_conversion_cloud/models/xls_load_options.rb +0 -368
  86. data/lib/groupdocs_conversion_cloud/models/xlsb_load_options.rb +0 -368
  87. data/lib/groupdocs_conversion_cloud/models/xlsm_load_options.rb +0 -368
  88. data/lib/groupdocs_conversion_cloud/models/xlsx_load_options.rb +0 -368
  89. data/lib/groupdocs_conversion_cloud/models/xltm_load_options.rb +0 -368
  90. data/lib/groupdocs_conversion_cloud/models/xltx_load_options.rb +0 -368
@@ -1,368 +0,0 @@
1
- #
2
- # --------------------------------------------------------------------------------------------------------------------
3
- # <copyright company="Aspose Pty Ltd" file="xltm_load_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
- # Xltm load options
32
- class XltmLoadOptions
33
-
34
- # The format of input file, (\"docx\", for example). This field must be filled with correct input file format when using ConvertDirect method, which accept input file as binary stream, and, because of that, API can correctly handle LoadOptions. In regular conversion, the input file format taken from the input file name and this field ignored.
35
- attr_accessor :format
36
-
37
- # Default font for Cells document. The following font will be used if a font is missing.
38
- attr_accessor :default_font
39
-
40
- # Substitute specific fonts when converting Cells document.
41
- attr_accessor :font_substitutes
42
-
43
- # Show grid lines when converting Excel files
44
- attr_accessor :show_grid_lines
45
-
46
- # Show hidden sheets when converting Excel files
47
- attr_accessor :show_hidden_sheets
48
-
49
- # If OnePagePerSheet is true the content of the sheet will be converted to one page in the PDF document. Default value is true.
50
- attr_accessor :one_page_per_sheet
51
-
52
- # Convert specific range when converting to other than cells format. Example: \"D1:F8\"
53
- attr_accessor :convert_range
54
-
55
- # Skips empty rows and columns when converting. Default is True.
56
- attr_accessor :skip_empty_rows_and_columns
57
-
58
- # Set password to unprotect protected document
59
- attr_accessor :password
60
-
61
- # Represents the way comments are printed with the sheet. Default is PrintNoComments.
62
- attr_accessor :print_comments
63
- class EnumAttributeValidator
64
- attr_reader :datatype
65
- attr_reader :allowable_values
66
-
67
- def initialize(datatype, allowable_values)
68
- @allowable_values = allowable_values.map do |value|
69
- case datatype.to_s
70
- when /Integer/i
71
- value.to_i
72
- when /Float/i
73
- value.to_f
74
- else
75
- value
76
- end
77
- end
78
- end
79
-
80
- def valid?(value)
81
- !value || allowable_values.include?(value)
82
- end
83
- end
84
-
85
- # Attribute mapping from ruby-style variable name to JSON key.
86
- def self.attribute_map
87
- {
88
- :'format' => :'Format',
89
- :'default_font' => :'DefaultFont',
90
- :'font_substitutes' => :'FontSubstitutes',
91
- :'show_grid_lines' => :'ShowGridLines',
92
- :'show_hidden_sheets' => :'ShowHiddenSheets',
93
- :'one_page_per_sheet' => :'OnePagePerSheet',
94
- :'convert_range' => :'ConvertRange',
95
- :'skip_empty_rows_and_columns' => :'SkipEmptyRowsAndColumns',
96
- :'password' => :'Password',
97
- :'print_comments' => :'PrintComments'
98
- }
99
- end
100
-
101
- # Attribute type mapping.
102
- def self.swagger_types
103
- {
104
- :'format' => :'String',
105
- :'default_font' => :'String',
106
- :'font_substitutes' => :'Hash<String, String>',
107
- :'show_grid_lines' => :'BOOLEAN',
108
- :'show_hidden_sheets' => :'BOOLEAN',
109
- :'one_page_per_sheet' => :'BOOLEAN',
110
- :'convert_range' => :'String',
111
- :'skip_empty_rows_and_columns' => :'BOOLEAN',
112
- :'password' => :'String',
113
- :'print_comments' => :'String'
114
- }
115
- end
116
-
117
- # Initializes the object
118
- # @param [Hash] attributes Model attributes in the form of hash
119
- def initialize(attributes = {})
120
- return unless attributes.is_a?(Hash)
121
-
122
- # convert string to symbol for hash key
123
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
124
-
125
- if attributes.key?(:'Format')
126
- self.format = attributes[:'Format']
127
- end
128
-
129
- if attributes.key?(:'DefaultFont')
130
- self.default_font = attributes[:'DefaultFont']
131
- end
132
-
133
- if attributes.key?(:'FontSubstitutes')
134
- if (value = attributes[:'FontSubstitutes']).is_a?(Hash)
135
- self.font_substitutes = value
136
- end
137
- end
138
-
139
- if attributes.key?(:'ShowGridLines')
140
- self.show_grid_lines = attributes[:'ShowGridLines']
141
- end
142
-
143
- if attributes.key?(:'ShowHiddenSheets')
144
- self.show_hidden_sheets = attributes[:'ShowHiddenSheets']
145
- end
146
-
147
- if attributes.key?(:'OnePagePerSheet')
148
- self.one_page_per_sheet = attributes[:'OnePagePerSheet']
149
- end
150
-
151
- if attributes.key?(:'ConvertRange')
152
- self.convert_range = attributes[:'ConvertRange']
153
- end
154
-
155
- if attributes.key?(:'SkipEmptyRowsAndColumns')
156
- self.skip_empty_rows_and_columns = attributes[:'SkipEmptyRowsAndColumns']
157
- end
158
-
159
- if attributes.key?(:'Password')
160
- self.password = attributes[:'Password']
161
- end
162
-
163
- if attributes.key?(:'PrintComments')
164
- self.print_comments = attributes[:'PrintComments']
165
- end
166
-
167
- end
168
-
169
- # Show invalid properties with the reasons. Usually used together with valid?
170
- # @return Array for valid properies with the reasons
171
- def list_invalid_properties
172
- invalid_properties = []
173
- if @show_grid_lines.nil?
174
- invalid_properties.push("invalid value for 'show_grid_lines', show_grid_lines cannot be nil.")
175
- end
176
-
177
- if @show_hidden_sheets.nil?
178
- invalid_properties.push("invalid value for 'show_hidden_sheets', show_hidden_sheets cannot be nil.")
179
- end
180
-
181
- if @one_page_per_sheet.nil?
182
- invalid_properties.push("invalid value for 'one_page_per_sheet', one_page_per_sheet cannot be nil.")
183
- end
184
-
185
- if @skip_empty_rows_and_columns.nil?
186
- invalid_properties.push("invalid value for 'skip_empty_rows_and_columns', skip_empty_rows_and_columns cannot be nil.")
187
- end
188
-
189
- if @print_comments.nil?
190
- invalid_properties.push("invalid value for 'print_comments', print_comments cannot be nil.")
191
- end
192
-
193
- return invalid_properties
194
- end
195
-
196
- # Check to see if the all the properties in the model are valid
197
- # @return true if the model is valid
198
- def valid?
199
- return false if @show_grid_lines.nil?
200
- return false if @show_hidden_sheets.nil?
201
- return false if @one_page_per_sheet.nil?
202
- return false if @skip_empty_rows_and_columns.nil?
203
- return false if @print_comments.nil?
204
- print_comments_validator = EnumAttributeValidator.new('String', ["PrintInPlace", "PrintNoComments", "PrintSheetEnd", "PrintWithThreadedComments"])
205
- return false unless print_comments_validator.valid?(@print_comments)
206
- return true
207
- end
208
-
209
- # Custom attribute writer method checking allowed values (enum).
210
- # @param [Object] print_comments Object to be assigned
211
- def print_comments=(print_comments)
212
- validator = EnumAttributeValidator.new('String', ["PrintInPlace", "PrintNoComments", "PrintSheetEnd", "PrintWithThreadedComments"])
213
- if print_comments.to_i == 0
214
- unless validator.valid?(print_comments)
215
- raise ArgumentError, "invalid value for 'print_comments', must be one of #{validator.allowable_values}."
216
- end
217
- @print_comments = print_comments
218
- else
219
- @print_comments = validator.allowable_values[print_comments.to_i]
220
- end
221
- end
222
-
223
- # Checks equality by comparing each attribute.
224
- # @param [Object] Object to be compared
225
- def ==(other)
226
- return true if self.equal?(other)
227
- self.class == other.class &&
228
- format == other.format &&
229
- default_font == other.default_font &&
230
- font_substitutes == other.font_substitutes &&
231
- show_grid_lines == other.show_grid_lines &&
232
- show_hidden_sheets == other.show_hidden_sheets &&
233
- one_page_per_sheet == other.one_page_per_sheet &&
234
- convert_range == other.convert_range &&
235
- skip_empty_rows_and_columns == other.skip_empty_rows_and_columns &&
236
- password == other.password &&
237
- print_comments == other.print_comments
238
- end
239
-
240
- # @see the `==` method
241
- # @param [Object] Object to be compared
242
- def eql?(other)
243
- self == other
244
- end
245
-
246
- # Calculates hash code according to all attributes.
247
- # @return [Fixnum] Hash code
248
- def hash
249
- [format, default_font, font_substitutes, show_grid_lines, show_hidden_sheets, one_page_per_sheet, convert_range, skip_empty_rows_and_columns, password, print_comments].hash
250
- end
251
-
252
- # Downcases first letter.
253
- # @return downcased string
254
- def uncap(str)
255
- str[0, 1].downcase + str[1..-1]
256
- end
257
-
258
- # Builds the object from hash
259
- # @param [Hash] attributes Model attributes in the form of hash
260
- # @return [Object] Returns the model itself
261
- def build_from_hash(attributes)
262
- return nil unless attributes.is_a?(Hash)
263
- self.class.swagger_types.each_pair do |key, type|
264
- pname = uncap(self.class.attribute_map[key]).intern
265
- value = attributes[pname]
266
- if type =~ /\AArray<(.*)>/i
267
- # check to ensure the input is an array given that the the attribute
268
- # is documented as an array but the input is not
269
- if value.is_a?(Array)
270
- self.send("#{key}=", value.map { |v| _deserialize($1, v) })
271
- end
272
- elsif !value.nil?
273
- self.send("#{key}=", _deserialize(type, value))
274
- end
275
- # or else data not found in attributes(hash), not an issue as the data can be optional
276
- end
277
-
278
- self
279
- end
280
-
281
- # Deserializes the data based on type
282
- # @param string type Data type
283
- # @param string value Value to be deserialized
284
- # @return [Object] Deserialized data
285
- def _deserialize(type, value)
286
- case type.to_sym
287
- when :DateTime
288
- Date.parse value
289
- when :Date
290
- Date.parse value
291
- when :String
292
- value.to_s
293
- when :Integer
294
- value.to_i
295
- when :Float
296
- value.to_f
297
- when :BOOLEAN
298
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
299
- true
300
- else
301
- false
302
- end
303
- when :Object
304
- # generic object (usually a Hash), return directly
305
- value
306
- when /\AArray<(?<inner_type>.+)>\z/
307
- inner_type = Regexp.last_match[:inner_type]
308
- value.map { |v| _deserialize(inner_type, v) }
309
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
310
- k_type = Regexp.last_match[:k_type]
311
- v_type = Regexp.last_match[:v_type]
312
- {}.tap do |hash|
313
- value.each do |k, v|
314
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
315
- end
316
- end
317
- else
318
- # model
319
- temp_model = GroupDocsConversionCloud.const_get(type).new
320
- temp_model.build_from_hash(value)
321
- end
322
- end
323
-
324
- # Returns the string representation of the object
325
- # @return [String] String presentation of the object
326
- def to_s
327
- to_hash.to_s
328
- end
329
-
330
- # to_body is an alias to to_hash (backward compatibility)
331
- # @return [Hash] Returns the object in the form of hash
332
- def to_body
333
- to_hash
334
- end
335
-
336
- # Returns the object in the form of hash
337
- # @return [Hash] Returns the object in the form of hash
338
- def to_hash
339
- hash = {}
340
- self.class.attribute_map.each_pair do |attr, param|
341
- value = self.send(attr)
342
- next if value.nil?
343
- hash[param] = _to_hash(value)
344
- end
345
- hash
346
- end
347
-
348
- # Outputs non-array value in the form of hash
349
- # For object, use to_hash. Otherwise, just return the value
350
- # @param [Object] value Any valid value
351
- # @return [Hash] Returns the value in the form of hash
352
- def _to_hash(value)
353
- if value.is_a?(Array)
354
- value.compact.map { |v| _to_hash(v) }
355
- elsif value.is_a?(Hash)
356
- {}.tap do |hash|
357
- value.each { |k, v| hash[k] = _to_hash(v) }
358
- end
359
- elsif value.respond_to? :to_hash
360
- value.to_hash
361
- else
362
- value
363
- end
364
- end
365
-
366
- end
367
-
368
- end