aspose_slides_cloud 20.2.0 → 20.8.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (163) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +1 -1
  3. data/TestData/ChartTest.pptx +0 -0
  4. data/lib/aspose_slides_cloud.rb +13 -3
  5. data/lib/aspose_slides_cloud/api/slides_api.rb +3254 -1024
  6. data/lib/aspose_slides_cloud/api/slides_api_requests.rb +970 -137
  7. data/lib/aspose_slides_cloud/api_client.rb +8 -5
  8. data/lib/aspose_slides_cloud/models/add_layout_slide.rb +31 -48
  9. data/lib/aspose_slides_cloud/models/add_master_slide.rb +31 -48
  10. data/lib/aspose_slides_cloud/models/add_shape.rb +31 -48
  11. data/lib/aspose_slides_cloud/models/add_slide.rb +31 -48
  12. data/lib/aspose_slides_cloud/models/api_info.rb +22 -10
  13. data/lib/aspose_slides_cloud/models/arrow_head_properties.rb +22 -10
  14. data/lib/aspose_slides_cloud/models/audio_frame.rb +32 -244
  15. data/lib/aspose_slides_cloud/models/axes.rb +22 -10
  16. data/lib/aspose_slides_cloud/models/axis.rb +22 -10
  17. data/lib/aspose_slides_cloud/models/base64_input_file.rb +31 -57
  18. data/lib/aspose_slides_cloud/models/blur_effect.rb +22 -10
  19. data/lib/aspose_slides_cloud/models/box_and_whisker_series.rb +299 -0
  20. data/lib/aspose_slides_cloud/models/bubble_chart_data_point.rb +30 -48
  21. data/lib/aspose_slides_cloud/models/bubble_series.rb +31 -211
  22. data/lib/aspose_slides_cloud/models/chart.rb +35 -221
  23. data/lib/aspose_slides_cloud/models/chart_category.rb +261 -0
  24. data/lib/aspose_slides_cloud/models/chart_title.rb +22 -10
  25. data/lib/aspose_slides_cloud/models/chart_wall.rb +22 -10
  26. data/lib/aspose_slides_cloud/models/color_scheme.rb +30 -40
  27. data/lib/aspose_slides_cloud/models/common_slide_view_properties.rb +217 -0
  28. data/lib/aspose_slides_cloud/models/connector.rb +31 -242
  29. data/lib/aspose_slides_cloud/models/custom_dash_pattern.rb +22 -10
  30. data/lib/aspose_slides_cloud/models/disc_usage.rb +22 -10
  31. data/lib/aspose_slides_cloud/models/document.rb +41 -41
  32. data/lib/aspose_slides_cloud/models/document_properties.rb +30 -40
  33. data/lib/aspose_slides_cloud/models/document_property.rb +30 -40
  34. data/lib/aspose_slides_cloud/models/document_replace_result.rb +32 -86
  35. data/lib/aspose_slides_cloud/models/effect.rb +22 -10
  36. data/lib/aspose_slides_cloud/models/effect_format.rb +22 -10
  37. data/lib/aspose_slides_cloud/models/entity_exists.rb +212 -0
  38. data/lib/aspose_slides_cloud/models/error.rb +22 -10
  39. data/lib/aspose_slides_cloud/models/error_details.rb +22 -10
  40. data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
  41. data/lib/aspose_slides_cloud/models/export_options.rb +33 -11
  42. data/lib/aspose_slides_cloud/models/file_version.rb +30 -75
  43. data/lib/aspose_slides_cloud/models/file_versions.rb +22 -10
  44. data/lib/aspose_slides_cloud/models/files_list.rb +22 -10
  45. data/lib/aspose_slides_cloud/models/files_upload_result.rb +22 -10
  46. data/lib/aspose_slides_cloud/models/fill_format.rb +22 -10
  47. data/lib/aspose_slides_cloud/models/fill_overlay_effect.rb +22 -10
  48. data/lib/aspose_slides_cloud/models/font_scheme.rb +30 -40
  49. data/lib/aspose_slides_cloud/models/font_set.rb +22 -10
  50. data/lib/aspose_slides_cloud/models/format_scheme.rb +30 -40
  51. data/lib/aspose_slides_cloud/models/geometry_shape.rb +30 -208
  52. data/lib/aspose_slides_cloud/models/glow_effect.rb +22 -10
  53. data/lib/aspose_slides_cloud/models/gradient_fill.rb +31 -48
  54. data/lib/aspose_slides_cloud/models/gradient_fill_stop.rb +22 -10
  55. data/lib/aspose_slides_cloud/models/graphical_object.rb +31 -217
  56. data/lib/aspose_slides_cloud/models/group_shape.rb +31 -217
  57. data/lib/aspose_slides_cloud/models/html_export_options.rb +33 -32
  58. data/lib/aspose_slides_cloud/models/i_shape_export_options.rb +22 -10
  59. data/lib/aspose_slides_cloud/models/image.rb +30 -40
  60. data/lib/aspose_slides_cloud/models/image_export_options.rb +33 -32
  61. data/lib/aspose_slides_cloud/models/images.rb +30 -40
  62. data/lib/aspose_slides_cloud/models/inner_shadow_effect.rb +22 -10
  63. data/lib/aspose_slides_cloud/models/input.rb +22 -10
  64. data/lib/aspose_slides_cloud/models/input_file.rb +22 -10
  65. data/lib/aspose_slides_cloud/models/interactive_sequence.rb +22 -10
  66. data/lib/aspose_slides_cloud/models/layout_slide.rb +30 -40
  67. data/lib/aspose_slides_cloud/models/layout_slides.rb +30 -40
  68. data/lib/aspose_slides_cloud/models/legend.rb +22 -10
  69. data/lib/aspose_slides_cloud/models/line_format.rb +22 -10
  70. data/lib/aspose_slides_cloud/models/master_slide.rb +30 -40
  71. data/lib/aspose_slides_cloud/models/master_slides.rb +30 -40
  72. data/lib/aspose_slides_cloud/models/merge.rb +31 -48
  73. data/lib/aspose_slides_cloud/models/merging_source.rb +22 -10
  74. data/lib/aspose_slides_cloud/models/no_fill.rb +29 -46
  75. data/lib/aspose_slides_cloud/models/normal_view_restored_properties.rb +217 -0
  76. data/lib/aspose_slides_cloud/models/notes_slide.rb +30 -40
  77. data/lib/aspose_slides_cloud/models/object_exist.rb +22 -10
  78. data/lib/aspose_slides_cloud/models/ole_object_frame.rb +32 -218
  79. data/lib/aspose_slides_cloud/models/one_value_chart_data_point.rb +30 -20
  80. data/lib/aspose_slides_cloud/models/one_value_series.rb +31 -211
  81. data/lib/aspose_slides_cloud/models/ordered_merge_request.rb +22 -10
  82. data/lib/aspose_slides_cloud/models/outer_shadow_effect.rb +22 -10
  83. data/lib/aspose_slides_cloud/models/output_file.rb +22 -10
  84. data/lib/aspose_slides_cloud/models/paragraph.rb +30 -40
  85. data/lib/aspose_slides_cloud/models/paragraphs.rb +30 -40
  86. data/lib/aspose_slides_cloud/models/path_input_file.rb +31 -57
  87. data/lib/aspose_slides_cloud/models/path_output_file.rb +31 -48
  88. data/lib/aspose_slides_cloud/models/pattern_fill.rb +31 -48
  89. data/lib/aspose_slides_cloud/models/pdf_export_options.rb +63 -35
  90. data/lib/aspose_slides_cloud/models/picture_fill.rb +31 -48
  91. data/lib/aspose_slides_cloud/models/picture_frame.rb +32 -244
  92. data/lib/aspose_slides_cloud/models/pipeline.rb +22 -10
  93. data/lib/aspose_slides_cloud/models/placeholder.rb +30 -40
  94. data/lib/aspose_slides_cloud/models/placeholders.rb +30 -40
  95. data/lib/aspose_slides_cloud/models/plot_area.rb +22 -10
  96. data/lib/aspose_slides_cloud/models/portion.rb +30 -40
  97. data/lib/aspose_slides_cloud/models/portions.rb +36 -46
  98. data/lib/aspose_slides_cloud/models/pptx_export_options.rb +33 -32
  99. data/lib/aspose_slides_cloud/models/presentation_to_merge.rb +22 -10
  100. data/lib/aspose_slides_cloud/models/presentations_merge_request.rb +22 -10
  101. data/lib/aspose_slides_cloud/models/preset_shadow_effect.rb +22 -10
  102. data/lib/aspose_slides_cloud/models/reflection_effect.rb +22 -10
  103. data/lib/aspose_slides_cloud/models/remove_shape.rb +31 -48
  104. data/lib/aspose_slides_cloud/models/remove_slide.rb +31 -48
  105. data/lib/aspose_slides_cloud/models/reorder_slide.rb +31 -48
  106. data/lib/aspose_slides_cloud/models/replace_text.rb +31 -48
  107. data/lib/aspose_slides_cloud/models/request_input_file.rb +31 -57
  108. data/lib/aspose_slides_cloud/models/reset_slide.rb +31 -48
  109. data/lib/aspose_slides_cloud/models/resource_base.rb +22 -10
  110. data/lib/aspose_slides_cloud/models/resource_uri.rb +22 -10
  111. data/lib/aspose_slides_cloud/models/resource_uri_element.rb +22 -10
  112. data/lib/aspose_slides_cloud/models/response_output_file.rb +29 -46
  113. data/lib/aspose_slides_cloud/models/save.rb +33 -50
  114. data/lib/aspose_slides_cloud/models/save_shape.rb +31 -48
  115. data/lib/aspose_slides_cloud/models/save_slide.rb +33 -50
  116. data/lib/aspose_slides_cloud/models/scatter_chart_data_point.rb +30 -20
  117. data/lib/aspose_slides_cloud/models/scatter_series.rb +31 -211
  118. data/lib/aspose_slides_cloud/models/series.rb +47 -14
  119. data/lib/aspose_slides_cloud/models/series_marker.rb +22 -10
  120. data/lib/aspose_slides_cloud/models/shape.rb +31 -242
  121. data/lib/aspose_slides_cloud/models/shape_base.rb +30 -40
  122. data/lib/aspose_slides_cloud/models/shape_image_export_options.rb +22 -10
  123. data/lib/aspose_slides_cloud/models/shapes.rb +30 -40
  124. data/lib/aspose_slides_cloud/models/slide.rb +30 -40
  125. data/lib/aspose_slides_cloud/models/slide_animation.rb +30 -40
  126. data/lib/aspose_slides_cloud/models/slide_background.rb +30 -40
  127. data/lib/aspose_slides_cloud/models/slide_comment.rb +22 -10
  128. data/lib/aspose_slides_cloud/models/slide_comments.rb +30 -40
  129. data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
  130. data/lib/aspose_slides_cloud/models/slide_replace_result.rb +30 -154
  131. data/lib/aspose_slides_cloud/models/slides.rb +30 -40
  132. data/lib/aspose_slides_cloud/models/smart_art.rb +32 -218
  133. data/lib/aspose_slides_cloud/models/smart_art_node.rb +22 -10
  134. data/lib/aspose_slides_cloud/models/smart_art_shape.rb +31 -217
  135. data/lib/aspose_slides_cloud/models/soft_edge_effect.rb +22 -10
  136. data/lib/aspose_slides_cloud/models/solid_fill.rb +31 -48
  137. data/lib/aspose_slides_cloud/models/split_document_result.rb +30 -40
  138. data/lib/aspose_slides_cloud/models/storage_exist.rb +22 -10
  139. data/lib/aspose_slides_cloud/models/storage_file.rb +22 -10
  140. data/lib/aspose_slides_cloud/models/svg_export_options.rb +33 -32
  141. data/lib/aspose_slides_cloud/models/swf_export_options.rb +33 -32
  142. data/lib/aspose_slides_cloud/models/table.rb +32 -218
  143. data/lib/aspose_slides_cloud/models/table_cell.rb +22 -10
  144. data/lib/aspose_slides_cloud/models/table_column.rb +22 -10
  145. data/lib/aspose_slides_cloud/models/table_row.rb +22 -10
  146. data/lib/aspose_slides_cloud/models/task.rb +22 -10
  147. data/lib/aspose_slides_cloud/models/text_item.rb +22 -10
  148. data/lib/aspose_slides_cloud/models/text_items.rb +30 -40
  149. data/lib/aspose_slides_cloud/models/theme.rb +30 -40
  150. data/lib/aspose_slides_cloud/models/tiff_export_options.rb +33 -32
  151. data/lib/aspose_slides_cloud/models/update_background.rb +31 -48
  152. data/lib/aspose_slides_cloud/models/update_shape.rb +31 -48
  153. data/lib/aspose_slides_cloud/models/video_frame.rb +32 -244
  154. data/lib/aspose_slides_cloud/models/view_properties.rb +357 -0
  155. data/lib/aspose_slides_cloud/models/waterfall_series.rb +247 -0
  156. data/lib/aspose_slides_cloud/models/xps_export_options.rb +33 -32
  157. data/lib/aspose_slides_cloud/type_registry.rb +313 -0
  158. data/lib/aspose_slides_cloud/version.rb +1 -1
  159. data/spec/api/slides_api_spec.rb +20595 -14073
  160. data/spec/extra/extra_spec.rb +155 -20
  161. data/spec/spec_utils.rb +8 -1
  162. data/testRules.json +111 -8
  163. metadata +11 -2
