aspose_slides_cloud 20.5.0 → 20.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (171) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -3
  3. data/TestData/ChartTest.pptx +0 -0
  4. data/TestData/Sections.pptx +0 -0
  5. data/lib/aspose_slides_cloud.rb +12 -5
  6. data/lib/aspose_slides_cloud/api/slides_api.rb +4571 -1683
  7. data/lib/aspose_slides_cloud/api/slides_api_requests.rb +1191 -185
  8. data/lib/aspose_slides_cloud/api_client.rb +30 -23
  9. data/lib/aspose_slides_cloud/configuration.rb +7 -2
  10. data/lib/aspose_slides_cloud/models/add_layout_slide.rb +31 -48
  11. data/lib/aspose_slides_cloud/models/add_master_slide.rb +31 -48
  12. data/lib/aspose_slides_cloud/models/add_shape.rb +31 -48
  13. data/lib/aspose_slides_cloud/models/add_slide.rb +31 -48
  14. data/lib/aspose_slides_cloud/models/api_info.rb +22 -10
  15. data/lib/aspose_slides_cloud/models/arrow_head_properties.rb +22 -10
  16. data/lib/aspose_slides_cloud/models/audio_frame.rb +32 -246
  17. data/lib/aspose_slides_cloud/models/axes.rb +22 -10
  18. data/lib/aspose_slides_cloud/models/axis.rb +22 -10
  19. data/lib/aspose_slides_cloud/models/base64_input_file.rb +31 -57
  20. data/lib/aspose_slides_cloud/models/blur_effect.rb +22 -10
  21. data/lib/aspose_slides_cloud/models/box_and_whisker_series.rb +31 -222
  22. data/lib/aspose_slides_cloud/models/bubble_chart_data_point.rb +30 -48
  23. data/lib/aspose_slides_cloud/models/bubble_series.rb +31 -211
  24. data/lib/aspose_slides_cloud/models/chart.rb +32 -220
  25. data/lib/aspose_slides_cloud/models/chart_category.rb +54 -20
  26. data/lib/aspose_slides_cloud/models/chart_title.rb +22 -10
  27. data/lib/aspose_slides_cloud/models/chart_wall.rb +22 -10
  28. data/lib/aspose_slides_cloud/models/color_scheme.rb +30 -40
  29. data/lib/aspose_slides_cloud/models/common_slide_view_properties.rb +22 -10
  30. data/lib/aspose_slides_cloud/models/connector.rb +32 -244
  31. data/lib/aspose_slides_cloud/models/custom_dash_pattern.rb +22 -10
  32. data/lib/aspose_slides_cloud/models/{resource_uri_element.rb → data_point.rb} +24 -22
  33. data/lib/aspose_slides_cloud/models/disc_usage.rb +22 -10
  34. data/lib/aspose_slides_cloud/models/document.rb +35 -45
  35. data/lib/aspose_slides_cloud/models/document_properties.rb +30 -40
  36. data/lib/aspose_slides_cloud/models/document_property.rb +30 -40
  37. data/lib/aspose_slides_cloud/models/document_replace_result.rb +30 -94
  38. data/lib/aspose_slides_cloud/models/effect.rb +22 -10
  39. data/lib/aspose_slides_cloud/models/effect_format.rb +22 -10
  40. data/lib/aspose_slides_cloud/models/entity_exists.rb +212 -0
  41. data/lib/aspose_slides_cloud/models/error.rb +22 -10
  42. data/lib/aspose_slides_cloud/models/error_details.rb +22 -10
  43. data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
  44. data/lib/aspose_slides_cloud/models/export_options.rb +33 -11
  45. data/lib/aspose_slides_cloud/models/file_version.rb +30 -75
  46. data/lib/aspose_slides_cloud/models/file_versions.rb +22 -10
  47. data/lib/aspose_slides_cloud/models/files_list.rb +22 -10
  48. data/lib/aspose_slides_cloud/models/files_upload_result.rb +22 -10
  49. data/lib/aspose_slides_cloud/models/fill_format.rb +22 -10
  50. data/lib/aspose_slides_cloud/models/fill_overlay_effect.rb +22 -10
  51. data/lib/aspose_slides_cloud/models/font_scheme.rb +30 -40
  52. data/lib/aspose_slides_cloud/models/font_set.rb +22 -10
  53. data/lib/aspose_slides_cloud/models/format_scheme.rb +30 -40
  54. data/lib/aspose_slides_cloud/models/geometry_shape.rb +33 -212
  55. data/lib/aspose_slides_cloud/models/glow_effect.rb +22 -10
  56. data/lib/aspose_slides_cloud/models/gradient_fill.rb +31 -48
  57. data/lib/aspose_slides_cloud/models/gradient_fill_stop.rb +22 -10
  58. data/lib/aspose_slides_cloud/models/graphical_object.rb +31 -219
  59. data/lib/aspose_slides_cloud/models/group_shape.rb +31 -219
  60. data/lib/aspose_slides_cloud/models/header_footer.rb +247 -0
  61. data/lib/aspose_slides_cloud/models/html_export_options.rb +33 -32
  62. data/lib/aspose_slides_cloud/models/i_shape_export_options.rb +22 -20
  63. data/lib/aspose_slides_cloud/models/image.rb +30 -40
  64. data/lib/aspose_slides_cloud/models/image_export_options.rb +33 -32
  65. data/lib/aspose_slides_cloud/models/images.rb +30 -40
  66. data/lib/aspose_slides_cloud/models/inner_shadow_effect.rb +22 -10
  67. data/lib/aspose_slides_cloud/models/input.rb +22 -10
  68. data/lib/aspose_slides_cloud/models/input_file.rb +22 -10
  69. data/lib/aspose_slides_cloud/models/interactive_sequence.rb +22 -10
  70. data/lib/aspose_slides_cloud/models/layout_slide.rb +31 -41
  71. data/lib/aspose_slides_cloud/models/layout_slides.rb +30 -40
  72. data/lib/aspose_slides_cloud/models/legend.rb +22 -10
  73. data/lib/aspose_slides_cloud/models/line_format.rb +22 -10
  74. data/lib/aspose_slides_cloud/models/master_slide.rb +31 -41
  75. data/lib/aspose_slides_cloud/models/master_slides.rb +30 -40
  76. data/lib/aspose_slides_cloud/models/merge.rb +31 -48
  77. data/lib/aspose_slides_cloud/models/merging_source.rb +22 -10
  78. data/lib/aspose_slides_cloud/models/no_fill.rb +29 -46
  79. data/lib/aspose_slides_cloud/models/normal_view_restored_properties.rb +22 -10
  80. data/lib/aspose_slides_cloud/models/notes_slide.rb +30 -40
  81. data/lib/aspose_slides_cloud/models/notes_slide_header_footer.rb +267 -0
  82. data/lib/aspose_slides_cloud/models/object_exist.rb +22 -10
  83. data/lib/aspose_slides_cloud/models/ole_object_frame.rb +32 -220
  84. data/lib/aspose_slides_cloud/models/one_value_chart_data_point.rb +30 -20
  85. data/lib/aspose_slides_cloud/models/one_value_series.rb +31 -211
  86. data/lib/aspose_slides_cloud/models/ordered_merge_request.rb +22 -10
  87. data/lib/aspose_slides_cloud/models/outer_shadow_effect.rb +22 -10
  88. data/lib/aspose_slides_cloud/models/output_file.rb +22 -10
  89. data/lib/aspose_slides_cloud/models/paragraph.rb +30 -40
  90. data/lib/aspose_slides_cloud/models/paragraphs.rb +30 -40
  91. data/lib/aspose_slides_cloud/models/path_input_file.rb +31 -57
  92. data/lib/aspose_slides_cloud/models/path_output_file.rb +31 -48
  93. data/lib/aspose_slides_cloud/models/pattern_fill.rb +31 -48
  94. data/lib/aspose_slides_cloud/models/pdf_export_options.rb +63 -35
  95. data/lib/aspose_slides_cloud/models/picture_fill.rb +32 -49
  96. data/lib/aspose_slides_cloud/models/picture_frame.rb +32 -246
  97. data/lib/aspose_slides_cloud/models/pipeline.rb +22 -10
  98. data/lib/aspose_slides_cloud/models/placeholder.rb +30 -40
  99. data/lib/aspose_slides_cloud/models/placeholders.rb +30 -40
  100. data/lib/aspose_slides_cloud/models/plot_area.rb +22 -10
  101. data/lib/aspose_slides_cloud/models/portion.rb +30 -40
  102. data/lib/aspose_slides_cloud/models/portions.rb +36 -46
  103. data/lib/aspose_slides_cloud/models/pptx_export_options.rb +33 -32
  104. data/lib/aspose_slides_cloud/models/presentation_to_merge.rb +22 -10
  105. data/lib/aspose_slides_cloud/models/presentations_merge_request.rb +22 -10
  106. data/lib/aspose_slides_cloud/models/preset_shadow_effect.rb +22 -10
  107. data/lib/aspose_slides_cloud/models/reflection_effect.rb +22 -10
  108. data/lib/aspose_slides_cloud/models/remove_shape.rb +31 -48
  109. data/lib/aspose_slides_cloud/models/remove_slide.rb +31 -48
  110. data/lib/aspose_slides_cloud/models/reorder_slide.rb +31 -48
  111. data/lib/aspose_slides_cloud/models/replace_text.rb +31 -48
  112. data/lib/aspose_slides_cloud/models/request_input_file.rb +31 -57
  113. data/lib/aspose_slides_cloud/models/reset_slide.rb +31 -48
  114. data/lib/aspose_slides_cloud/models/resource_base.rb +22 -10
  115. data/lib/aspose_slides_cloud/models/resource_uri.rb +22 -10
  116. data/lib/aspose_slides_cloud/models/response_output_file.rb +29 -46
  117. data/lib/aspose_slides_cloud/models/save.rb +33 -50
  118. data/lib/aspose_slides_cloud/models/save_shape.rb +31 -48
  119. data/lib/aspose_slides_cloud/models/save_slide.rb +33 -50
  120. data/lib/aspose_slides_cloud/models/scatter_chart_data_point.rb +30 -20
  121. data/lib/aspose_slides_cloud/models/scatter_series.rb +31 -211
  122. data/lib/aspose_slides_cloud/models/section.rb +234 -0
  123. data/lib/aspose_slides_cloud/models/sections.rb +209 -0
  124. data/lib/aspose_slides_cloud/models/series.rb +45 -12
  125. data/lib/aspose_slides_cloud/models/series_marker.rb +22 -10
  126. data/lib/aspose_slides_cloud/models/shape.rb +32 -244
  127. data/lib/aspose_slides_cloud/models/shape_base.rb +31 -62
  128. data/lib/aspose_slides_cloud/models/shape_image_export_options.rb +22 -10
  129. data/lib/aspose_slides_cloud/models/shapes.rb +30 -40
  130. data/lib/aspose_slides_cloud/models/slide.rb +37 -47
  131. data/lib/aspose_slides_cloud/models/slide_animation.rb +30 -40
  132. data/lib/aspose_slides_cloud/models/slide_background.rb +30 -40
  133. data/lib/aspose_slides_cloud/models/slide_comment.rb +22 -10
  134. data/lib/aspose_slides_cloud/models/slide_comments.rb +30 -40
  135. data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
  136. data/lib/aspose_slides_cloud/models/slide_replace_result.rb +30 -154
  137. data/lib/aspose_slides_cloud/models/slides.rb +30 -40
  138. data/lib/aspose_slides_cloud/models/smart_art.rb +32 -220
  139. data/lib/aspose_slides_cloud/models/smart_art_node.rb +23 -11
  140. data/lib/aspose_slides_cloud/models/smart_art_shape.rb +30 -217
  141. data/lib/aspose_slides_cloud/models/soft_edge_effect.rb +22 -10
  142. data/lib/aspose_slides_cloud/models/solid_fill.rb +31 -48
  143. data/lib/aspose_slides_cloud/models/split_document_result.rb +30 -40
  144. data/lib/aspose_slides_cloud/models/storage_exist.rb +22 -10
  145. data/lib/aspose_slides_cloud/models/storage_file.rb +22 -10
  146. data/lib/aspose_slides_cloud/models/svg_export_options.rb +33 -32
  147. data/lib/aspose_slides_cloud/models/swf_export_options.rb +33 -32
  148. data/lib/aspose_slides_cloud/models/table.rb +32 -220
  149. data/lib/aspose_slides_cloud/models/table_cell.rb +22 -10
  150. data/lib/aspose_slides_cloud/models/table_column.rb +22 -10
  151. data/lib/aspose_slides_cloud/models/table_row.rb +22 -10
  152. data/lib/aspose_slides_cloud/models/task.rb +22 -10
  153. data/lib/aspose_slides_cloud/models/text_item.rb +22 -10
  154. data/lib/aspose_slides_cloud/models/text_items.rb +30 -40
  155. data/lib/aspose_slides_cloud/models/theme.rb +32 -42
  156. data/lib/aspose_slides_cloud/models/tiff_export_options.rb +33 -32
  157. data/lib/aspose_slides_cloud/models/update_background.rb +31 -48
  158. data/lib/aspose_slides_cloud/models/update_shape.rb +31 -48
  159. data/lib/aspose_slides_cloud/models/video_frame.rb +32 -246
  160. data/lib/aspose_slides_cloud/models/view_properties.rb +30 -40
  161. data/lib/aspose_slides_cloud/models/waterfall_chart_data_point.rb +206 -0
  162. data/lib/aspose_slides_cloud/models/waterfall_series.rb +31 -222
  163. data/lib/aspose_slides_cloud/models/xps_export_options.rb +33 -32
  164. data/lib/aspose_slides_cloud/type_registry.rb +320 -0
  165. data/lib/aspose_slides_cloud/version.rb +1 -1
  166. data/spec/api/slides_api_spec.rb +25246 -14028
  167. data/spec/extra/extra_spec.rb +156 -22
  168. data/spec/spec_utils.rb +11 -4
  169. data/testConfig.json +2 -2
  170. data/testRules.json +172 -77
  171. metadata +12 -3
