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
@@ -56,7 +56,7 @@ module AsposeSlidesCloud
56
56
  def self.attribute_map
57
57
  {
58
58
  :'password' => :'Password',
59
- :'type' => :'Type'
59
+ :'type' => :'Type',
60
60
  }
61
61
  end
62
62
 
@@ -64,7 +64,7 @@ module AsposeSlidesCloud
64
64
  def self.swagger_types
65
65
  {
66
66
  :'password' => :'String',
67
- :'type' => :'String'
67
+ :'type' => :'String',
68
68
  }
69
69
  end
70
70
 
@@ -137,15 +137,27 @@ module AsposeSlidesCloud
137
137
  def build_from_hash(attributes)
138
138
  return nil unless attributes.is_a?(Hash)
139
139
  self.class.swagger_types.each_pair do |key, type|
140
- if type =~ /\AArray<(.*)>/i
141
- # check to ensure the input is an array given that the the attribute
142
- # is documented as an array but the input is not
143
- if attributes[self.class.attribute_map[key]].is_a?(Array)
144
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
140
+ mapKey = self.class.attribute_map[key]
141
+ if !mapKey.nil?
142
+ val = attributes[mapKey]
143
+ if val.nil?
144
+ mapKeyString = mapKey.to_s
145
+ mapKeyString[0] = mapKeyString[0].downcase
146
+ mapKey = mapKeyString.to_sym
147
+ val = attributes[mapKey]
145
148
  end
146
- elsif !attributes[self.class.attribute_map[key]].nil?
147
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
148
- end # or else data not found in attributes(hash), not an issue as the data can be optional
149
+ if !val.nil?
150
+ if type =~ /\AArray<(.*)>/i
151
+ # check to ensure the input is an array given that the the attribute
152
+ # is documented as an array but the input is not
153
+ if val.is_a?(Array)
154
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
155
+ end
156
+ else
157
+ self.send("#{key}=", _deserialize(type, val))
158
+ end
159
+ end
160
+ end
149
161
  end
150
162
 
151
163
  self
@@ -35,7 +35,7 @@ module AsposeSlidesCloud
35
35
  def self.attribute_map
36
36
  {
37
37
  :'effects' => :'Effects',
38
- :'trigger_shape_index' => :'TriggerShapeIndex'
38
+ :'trigger_shape_index' => :'TriggerShapeIndex',
39
39
  }
40
40
  end
41
41
 
@@ -43,7 +43,7 @@ module AsposeSlidesCloud
43
43
  def self.swagger_types
44
44
  {
45
45
  :'effects' => :'Array<Effect>',
46
- :'trigger_shape_index' => :'Integer'
46
+ :'trigger_shape_index' => :'Integer',
47
47
  }
48
48
  end
49
49
 
@@ -111,15 +111,27 @@ module AsposeSlidesCloud
111
111
  def build_from_hash(attributes)
112
112
  return nil unless attributes.is_a?(Hash)
113
113
  self.class.swagger_types.each_pair do |key, type|
114
- if type =~ /\AArray<(.*)>/i
115
- # check to ensure the input is an array given that the the attribute
116
- # is documented as an array but the input is not
117
- if attributes[self.class.attribute_map[key]].is_a?(Array)
118
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
114
+ mapKey = self.class.attribute_map[key]
115
+ if !mapKey.nil?
116
+ val = attributes[mapKey]
117
+ if val.nil?
118
+ mapKeyString = mapKey.to_s
119
+ mapKeyString[0] = mapKeyString[0].downcase
120
+ mapKey = mapKeyString.to_sym
121
+ val = attributes[mapKey]
119
122
  end
120
- elsif !attributes[self.class.attribute_map[key]].nil?
121
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
122
- end # or else data not found in attributes(hash), not an issue as the data can be optional
123
+ if !val.nil?
124
+ if type =~ /\AArray<(.*)>/i
125
+ # check to ensure the input is an array given that the the attribute
126
+ # is documented as an array but the input is not
127
+ if val.is_a?(Array)
128
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
129
+ end
130
+ else
131
+ self.send("#{key}=", _deserialize(type, val))
132
+ end
133
+ end
134
+ end
123
135
  end
124
136
 
125
137
  self
@@ -24,13 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Layout slide.
27
- class LayoutSlide
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 LayoutSlide < ResourceBase
34
28
  # Name.
35
29
  attr_accessor :name
36
30
 
@@ -67,45 +61,28 @@ module AsposeSlidesCloud
67
61
 
68
62
  # Attribute mapping from ruby-style variable name to JSON key.
69
63
  def self.attribute_map