@@ -24,10 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Represents Pattern Fill
27
- class PatternFill
28
- # Type of fill.
29
- attr_accessor :type
30
-
27
+ class PatternFill < FillFormat
31
28
  # Gets or sets the back color of the pattern fill.
32
29
  attr_accessor :back_color
33
30
 
@@ -61,37 +58,26 @@ module AsposeSlidesCloud
61
58
 
62
59
  # Attribute mapping from ruby-style variable name to JSON key.
63
60
  def self.attribute_map
64
- {
65
- :'type' => :'Type',
61
+ super.merge({
66
62
  :'back_color' => :'BackColor',
67
63
  :'fore_color' => :'ForeColor',
68
- :'style' => :'Style'
69
- }
64
+ :'style' => :'Style',
65
+ })
70
66
  end
71
67
 
72
68
  # Attribute type mapping.
73
69
  def self.swagger_types
74
- {
75
- :'type' => :'String',
70
+ super.merge({
76
71
  :'back_color' => :'String',
77
72
  :'fore_color' => :'String',
78
- :'style' => :'String'
79
- }
73
+ :'style' => :'String',
74
+ })
80
75
  end
81
76
 
82
77
  # Initializes the object
83
78
  # @param [Hash] attributes Model attributes in the form of hash
84
79
  def initialize(attributes = {})