@@ -24,51 +24,28 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Placeholder list.
27
- class Placeholders
28
- # Gets or sets the link to this resource.
29
- attr_accessor :self_uri
30
-
31
- # List of alternate links.
32
- attr_accessor :alternate_links
33
-
27
+ class Placeholders < ResourceBase
34
28
  # List for placeholder links.
35
29
  attr_accessor :placeholder_links
36
30
 
37
31
  # Attribute mapping from ruby-style variable name to JSON key.
38
32
  def self.attribute_map
39
- {
40
- :'self_uri' => :'SelfUri',
41
- :'alternate_links' => :'AlternateLinks',
42
- :'placeholder_links' => :'PlaceholderLinks'
43
- }
33
+ super.merge({
34
+ :'placeholder_links' => :'PlaceholderLinks',
35
+ })
44
36
  end
45
37
 
46
38
  # Attribute type mapping.
47
39
  def self.swagger_types
48
- {
49
- :'self_uri' => :'ResourceUri',
50
- :'alternate_links' => :'Array<ResourceUri>',
51
- :'placeholder_links' => :'Array<ResourceUri>'
52
- }
40
+ super.merge({
41
+ :'placeholder_links' => :'Array<ResourceUri>',
42
+ })
53
43
  end
54
44
 
55
45
  # Initializes the object