70
- {
71
- :'self_uri' => :'SelfUri',
72
- :'alternate_links' => :'AlternateLinks',
64
+ super.merge({
73
65
  :'name' => :'Name',
74
66
  :'type' => :'Type',
75
67
  :'master_slide' => :'MasterSlide',
76
- :'depending_slides' => :'DependingSlides'
77
- }
68
+ :'depending_slides' => :'DependingSlides',
69
+ })
78
70
  end
79
71
 
80
72
  # Attribute type mapping.
81
73
  def self.swagger_types
82
- {
83
- :'self_uri' => :'ResourceUri',
84
- :'alternate_links' => :'Array<ResourceUri>',
74
+ super.merge({
85
75
  :'name' => :'String',
86
76
  :'type' => :'String',
87
77
  :'master_slide' => :'ResourceUriElement',
88
- :'depending_slides' => :'Array<ResourceUriElement>'
89
- }
78
+ :'depending_slides' => :'Array<ResourceUriElement>',
79
+ })
90
80
  end
91
81
 
92
82
  # Initializes the object
93
83
  # @param [Hash] attributes Model attributes in the form of hash
94
84
  def initialize(attributes = {})
95
- return unless attributes.is_a?(Hash)
96
-
97
- # convert string to symbol for hash key
98
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
99
-
100
- if attributes.has_key?(:'SelfUri')
101
- self.self_uri = attributes[:'SelfUri']
102
- end
103
-
104
- if attributes.has_key?(:'AlternateLinks')
105
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
106
- self.alternate_links = value
107
- end
108
- end
85
+ super
109
86
 
110
87
  if attributes.has_key?(:'Name')
111
88
  self.name = attributes[:'Name']
@@ -129,7 +106,7 @@ module AsposeSlidesCloud
129
106
  # Show invalid properties with the reasons. Usually used together with valid?
130
107
  # @return Array for valid properties with the reasons
131
108
  def list_invalid_properties
132
- invalid_properties = Array.new
109
+ invalid_properties = super
133
110
  if @type.nil?
134
111
  invalid_properties.push('invalid value for "type", type cannot be nil.')
135
112
  end
@@ -140,6 +117,7 @@ module AsposeSlidesCloud
140
117
  # Check to see if the all the properties in the model are valid
141
118
  # @return true if the model is valid
142
119
  def valid?
120
+ return false if !super
143
121
  return false if @type.nil?
144
122
  type_validator = EnumAttributeValidator.new('String', ['Title', 'Text', 'TwoColumnText', 'Table', 'TextAndChart', 'ChartAndText', 'Diagram', 'Chart', 'TextAndClipArt', 'ClipArtAndText', 'TitleOnly', 'Blank', 'TextAndObject', 'ObjectAndText', 'Object', 'TitleAndObject', 'TextAndMedia', 'MediaAndText', 'ObjectOverText', 'TextOverObject', 'TextAndTwoObjects', 'TwoObjectsAndText', 'TwoObjectsOverText', 'FourObjects', 'VerticalText', 'ClipArtAndVerticalText', 'VerticalTitleAndText', 'VerticalTitleAndTextOverChart', 'TwoObjects', 'ObjectAndTwoObject', 'TwoObjectsAndObject', 'SectionHeader', 'TwoTextAndTwoObjects', 'TitleObjectAndCaption', 'PictureAndCaption', 'Custom'])
145
123
  return false unless type_validator.valid?(@type)
@@ -187,15 +165,27 @@ module AsposeSlidesCloud
187
165
  def build_from_hash(attributes)
188
166
  return nil unless attributes.is_a?(Hash)
189
167
  self.class.swagger_types.each_pair do |key, type|
190
- if type =~ /\AArray<(.*)>/i
191
- # check to ensure the input is an array given that the the attribute
192
- # is documented as an array but the input is not
193
- if attributes[self.class.attribute_map[key]].is_a?(Array)
194
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
168
+ mapKey = self.class.attribute_map[key]
169
+ if !mapKey.nil?
170
+ val = attributes[mapKey]
171
+ if val.nil?
172
+ mapKeyString = mapKey.to_s
173
+ mapKeyString[0] = mapKeyString[0].downcase
174
+ mapKey = mapKeyString.to_sym
175
+ val = attributes[mapKey]
195
176
  end
196
- elsif !attributes[self.class.attribute_map[key]].nil?
197
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
198
- end # or else data not found in attributes(hash), not an issue as the data can be optional
177
+ if !val.nil?
178
+ if type =~ /\AArray<(.*)>/i
179
+ # check to ensure the input is an array given that the the attribute
180
+ # is documented as an array but the input is not
181
+ if val.is_a?(Array)
182
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
183
+ end
184
+ else
185
+ self.send("#{key}=", _deserialize(type, val))
186
+ end
187
+ end
188
+ end
199
189
  end