85
- return unless attributes.is_a?(Hash)
86
-
87
- # convert string to symbol for hash key
88
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
89
-
90
- if attributes.has_key?(:'Type')
91
- self.type = attributes[:'Type']
92
- else
93
- self.type = "Pattern"
94
- end
80
+ super
95
81
 
96
82
  if attributes.has_key?(:'BackColor')
97
83
  self.back_color = attributes[:'BackColor']
@@ -104,16 +90,13 @@ module AsposeSlidesCloud
104
90
  if attributes.has_key?(:'Style')
105
91
  self.style = attributes[:'Style']
106
92
  end
93
+ self.type = "Pattern"
107
94
  end
108
95
 
109
96
  # Show invalid properties with the reasons. Usually used together with valid?
110
97
  # @return Array for valid properties with the reasons
111
98
  def list_invalid_properties
112
- invalid_properties = Array.new
113
- if @type.nil?
114
- invalid_properties.push('invalid value for "type", type cannot be nil.')
115
- end
116
-
99
+ invalid_properties = super
117
100
  if @style.nil?
118
101
  invalid_properties.push('invalid value for "style", style cannot be nil.')
119
102
  end
@@ -124,25 +107,13 @@ module AsposeSlidesCloud
124
107
  # Check to see if the all the properties in the model are valid