56
46
  # @param [Hash] attributes Model attributes in the form of hash
57
47
  def initialize(attributes = {})
58
- return unless attributes.is_a?(Hash)
59
-
60
- # convert string to symbol for hash key
61
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
62
-
63
- if attributes.has_key?(:'SelfUri')
64
- self.self_uri = attributes[:'SelfUri']
65
- end
66
-
67
- if attributes.has_key?(:'AlternateLinks')
68
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
69
- self.alternate_links = value
70
- end
71
- end
48
+ super
72
49
 
73
50
  if attributes.has_key?(:'PlaceholderLinks')
74
51
  if (value = attributes[:'PlaceholderLinks']).is_a?(Array)
@@ -80,13 +57,14 @@ module AsposeSlidesCloud
80
57
  # Show invalid properties with the reasons. Usually used together with valid?
81
58
  # @return Array for valid properties with the reasons
82
59
  def list_invalid_properties
83
- invalid_properties = Array.new
60
+ invalid_properties = super
84
61
  invalid_properties
85
62
  end
86
63
 
87
64
  # Check to see if the all the properties in the model are valid
88
65
  # @return true if the model is valid
89
66
  def valid?
67
+ return false if !super
90
68
  true
91
69
  end
92
70
 
@@ -118,15 +96,27 @@ module AsposeSlidesCloud
118
96
  def build_from_hash(attributes)