200
190
 
201
191
  self
@@ -24,51 +24,28 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Layout slide list.
27
- class LayoutSlides
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 LayoutSlides < ResourceBase
34
28
  # List of layout slide links.
35
29
  attr_accessor :slide_list
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
- :'slide_list' => :'SlideList'
43
- }
33
+ super.merge({
34
+ :'slide_list' => :'SlideList',
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
- :'slide_list' => :'Array<ResourceUriElement>'
52
- }
40
+ super.merge({
41
+ :'slide_list' => :'Array<ResourceUriElement>',
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?(:'SlideList')
74
51
  if (value = attributes[:'SlideList']).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
@@ -85,7 +85,7 @@ module AsposeSlidesCloud
85
85
  :'overlay' => :'Overlay',
86
86
  :'fill_format' => :'FillFormat',
87
87
  :'effect_format' => :'EffectFormat',
88
- :'line_format' => :'LineFormat'
88
+ :'line_format' => :'LineFormat',
89
89
  }
90
90
  end
91
91
 
@@ -100,7 +100,7 @@ module AsposeSlidesCloud
100
100
  :'overlay' => :'BOOLEAN',
101
101
  :'fill_format' => :'FillFormat',
102
102
  :'effect_format' => :'EffectFormat',
103
- :'line_format' => :'LineFormat'
103
+ :'line_format' => :'LineFormat',
104
104
  }
105
105
  end
106
106
 
@@ -208,15 +208,27 @@ module AsposeSlidesCloud
208
208
  def build_from_hash(attributes)
209
209
  return nil unless attributes.is_a?(Hash)
210
210
  self.class.swagger_types.each_pair do |key, type|
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 attributes[self.class.attribute_map[key]].is_a?(Array)
215
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
211
+ mapKey = self.class.attribute_map[key]
212
+ if !mapKey.nil?
213
+ val = attributes[mapKey]
214
+ if val.nil?
215
+ mapKeyString = mapKey.to_s
216
+ mapKeyString[0] = mapKeyString[0].downcase
217
+ mapKey = mapKeyString.to_sym
218
+ val = attributes[mapKey]
216
219
  end
217
- elsif !attributes[self.class.attribute_map[key]].nil?
218
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
219
- end # or else data not found in attributes(hash), not an issue as the data can be optional
220
+ if !val.nil?
221
+ if type =~ /\AArray<(.*)>/i
222
+ # check to ensure the input is an array given that the the attribute
223
+ # is documented as an array but the input is not
224
+ if val.is_a?(Array)
225
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
226
+ end
227
+ else
228
+ self.send("#{key}=", _deserialize(type, val))
229
+ end
230
+ end
231
+ end
220
232
  end
221
233
 
222
234
  self
@@ -93,7 +93,7 @@ module AsposeSlidesCloud
93
93
  :'custom_dash_pattern' => :'CustomDashPattern',
94
94
  :'fill_format' => :'FillFormat',
95
95
  :'miter_limit' => :'MiterLimit',
96
- :'width' => :'Width'
96
+ :'width' => :'Width',
97
97
  }
98
98
  end
99
99
 
@@ -110,7 +110,7 @@ module AsposeSlidesCloud
110
110
  :'custom_dash_pattern' => :'CustomDashPattern',
111
111
  :'fill_format' => :'FillFormat',
112
112
  :'miter_limit' => :'Float',
113
- :'width' => :'Float'
113
+ :'width' => :'Float',
114
114
  }
115
115
  end
116
116
 
@@ -276,15 +276,27 @@ module AsposeSlidesCloud
276
276
  def build_from_hash(attributes)
277
277
  return nil unless attributes.is_a?(Hash)
278
278
  self.class.swagger_types.each_pair do |key, type|
279
- if type =~ /\AArray<(.*)>/i
280
- # check to ensure the input is an array given that the the attribute
281
- # is documented as an array but the input is not
282
- if attributes[self.class.attribute_map[key]].is_a?(Array)
283
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
279
+ mapKey = self.class.attribute_map[key]
280
+ if !mapKey.nil?
281
+ val = attributes[mapKey]
282
+ if val.nil?
283
+ mapKeyString = mapKey.to_s
284
+ mapKeyString[0] = mapKeyString[0].downcase
285
+ mapKey = mapKeyString.to_sym
286
+ val = attributes[mapKey]
284
287
  end