125
108
  # @return true if the model is valid
126
109
  def valid?
127
- return false if @type.nil?
128
- type_validator = EnumAttributeValidator.new('String', ['NoFill', 'Solid', 'Gradient', 'Pattern', 'Picture', 'NotDefined'])
129
- return false unless type_validator.valid?(@type)
110
+ return false if !super
130
111
  return false if @style.nil?
131
112
  style_validator = EnumAttributeValidator.new('String', ['Unknown', 'Percent05', 'Percent10', 'Percent20', 'Percent25', 'Percent30', 'Percent40', 'Percent50', 'Percent60', 'Percent70', 'Percent75', 'Percent80', 'Percent90', 'DarkHorizontal', 'DarkVertical', 'DarkDownwardDiagonal', 'DarkUpwardDiagonal', 'SmallCheckerBoard', 'Trellis', 'LightHorizontal', 'LightVertical', 'LightDownwardDiagonal', 'LightUpwardDiagonal', 'SmallGrid', 'DottedDiamond', 'WideDownwardDiagonal', 'WideUpwardDiagonal', 'DashedUpwardDiagonal', 'DashedDownwardDiagonal', 'NarrowVertical', 'NarrowHorizontal', 'DashedVertical', 'DashedHorizontal', 'LargeConfetti', 'LargeGrid', 'HorizontalBrick', 'LargeCheckerBoard', 'SmallConfetti', 'Zigzag', 'SolidDiamond', 'DiagonalBrick', 'OutlinedDiamond', 'Plaid', 'Sphere', 'Weave', 'DottedGrid', 'Divot', 'Shingle', 'Wave', 'Horizontal', 'Vertical', 'Cross', 'DownwardDiagonal', 'UpwardDiagonal', 'DiagonalCross', 'NotDefined'])
132
113
  return false unless style_validator.valid?(@style)
133
114
  true
134
115
  end
135
116
 
136
- # Custom attribute writer method checking allowed values (enum).
137
- # @param [Object] type Object to be assigned
138
- def type=(type)
139
- validator = EnumAttributeValidator.new('String', ['NoFill', 'Solid', 'Gradient', 'Pattern', 'Picture', 'NotDefined'])
140
- unless validator.valid?(type)
141
- fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
142
- end
143
- @type = type
144
- end
145
-
146
117
  # Custom attribute writer method checking allowed values (enum).