119
97
  return nil unless attributes.is_a?(Hash)
120
98
  self.class.swagger_types.each_pair do |key, type|
121
- if type =~ /\AArray<(.*)>/i
122
- # check to ensure the input is an array given that the the attribute
123
- # is documented as an array but the input is not
124
- if attributes[self.class.attribute_map[key]].is_a?(Array)
125
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
99
+ mapKey = self.class.attribute_map[key]
100
+ if !mapKey.nil?
101
+ val = attributes[mapKey]
102
+ if val.nil?
103
+ mapKeyString = mapKey.to_s
104
+ mapKeyString[0] = mapKeyString[0].downcase
105
+ mapKey = mapKeyString.to_sym
106
+ val = attributes[mapKey]
126
107
  end
127
- elsif !attributes[self.class.attribute_map[key]].nil?
128
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
129
- end # or else data not found in attributes(hash), not an issue as the data can be optional
108
+ if !val.nil?
109
+ if type =~ /\AArray<(.*)>/i
110
+ # check to ensure the input is an array given that the the attribute
111
+ # is documented as an array but the input is not
112
+ if val.is_a?(Array)
113
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
114
+ end
115
+ else
116
+ self.send("#{key}=", _deserialize(type, val))
117
+ end
118
+ end
119
+ end
130
120
  end