285
- elsif !attributes[self.class.attribute_map[key]].nil?
286
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
287
- end # or else data not found in attributes(hash), not an issue as the data can be optional
288
+ if !val.nil?
289
+ if type =~ /\AArray<(.*)>/i
290
+ # check to ensure the input is an array given that the the attribute
291
+ # is documented as an array but the input is not
292
+ if val.is_a?(Array)
293
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
294
+ end
295
+ else
296
+ self.send("#{key}=", _deserialize(type, val))
297
+ end
298
+ end
299
+ end
288
300
  end
289
301
 
290
302
  self
@@ -24,13 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Master slide.
27
- class MasterSlide
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 MasterSlide < ResourceBase
34
28
  # Name.
35
29
  attr_accessor :name
36
30
 
@@ -42,43 +36,26 @@ module AsposeSlidesCloud
42
36
 
43
37
  # Attribute mapping from ruby-style variable name to JSON key.
44
38
  def self.attribute_map
45
- {
46
- :'self_uri' => :'SelfUri',
47
- :'alternate_links' => :'AlternateLinks',
39
+ super.merge({
48
40
  :'name' => :'Name',
49
41
  :'layout_slides' => :'LayoutSlides',
50
- :'depending_slides' => :'DependingSlides'
51
- }
42
+ :'depending_slides' => :'DependingSlides',
43
+ })
52
44
  end
53
45
 
54
46
  # Attribute type mapping.
55
47
  def self.swagger_types
56
- {
57
- :'self_uri' => :'ResourceUri',
58
- :'alternate_links' => :'Array<ResourceUri>',
48
+ super.merge({
59
49
  :'name' => :'String',
60
50
  :'layout_slides' => :'Array<ResourceUriElement>',
61
- :'depending_slides' => :'Array<ResourceUriElement>'
62
- }
51
+ :'depending_slides' => :'Array<ResourceUriElement>',
52
+ })
63
53
  end
64
54
 
65
55
  # Initializes the object
66
56
  # @param [Hash] attributes Model attributes in the form of hash
67
57
  def initialize(attributes = {})
68
- return unless attributes.is_a?(Hash)
69
-
70
- # convert string to symbol for hash key
71
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
72
-
73
- if attributes.has_key?(:'SelfUri')
74
- self.self_uri = attributes[:'SelfUri']
75
- end
76
-
77
- if attributes.has_key?(:'AlternateLinks')
78
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
79
- self.alternate_links = value
80
- end
81
- end
58
+ super
82
59
 
83
60
  if attributes.has_key?(:'Name')
84
61
  self.name = attributes[:'Name']
@@ -100,13 +77,14 @@ module AsposeSlidesCloud
100
77
  # Show invalid properties with the reasons. Usually used together with valid?
101
78
  # @return Array for valid properties with the reasons
102
79
  def list_invalid_properties
103
- invalid_properties = Array.new
80
+ invalid_properties = super
104
81
  invalid_properties
105
82
  end
106
83
 
107
84
  # Check to see if the all the properties in the model are valid
108
85
  # @return true if the model is valid
109
86
  def valid?
87
+ return false if !super
110
88
  true
111
89
  end
112
90
 
@@ -140,15 +118,27 @@ module AsposeSlidesCloud
140
118
  def build_from_hash(attributes)
141
119
  return nil unless attributes.is_a?(Hash)
142
120
  self.class.swagger_types.each_pair do |key, type|
143
- if type =~ /\AArray<(.*)>/i
144
- # check to ensure the input is an array given that the the attribute
145
- # is documented as an array but the input is not
146
- if attributes[self.class.attribute_map[key]].is_a?(Array)
147
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
121
+ mapKey = self.class.attribute_map[key]
122
+ if !mapKey.nil?
123
+ val = attributes[mapKey]
124
+ if val.nil?
125
+ mapKeyString = mapKey.to_s
126
+ mapKeyString[0] = mapKeyString[0].downcase
127
+ mapKey = mapKeyString.to_sym
128
+ val = attributes[mapKey]
148
129
  end
149
- elsif !attributes[self.class.attribute_map[key]].nil?
150
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
151
- end # or else data not found in attributes(hash), not an issue as the data can be optional
130
+ if !val.nil?
131
+ if type =~ /\AArray<(.*)>/i
132
+ # check to ensure the input is an array given that the the attribute
133
+ # is documented as an array but the input is not
134
+ if val.is_a?(Array)
135
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
136
+ end
137
+ else
138
+ self.send("#{key}=", _deserialize(type, val))
139
+ end
140
+ end
141
+ end
152
142
  end
153
143
 
154
144
  self