147
118
  # @param [Object] style Object to be assigned
148
119
  def style=(style)
@@ -182,15 +153,27 @@ module AsposeSlidesCloud
182
153
  def build_from_hash(attributes)
183
154
  return nil unless attributes.is_a?(Hash)
184
155
  self.class.swagger_types.each_pair do |key, type|
185
- if type =~ /\AArray<(.*)>/i
186
- # check to ensure the input is an array given that the the attribute
187
- # is documented as an array but the input is not
188
- if attributes[self.class.attribute_map[key]].is_a?(Array)
189
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
156
+ mapKey = self.class.attribute_map[key]
157
+ if !mapKey.nil?
158
+ val = attributes[mapKey]
159
+ if val.nil?
160
+ mapKeyString = mapKey.to_s
161
+ mapKeyString[0] = mapKeyString[0].downcase
162
+ mapKey = mapKeyString.to_sym
163
+ val = attributes[mapKey]
164
+ end
165
+ if !val.nil?
166
+ if type =~ /\AArray<(.*)>/i
167
+ # check to ensure the input is an array given that the the attribute
168
+ # is documented as an array but the input is not
169
+ if val.is_a?(Array)
170
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
171
+ end
172
+ else
173
+ self.send("#{key}=", _deserialize(type, val))
174
+ end
190
175
  end
191
- elsif !attributes[self.class.attribute_map[key]].nil?
192
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
193
- end # or else data not found in attributes(hash), not an issue as the data can be optional
176
+ end
194
177
  end
195
178
 
196
179
  self
@@ -24,10 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Provides options that control how a presentation is saved in Pdf format.
27
- class PdfExportOptions
28
- # Export format.
29
- attr_accessor :format
30
-
27
+ class PdfExportOptions < ExportOptions
31
28
  # Specifies compression type to be used for all textual content in the document.
32
29
  attr_accessor :text_compression
33
30
 
@@ -82,6 +79,9 @@ module AsposeSlidesCloud
82
79
  # True to apply specified ImageTransparentColor to an image.
83
80
  attr_accessor :apply_image_transparent
84
81
 
82
+ # Access permissions that should be granted when the document is opened with user access. Default is AccessPermissions.None.
83
+ attr_accessor :access_permissions
84
+
85
85
  class EnumAttributeValidator
86
86
  attr_reader :datatype
87
87
  attr_reader :allowable_values
@@ -106,8 +106,7 @@ module AsposeSlidesCloud
106
106
 
107
107
  # Attribute mapping from ruby-style variable name to JSON key.
108
108
  def self.attribute_map
109
- {
110
- :'format' => :'Format',
109
+ super.merge({
111
110
  :'text_compression' => :'TextCompression',
112
111
  :'embed_full_fonts' => :'EmbedFullFonts',
113
112
  :'compliance' => :'Compliance',
@@ -125,14 +124,14 @@ module AsposeSlidesCloud
125
124
  :'comments_area_color' => :'CommentsAreaColor',
126
125
  :'show_comments_by_no_author' => :'ShowCommentsByNoAuthor',
127
126
  :'image_transparent_color' => :'ImageTransparentColor',
128
- :'apply_image_transparent' => :'ApplyImageTransparent'
129
- }
127
+ :'apply_image_transparent' => :'ApplyImageTransparent',
128
+ :'access_permissions' => :'AccessPermissions',
129
+ })
130
130
  end
131
131
 
132
132
  # Attribute type mapping.
133
133
  def self.swagger_types
134
- {
135
- :'format' => :'String',
134
+ super.merge({
136
135
  :'text_compression' => :'String',
137
136
  :'embed_full_fonts' => :'BOOLEAN',
138
137
  :'compliance' => :'String',
@@ -150,23 +149,15 @@ module AsposeSlidesCloud
150
149
  :'comments_area_color' => :'String',
151
150
  :'show_comments_by_no_author' => :'BOOLEAN',
152
151
  :'image_transparent_color' => :'String',
153
- :'apply_image_transparent' => :'BOOLEAN'
154
- }
152
+ :'apply_image_transparent' => :'BOOLEAN',
153
+ :'access_permissions' => :'String',
154
+ })
155
155
  end
156
156
 
157
157
  # Initializes the object
158
158
  # @param [Hash] attributes Model attributes in the form of hash
159
159
  def initialize(attributes = {})
160
- return unless attributes.is_a?(Hash)
161
-
162
- # convert string to symbol for hash key
163
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
164
-
165
- if attributes.has_key?(:'Format')
166
- self.format = attributes[:'Format']
167
- else
168
- self.format = "pdf"
169
- end
160
+ super
170
161
 