131
121
 
132
122
  self
@@ -81,7 +81,7 @@ module AsposeSlidesCloud
81
81
  :'layout_target_type' => :'LayoutTargetType',
82
82
  :'fill_format' => :'FillFormat',
83
83
  :'effect_format' => :'EffectFormat',
84
- :'line_format' => :'LineFormat'
84
+ :'line_format' => :'LineFormat',
85
85
  }
86
86
  end
87
87
 
@@ -95,7 +95,7 @@ module AsposeSlidesCloud
95
95
  :'layout_target_type' => :'String',
96
96
  :'fill_format' => :'FillFormat',
97
97
  :'effect_format' => :'EffectFormat',
98
- :'line_format' => :'LineFormat'
98
+ :'line_format' => :'LineFormat',
99
99
  }
100
100
  end
101
101
 
@@ -198,15 +198,27 @@ module AsposeSlidesCloud
198
198
  def build_from_hash(attributes)
199
199
  return nil unless attributes.is_a?(Hash)
200
200
  self.class.swagger_types.each_pair do |key, type|
201
- if type =~ /\AArray<(.*)>/i
202
- # check to ensure the input is an array given that the the attribute
203
- # is documented as an array but the input is not
204
- if attributes[self.class.attribute_map[key]].is_a?(Array)
205
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
201
+ mapKey = self.class.attribute_map[key]
202
+ if !mapKey.nil?
203
+ val = attributes[mapKey]
204
+ if val.nil?
205
+ mapKeyString = mapKey.to_s
206
+ mapKeyString[0] = mapKeyString[0].downcase
207
+ mapKey = mapKeyString.to_sym
208
+ val = attributes[mapKey]
206
209
  end
207
- elsif !attributes[self.class.attribute_map[key]].nil?
208
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
209
- end # or else data not found in attributes(hash), not an issue as the data can be optional
210
+ if !val.nil?
211
+ if type =~ /\AArray<(.*)>/i
212
+ # check to ensure the input is an array given that the the attribute
213
+ # is documented as an array but the input is not
214
+ if val.is_a?(Array)
215
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
216
+ end
217
+ else
218
+ self.send("#{key}=", _deserialize(type, val))
219
+ end
220
+ end
221
+ end
210
222
  end
211
223
 
212
224
  self
@@ -24,13 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Represents portion resource
27
- class Portion
28
- # Gets or sets the link to this resource.
29
- attr_accessor :self_uri
30
-
31
- # List of alternate links.
32
- attr_accessor :alternate_links
33
-
27
+ class Portion < ResourceBase
34
28
  # Text.
35
29
  attr_accessor :text
36
30
 
@@ -130,9 +124,7 @@ module AsposeSlidesCloud
130
124
 
131
125
  # Attribute mapping from ruby-style variable name to JSON key.
132
126
  def self.attribute_map
133
- {
134
- :'self_uri' => :'SelfUri',
135
- :'alternate_links' => :'AlternateLinks',
127
+ super.merge({
136
128
  :'text' => :'Text',
137
129
  :'font_bold' => :'FontBold',
138
130
  :'font_italic' => :'FontItalic',
@@ -157,15 +149,13 @@ module AsposeSlidesCloud
157
149
  :'effect_format' => :'EffectFormat',
158
150
  :'line_format' => :'LineFormat',
159
151
  :'underline_fill_format' => :'UnderlineFillFormat',
160
- :'underline_line_format' => :'UnderlineLineFormat'
161
- }
152
+ :'underline_line_format' => :'UnderlineLineFormat',
153
+ })
162
154
  end
163
155
 
164
156
  # Attribute type mapping.
165
157
  def self.swagger_types