171
162
  if attributes.has_key?(:'TextCompression')
172
163
  self.text_compression = attributes[:'TextCompression']
@@ -241,12 +232,17 @@ module AsposeSlidesCloud
241
232
  if attributes.has_key?(:'ApplyImageTransparent')
242
233
  self.apply_image_transparent = attributes[:'ApplyImageTransparent']
243
234
  end
235
+
236
+ if attributes.has_key?(:'AccessPermissions')
237
+ self.access_permissions = attributes[:'AccessPermissions']
238
+ end
239
+ self.format = "pdf"
244
240
  end
245
241
 
246
242
  # Show invalid properties with the reasons. Usually used together with valid?
247
243
  # @return Array for valid properties with the reasons
248
244
  def list_invalid_properties
249
- invalid_properties = Array.new
245
+ invalid_properties = super
250
246
  if @text_compression.nil?
251
247
  invalid_properties.push('invalid value for "text_compression", text_compression cannot be nil.')
252
248
  end
@@ -303,18 +299,23 @@ module AsposeSlidesCloud
303
299
  invalid_properties.push('invalid value for "apply_image_transparent", apply_image_transparent cannot be nil.')
304
300
  end
305
301
 
302
+ if @access_permissions.nil?
303
+ invalid_properties.push('invalid value for "access_permissions", access_permissions cannot be nil.')
304
+ end
305
+
306
306
  invalid_properties
307
307
  end
308
308
 
309
309
  # Check to see if the all the properties in the model are valid
310
310
  # @return true if the model is valid
311
311
  def valid?
312
+ return false if !super
312
313
  return false if @text_compression.nil?
313
314
  text_compression_validator = EnumAttributeValidator.new('String', ['None', 'Flate'])
314
315
  return false unless text_compression_validator.valid?(@text_compression)
315
316
  return false if @embed_full_fonts.nil?
316
317
  return false if @compliance.nil?
317
- compliance_validator = EnumAttributeValidator.new('String', ['Pdf15', 'PdfA1b'])
318
+ compliance_validator = EnumAttributeValidator.new('String', ['Pdf15', 'PdfA1b', 'PdfA1a', 'PdfUa'])
318
319
  return false unless compliance_validator.valid?(@compliance)
319
320
  return false if @sufficient_resolution.nil?
320
321
  return false if @jpeg_quality.nil?
@@ -331,6 +332,9 @@ module AsposeSlidesCloud
331
332
  return false if @comments_area_width.nil?
332
333
  return false if @show_comments_by_no_author.nil?
333
334
  return false if @apply_image_transparent.nil?
335
+ return false if @access_permissions.nil?
336
+ access_permissions_validator = EnumAttributeValidator.new('String', ['None', 'PrintDocument', 'ModifyContent', 'CopyTextAndGraphics', 'AddOrModifyFields', 'FillExistingFields', 'ExtractTextAndGraphics', 'AssembleDocument', 'HighQualityPrint'])
337
+ return false unless access_permissions_validator.valid?(@access_permissions)
334
338
  true
335
339
  end
336
340
 
@@ -347,7 +351,7 @@ module AsposeSlidesCloud
347
351
  # Custom attribute writer method checking allowed values (enum).
348
352
  # @param [Object] compliance Object to be assigned
349
353
  def compliance=(compliance)
350
- validator = EnumAttributeValidator.new('String', ['Pdf15', 'PdfA1b'])
354
+ validator = EnumAttributeValidator.new('String', ['Pdf15', 'PdfA1b', 'PdfA1a', 'PdfUa'])
351
355
  unless validator.valid?(compliance)
352
356
  fail ArgumentError, 'invalid value for "compliance", must be one of #{validator.allowable_values}.'
353
357
  end
@@ -374,11 +378,22 @@ module AsposeSlidesCloud
374
378
  @comments_position = comments_position
375
379
  end
376
380
 
381
+ # Custom attribute writer method checking allowed values (enum).
382
+ # @param [Object] access_permissions Object to be assigned
383
+ def access_permissions=(access_permissions)
384
+ validator = EnumAttributeValidator.new('String', ['None', 'PrintDocument', 'ModifyContent', 'CopyTextAndGraphics', 'AddOrModifyFields', 'FillExistingFields', 'ExtractTextAndGraphics', 'AssembleDocument', 'HighQualityPrint'])
385
+ unless validator.valid?(access_permissions)
386
+ fail ArgumentError, 'invalid value for "access_permissions", must be one of #{validator.allowable_values}.'
387
+ end
388
+ @access_permissions = access_permissions
389
+ end
390
+
377
391
  # Checks equality by comparing each attribute.
378
392
  # @param [Object] Object to be compared
379
393
  def ==(o)
380
394
  return true if self.equal?(o)
381
395
  self.class == o.class &&
396
+ default_regular_font == o.default_regular_font &&
382
397
  format == o.format &&
383
398
  text_compression == o.text_compression &&
384
399
  embed_full_fonts == o.embed_full_fonts &&
@@ -397,7 +412,8 @@ module AsposeSlidesCloud
397
412
  comments_area_color == o.comments_area_color &&
398
413
  show_comments_by_no_author == o.show_comments_by_no_author &&
399
414
  image_transparent_color == o.image_transparent_color &&
400
- apply_image_transparent == o.apply_image_transparent
415
+ apply_image_transparent == o.apply_image_transparent &&
416
+ access_permissions == o.access_permissions
401
417
  end
402
418
 
403
419
  # @see the `==` method
@@ -409,7 +425,7 @@ module AsposeSlidesCloud
409
425
  # Calculates hash code according to all attributes.
410
426
  # @return [Fixnum] Hash code
411
427
  def hash
412
- [format, text_compression, embed_full_fonts, compliance, sufficient_resolution, jpeg_quality, draw_slides_frame, show_hidden_slides, save_metafiles_as_png, password, embed_true_type_fonts_for_ascii, additional_common_font_families, notes_position, comments_position, comments_area_width, comments_area_color, show_comments_by_no_author, image_transparent_color, apply_image_transparent].hash
428
+ [default_regular_font, format, text_compression, embed_full_fonts, compliance, sufficient_resolution, jpeg_quality, draw_slides_frame, show_hidden_slides, save_metafiles_as_png, password, embed_true_type_fonts_for_ascii, additional_common_font_families, notes_position, comments_position, comments_area_width, comments_area_color, show_comments_by_no_author, image_transparent_color, apply_image_transparent, access_permissions].hash
413
429
  end
414
430
 
415
431
  # Builds the object from hash
@@ -418,15 +434,27 @@ module AsposeSlidesCloud
418
434
  def build_from_hash(attributes)
419
435
  return nil unless attributes.is_a?(Hash)
420
436
  self.class.swagger_types.each_pair do |key, type|
421
- if type =~ /\AArray<(.*)>/i
422
- # check to ensure the input is an array given that the the attribute
423
- # is documented as an array but the input is not
424
- if attributes[self.class.attribute_map[key]].is_a?(Array)
425
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
437
+ mapKey = self.class.attribute_map[key]
438
+ if !mapKey.nil?
439
+ val = attributes[mapKey]
440
+ if val.nil?
441
+ mapKeyString = mapKey.to_s
442
+ mapKeyString[0] = mapKeyString[0].downcase
443
+ mapKey = mapKeyString.to_sym
444
+ val = attributes[mapKey]
426
445
  end
427
- elsif !attributes[self.class.attribute_map[key]].nil?
428
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
429
- end # or else data not found in attributes(hash), not an issue as the data can be optional
446
+ if !val.nil?
447
+ if type =~ /\AArray<(.*)>/i
448
+ # check to ensure the input is an array given that the the attribute
449
+ # is documented as an array but the input is not
450
+ if val.is_a?(Array)
451
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
452
+ end
453
+ else
454
+ self.send("#{key}=", _deserialize(type, val))
455
+ end
456
+ end
457
+ end
430
458
  end
431
459
 
432
460
  self
@@ -24,10 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Picture fill.
27
- class PictureFill
28
- # Fill type.
29
- attr_accessor :type
30
-
27
+ class PictureFill < FillFormat
31
28
  # Percentage of image height that is cropped from the bottom.
32
29
  attr_accessor :crop_bottom
33
30
 
@@ -79,8 +76,7 @@ module AsposeSlidesCloud
79
76
 
80
77
  # Attribute mapping from ruby-style variable name to JSON key.
81
78
  def self.attribute_map
82
- {
83
- :'type' => :'Type',
79
+ super.merge({
84
80
  :'crop_bottom' => :'CropBottom',
85
81
  :'crop_left' => :'CropLeft',
86
82
  :'crop_right' => :'CropRight',
@@ -89,14 +85,13 @@ module AsposeSlidesCloud
89
85
  :'image' => :'Image',
90
86
  :'base64_data' => :'Base64Data',
91
87
  :'svg_data' => :'SvgData',
92
- :'picture_fill_mode' => :'PictureFillMode'
93
- }
88
+ :'picture_fill_mode' => :'PictureFillMode',
89
+ })
94
90
  end
95
91
 
96
92
  # Attribute type mapping.
97
93
  def self.swagger_types