166
- {
167
- :'self_uri' => :'ResourceUri',
168
- :'alternate_links' => :'Array<ResourceUri>',
158
+ super.merge({
169
159
  :'text' => :'String',
170
160
  :'font_bold' => :'String',
171
161
  :'font_italic' => :'String',
@@ -190,27 +180,14 @@ module AsposeSlidesCloud
190
180
  :'effect_format' => :'EffectFormat',
191
181
  :'line_format' => :'LineFormat',
192
182
  :'underline_fill_format' => :'FillFormat',
193
- :'underline_line_format' => :'LineFormat'
194
- }
183
+ :'underline_line_format' => :'LineFormat',
184
+ })
195
185
  end
196
186
 
197
187
  # Initializes the object
198
188
  # @param [Hash] attributes Model attributes in the form of hash
199
189
  def initialize(attributes = {})
200
- return unless attributes.is_a?(Hash)
201
-
202
- # convert string to symbol for hash key
203
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
204
-
205
- if attributes.has_key?(:'SelfUri')
206
- self.self_uri = attributes[:'SelfUri']
207
- end
208
-
209
- if attributes.has_key?(:'AlternateLinks')
210
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
211
- self.alternate_links = value
212
- end
213
- end
190
+ super
214
191
 
215
192
  if attributes.has_key?(:'Text')
216
193
  self.text = attributes[:'Text']
@@ -316,13 +293,14 @@ module AsposeSlidesCloud
316
293
  # Show invalid properties with the reasons. Usually used together with valid?
317
294
  # @return Array for valid properties with the reasons
318
295
  def list_invalid_properties
319
- invalid_properties = Array.new
296
+ invalid_properties = super
320
297
  invalid_properties
321
298
  end
322
299
 
323
300
  # Check to see if the all the properties in the model are valid
324
301
  # @return true if the model is valid
325
302
  def valid?
303
+ return false if !super
326
304
  font_bold_validator = EnumAttributeValidator.new('String', ['False', 'True', 'NotDefined'])
327
305
  return false unless font_bold_validator.valid?(@font_bold)
328
306
  font_italic_validator = EnumAttributeValidator.new('String', ['False', 'True', 'NotDefined'])
@@ -498,15 +476,27 @@ module AsposeSlidesCloud
498
476
  def build_from_hash(attributes)
499
477
  return nil unless attributes.is_a?(Hash)
500
478
  self.class.swagger_types.each_pair do |key, type|
501
- if type =~ /\AArray<(.*)>/i
502
- # check to ensure the input is an array given that the the attribute
503
- # is documented as an array but the input is not
504
- if attributes[self.class.attribute_map[key]].is_a?(Array)
505
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
479
+ mapKey = self.class.attribute_map[key]
480
+ if !mapKey.nil?
481
+ val = attributes[mapKey]
482
+ if val.nil?
483
+ mapKeyString = mapKey.to_s
484
+ mapKeyString[0] = mapKeyString[0].downcase
485
+ mapKey = mapKeyString.to_sym
486
+ val = attributes[mapKey]
506
487
  end
507
- elsif !attributes[self.class.attribute_map[key]].nil?
508
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
509
- end # or else data not found in attributes(hash), not an issue as the data can be optional
488
+ if !val.nil?
489
+ if type =~ /\AArray<(.*)>/i
490
+ # check to ensure the input is an array given that the the attribute
491
+ # is documented as an array but the input is not
492
+ if val.is_a?(Array)
493
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
494
+ end
495
+ else
496
+ self.send("#{key}=", _deserialize(type, val))
497
+ end
498
+ end
499
+ end
510
500
  end
511
501
 
512
502
  self
@@ -24,55 +24,32 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Represents list of Links to Paragraphs resources
27
- class Portions
28
- # Gets or sets the link to this resource.
29
- attr_accessor :self_uri
30
-
31
- # List of alternate links.
32
- attr_accessor :alternate_links
33
-
27
+ class Portions < ResourceBase
34
28
  # List of portion links.
35
- attr_accessor :portion_links
29
+ attr_accessor :items
36
30
 
37
31
  # Attribute mapping from ruby-style variable name to JSON key.
38
32
  def self.attribute_map
39
- {
40
- :'self_uri' => :'SelfUri',
41
- :'alternate_links' => :'AlternateLinks',
42
- :'portion_links' => :'PortionLinks'
43
- }
33
+ super.merge({
34
+ :'items' => :'Items',
35
+ })
44
36
  end
45
37
 
46
38
  # Attribute type mapping.
47
39
  def self.swagger_types
48
- {
49
- :'self_uri' => :'ResourceUri',
50
- :'alternate_links' => :'Array<ResourceUri>',
51
- :'portion_links' => :'Array<ResourceUriElement>'
52
- }
40
+ super.merge({
41
+ :'items' => :'Array<Portion>',
42
+ })
53
43
  end
54
44
 
55
45
  # Initializes the object
56
46
  # @param [Hash] attributes Model attributes in the form of hash
57
47
  def initialize(attributes = {})
58
- return unless attributes.is_a?(Hash)
59
-
60
- # convert string to symbol for hash key
61
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
62
-
63
- if attributes.has_key?(:'SelfUri')
64
- self.self_uri = attributes[:'SelfUri']
65
- end
48
+ super
66
49
 
67
- if attributes.has_key?(:'AlternateLinks')
68
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
69
- self.alternate_links = value
70
- end
71
- end
72
-
73
- if attributes.has_key?(:'PortionLinks')
74
- if (value = attributes[:'PortionLinks']).is_a?(Array)
75
- self.portion_links = value
50
+ if attributes.has_key?(:'Items')
51
+ if (value = attributes[:'Items']).is_a?(Array)
52
+ self.items = value
76
53
  end
77
54
  end
78
55
  end
@@ -80,13 +57,14 @@ module AsposeSlidesCloud
80
57
  # Show invalid properties with the reasons. Usually used together with valid?
81
58
  # @return Array for valid properties with the reasons
82
59
  def list_invalid_properties
83
- invalid_properties = Array.new
60
+ invalid_properties = super
84
61
  invalid_properties
85
62
  end
86
63
 
87
64
  # Check to see if the all the properties in the model are valid
88
65
  # @return true if the model is valid
89
66
  def valid?
67
+ return false if !super
90
68
  true
91
69
  end
92
70
 
@@ -97,7 +75,7 @@ module AsposeSlidesCloud
97
75
  self.class == o.class &&
98
76
  self_uri == o.self_uri &&
99
77
  alternate_links == o.alternate_links &&
100
- portion_links == o.portion_links
78
+ items == o.items
101
79
  end
102
80
 
103
81
  # @see the `==` method
@@ -109,7 +87,7 @@ module AsposeSlidesCloud
109
87
  # Calculates hash code according to all attributes.
110
88
  # @return [Fixnum] Hash code
111
89
  def hash
112
- [self_uri, alternate_links, portion_links].hash
90
+ [self_uri, alternate_links, items].hash
113
91
  end
114
92
 
115
93
  # Builds the object from hash
@@ -118,15 +96,27 @@ module AsposeSlidesCloud
118
96
  def build_from_hash(attributes)
119
97
  return nil unless attributes.is_a?(Hash)
120
98
  self.class.swagger_types.each_pair do |key, type|
121
- if type =~ /\AArray<(.*)>/i
122
- # check to ensure the input is an array given that the the attribute
123
- # is documented as an array but the input is not
124
- if attributes[self.class.attribute_map[key]].is_a?(Array)
125
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
99
+ mapKey = self.class.attribute_map[key]
100
+ if !mapKey.nil?
101
+ val = attributes[mapKey]
102
+ if val.nil?
103
+ mapKeyString = mapKey.to_s
104
+ mapKeyString[0] = mapKeyString[0].downcase
105
+ mapKey = mapKeyString.to_sym
106
+ val = attributes[mapKey]
126
107
  end
127
- elsif !attributes[self.class.attribute_map[key]].nil?
128
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
129
- end # or else data not found in attributes(hash), not an issue as the data can be optional
108
+ if !val.nil?
109
+ if type =~ /\AArray<(.*)>/i
110
+ # check to ensure the input is an array given that the the attribute
111
+ # is documented as an array but the input is not
112
+ if val.is_a?(Array)
113
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
114
+ end
115
+ else
116
+ self.send("#{key}=", _deserialize(type, val))
117
+ end
118
+ end
119
+ end
130
120
  end
131
121
 
132
122
  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 PPTX format.
27
- class PptxExportOptions
28
- # Export format.
29
- attr_accessor :format
30
-
27
+ class PptxExportOptions < ExportOptions
31
28
  # The conformance class to which the PresentationML document conforms. Read/write Conformance.