98
- {
99
- :'type' => :'String',
94
+ super.merge({
100
95
  :'crop_bottom' => :'Float',
101
96
  :'crop_left' => :'Float',
102
97
  :'crop_right' => :'Float',
@@ -105,23 +100,14 @@ module AsposeSlidesCloud
105
100
  :'image' => :'ResourceUriElement',
106
101
  :'base64_data' => :'String',
107
102
  :'svg_data' => :'String',
108
- :'picture_fill_mode' => :'String'
109
- }
103
+ :'picture_fill_mode' => :'String',
104
+ })
110
105
  end
111
106
 
112
107
  # Initializes the object
113
108
  # @param [Hash] attributes Model attributes in the form of hash
114
109
  def initialize(attributes = {})
115
- return unless attributes.is_a?(Hash)
116
-
117
- # convert string to symbol for hash key
118
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
119
-
120
- if attributes.has_key?(:'Type')
121
- self.type = attributes[:'Type']
122
- else
123
- self.type = "Picture"
124
- end
110
+ super
125
111
 
126
112
  if attributes.has_key?(:'CropBottom')
127
113
  self.crop_bottom = attributes[:'CropBottom']
@@ -158,16 +144,13 @@ module AsposeSlidesCloud
158
144
  if attributes.has_key?(:'PictureFillMode')
159
145
  self.picture_fill_mode = attributes[:'PictureFillMode']
160
146
  end
147
+ self.type = "Picture"
161
148
  end
162
149
 
163
150
  # Show invalid properties with the reasons. Usually used together with valid?
164
151
  # @return Array for valid properties with the reasons
165
152
  def list_invalid_properties
166
- invalid_properties = Array.new
167
- if @type.nil?
168
- invalid_properties.push('invalid value for "type", type cannot be nil.')
169
- end
170
-
153
+ invalid_properties = super
171
154
  if @crop_bottom.nil?
172
155
  invalid_properties.push('invalid value for "crop_bottom", crop_bottom cannot be nil.')
173
156
  end
@@ -198,9 +181,7 @@ module AsposeSlidesCloud
198
181
  # Check to see if the all the properties in the model are valid
199
182
  # @return true if the model is valid
200
183
  def valid?
201
- return false if @type.nil?
202
- type_validator = EnumAttributeValidator.new('String', ['NoFill', 'Solid', 'Gradient', 'Pattern', 'Picture', 'NotDefined'])
203
- return false unless type_validator.valid?(@type)
184
+ return false if !super
204
185
  return false if @crop_bottom.nil?
205
186
  return false if @crop_left.nil?
206
187
  return false if @crop_right.nil?
@@ -212,16 +193,6 @@ module AsposeSlidesCloud
212
193
  true
213
194
  end
214
195
 
215
- # Custom attribute writer method checking allowed values (enum).
216
- # @param [Object] type Object to be assigned
217
- def type=(type)
218
- validator = EnumAttributeValidator.new('String', ['NoFill', 'Solid', 'Gradient', 'Pattern', 'Picture', 'NotDefined'])
219
- unless validator.valid?(type)
220
- fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
221
- end
222
- @type = type
223
- end
224
-
225
196
  # Custom attribute writer method checking allowed values (enum).
226
197
  # @param [Object] picture_fill_mode Object to be assigned
227
198
  def picture_fill_mode=(picture_fill_mode)
@@ -267,15 +238,27 @@ module AsposeSlidesCloud
267
238
  def build_from_hash(attributes)
268
239
  return nil unless attributes.is_a?(Hash)
269
240
  self.class.swagger_types.each_pair do |key, type|
270
- if type =~ /\AArray<(.*)>/i
271
- # check to ensure the input is an array given that the the attribute
272
- # is documented as an array but the input is not
273
- if attributes[self.class.attribute_map[key]].is_a?(Array)
274
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
241
+ mapKey = self.class.attribute_map[key]
242
+ if !mapKey.nil?
243
+ val = attributes[mapKey]
244
+ if val.nil?
245
+ mapKeyString = mapKey.to_s
246
+ mapKeyString[0] = mapKeyString[0].downcase
247
+ mapKey = mapKeyString.to_sym
248
+ val = attributes[mapKey]
249
+ end
250
+ if !val.nil?
251
+ if type =~ /\AArray<(.*)>/i
252
+ # check to ensure the input is an array given that the the attribute
253
+ # is documented as an array but the input is not
254
+ if val.is_a?(Array)
255
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
256
+ end
257
+ else
258
+ self.send("#{key}=", _deserialize(type, val))
259
+ end
275
260
  end
276
- elsif !attributes[self.class.attribute_map[key]].nil?
277
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
278
- end # or else data not found in attributes(hash), not an issue as the data can be optional
261
+ end
279
262
  end
280
263
 
281
264
  self