32
29
  attr_accessor :conformance
33
30
 
@@ -55,43 +52,33 @@ module AsposeSlidesCloud
55
52
 
56
53
  # Attribute mapping from ruby-style variable name to JSON key.
57
54
  def self.attribute_map
58
- {
59
- :'format' => :'Format',
60
- :'conformance' => :'Conformance'
61
- }
55
+ super.merge({
56
+ :'conformance' => :'Conformance',
57
+ })
62
58
  end
63
59
 
64
60
  # Attribute type mapping.
65
61
  def self.swagger_types
66
- {
67
- :'format' => :'String',
68
- :'conformance' => :'String'
69
- }
62
+ super.merge({
63
+ :'conformance' => :'String',
64
+ })
70
65
  end
71
66
 
72
67
  # Initializes the object
73
68
  # @param [Hash] attributes Model attributes in the form of hash
74
69
  def initialize(attributes = {})
75
- return unless attributes.is_a?(Hash)
76
-
77
- # convert string to symbol for hash key
78
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
79
-
80
- if attributes.has_key?(:'Format')
81
- self.format = attributes[:'Format']
82
- else
83
- self.format = "pptx"
84
- end
70
+ super
85
71
 
86
72
  if attributes.has_key?(:'Conformance')
87
73
  self.conformance = attributes[:'Conformance']
88
74
  end
75
+ self.format = "pptx"
89
76
  end
90
77
 
91
78
  # Show invalid properties with the reasons. Usually used together with valid?
92
79
  # @return Array for valid properties with the reasons
93
80
  def list_invalid_properties
94
- invalid_properties = Array.new
81
+ invalid_properties = super
95
82
  if @conformance.nil?
96
83
  invalid_properties.push('invalid value for "conformance", conformance cannot be nil.')
97
84
  end
@@ -102,6 +89,7 @@ module AsposeSlidesCloud
102
89
  # Check to see if the all the properties in the model are valid
103
90
  # @return true if the model is valid
104
91
  def valid?
92
+ return false if !super
105
93
  return false if @conformance.nil?
106
94
  conformance_validator = EnumAttributeValidator.new('String', ['Ecma376_2006', 'Iso29500_2008_Transitional', 'Iso29500_2008_Strict'])
107
95
  return false unless conformance_validator.valid?(@conformance)
@@ -123,6 +111,7 @@ module AsposeSlidesCloud
123
111
  def ==(o)
124
112
  return true if self.equal?(o)
125
113
  self.class == o.class &&
114
+ default_regular_font == o.default_regular_font &&
126
115
  format == o.format &&
127
116
  conformance == o.conformance
128
117
  end
@@ -136,7 +125,7 @@ module AsposeSlidesCloud
136
125
  # Calculates hash code according to all attributes.
137
126
  # @return [Fixnum] Hash code
138
127
  def hash
139
- [format, conformance].hash
128
+ [default_regular_font, format, conformance].hash
140
129
  end
141
130
 
142
131
  # Builds the object from hash
@@ -145,15 +134,27 @@ module AsposeSlidesCloud
145
134
  def build_from_hash(attributes)
146
135
  return nil unless attributes.is_a?(Hash)
147
136
  self.class.swagger_types.each_pair do |key, type|
148
- if type =~ /\AArray<(.*)>/i
149
- # check to ensure the input is an array given that the the attribute
150
- # is documented as an array but the input is not
151
- if attributes[self.class.attribute_map[key]].is_a?(Array)
152
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
137
+ mapKey = self.class.attribute_map[key]
138
+ if !mapKey.nil?
139
+ val = attributes[mapKey]
140
+ if val.nil?
141
+ mapKeyString = mapKey.to_s
142
+ mapKeyString[0] = mapKeyString[0].downcase
143
+ mapKey = mapKeyString.to_sym
144
+ val = attributes[mapKey]
145
+ end
146
+ if !val.nil?
147
+ if type =~ /\AArray<(.*)>/i
148
+ # check to ensure the input is an array given that the the attribute
149
+ # is documented as an array but the input is not
150
+ if val.is_a?(Array)
151
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
152
+ end
153
+ else
154
+ self.send("#{key}=", _deserialize(type, val))
155
+ end
153
156
  end
154
- elsif !attributes[self.class.attribute_map[key]].nil?
155
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
156
- end # or else data not found in attributes(hash), not an issue as the data can be optional
157
+ end
157
158
  end
158
159
 
159
160
  self