aspose_slides_cloud 20.4.0 → 20.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +61 -61
  3. data/TestData/ChartTest.pptx +0 -0
  4. data/TestData/Sections.pptx +0 -0
  5. data/TestData/TemplatingCVDataWithBase64.xml +22 -22
  6. data/lib/aspose_slides_cloud.rb +212 -205
  7. data/lib/aspose_slides_cloud/api/slides_api.rb +10979 -7974
  8. data/lib/aspose_slides_cloud/api/slides_api_requests.rb +4146 -3099
  9. data/lib/aspose_slides_cloud/api_client.rb +432 -429
  10. data/lib/aspose_slides_cloud/models/add_layout_slide.rb +244 -261
  11. data/lib/aspose_slides_cloud/models/add_master_slide.rb +259 -276
  12. data/lib/aspose_slides_cloud/models/add_shape.rb +239 -256
  13. data/lib/aspose_slides_cloud/models/add_slide.rb +269 -286
  14. data/lib/aspose_slides_cloud/models/api_info.rb +217 -205
  15. data/lib/aspose_slides_cloud/models/arrow_head_properties.rb +285 -273
  16. data/lib/aspose_slides_cloud/models/audio_frame.rb +359 -573
  17. data/lib/aspose_slides_cloud/models/axes.rb +237 -225
  18. data/lib/aspose_slides_cloud/models/axis.rb +699 -687
  19. data/lib/aspose_slides_cloud/models/base64_input_file.rb +230 -256
  20. data/lib/aspose_slides_cloud/models/blur_effect.rb +227 -215
  21. data/lib/aspose_slides_cloud/models/box_and_whisker_series.rb +299 -0
  22. data/lib/aspose_slides_cloud/models/bubble_chart_data_point.rb +212 -230
  23. data/lib/aspose_slides_cloud/models/bubble_series.rb +248 -428
  24. data/lib/aspose_slides_cloud/models/chart.rb +365 -553
  25. data/lib/aspose_slides_cloud/models/chart_category.rb +271 -0
  26. data/lib/aspose_slides_cloud/models/chart_title.rb +222 -210
  27. data/lib/aspose_slides_cloud/models/chart_wall.rb +281 -269
  28. data/lib/aspose_slides_cloud/models/color_scheme.rb +317 -327
  29. data/lib/aspose_slides_cloud/models/common_slide_view_properties.rb +217 -0
  30. data/lib/aspose_slides_cloud/models/connector.rb +275 -487
  31. data/lib/aspose_slides_cloud/models/custom_dash_pattern.rb +209 -197
  32. data/lib/aspose_slides_cloud/models/{resource_uri_element.rb → data_point.rb} +197 -195
  33. data/lib/aspose_slides_cloud/models/disc_usage.rb +227 -215
  34. data/lib/aspose_slides_cloud/models/document.rb +257 -267
  35. data/lib/aspose_slides_cloud/models/document_properties.rb +209 -219
  36. data/lib/aspose_slides_cloud/models/document_property.rb +232 -242
  37. data/lib/aspose_slides_cloud/models/document_replace_result.rb +218 -282
  38. data/lib/aspose_slides_cloud/models/effect.rb +424 -412
  39. data/lib/aspose_slides_cloud/models/effect_format.rb +277 -265
  40. data/lib/aspose_slides_cloud/models/entity_exists.rb +212 -0
  41. data/lib/aspose_slides_cloud/models/error.rb +237 -225
  42. data/lib/aspose_slides_cloud/models/error_details.rb +222 -210
  43. data/lib/aspose_slides_cloud/models/export_format.rb +60 -59
  44. data/lib/aspose_slides_cloud/models/export_options.rb +216 -194
  45. data/lib/aspose_slides_cloud/models/file_version.rb +225 -270
  46. data/lib/aspose_slides_cloud/models/file_versions.rb +209 -197
  47. data/lib/aspose_slides_cloud/models/files_list.rb +209 -197
  48. data/lib/aspose_slides_cloud/models/files_upload_result.rb +221 -209
  49. data/lib/aspose_slides_cloud/models/fill_format.rb +240 -228
  50. data/lib/aspose_slides_cloud/models/fill_overlay_effect.rb +246 -234
  51. data/lib/aspose_slides_cloud/models/font_scheme.rb +227 -237
  52. data/lib/aspose_slides_cloud/models/font_set.rb +227 -215
  53. data/lib/aspose_slides_cloud/models/format_scheme.rb +245 -255
  54. data/lib/aspose_slides_cloud/models/geometry_shape.rb +260 -439
  55. data/lib/aspose_slides_cloud/models/glow_effect.rb +222 -210
  56. data/lib/aspose_slides_cloud/models/gradient_fill.rb +342 -359
  57. data/lib/aspose_slides_cloud/models/gradient_fill_stop.rb +222 -210
  58. data/lib/aspose_slides_cloud/models/graphical_object.rb +234 -422
  59. data/lib/aspose_slides_cloud/models/group_shape.rb +234 -422
  60. data/lib/aspose_slides_cloud/models/header_footer.rb +247 -0
  61. data/lib/aspose_slides_cloud/models/html_export_options.rb +421 -420
  62. data/lib/aspose_slides_cloud/models/i_shape_export_options.rb +197 -195
  63. data/lib/aspose_slides_cloud/models/image.rb +237 -247
  64. data/lib/aspose_slides_cloud/models/image_export_format.rb +43 -43
  65. data/lib/aspose_slides_cloud/models/image_export_options.rb +299 -298
  66. data/lib/aspose_slides_cloud/models/images.rb +209 -219
  67. data/lib/aspose_slides_cloud/models/inner_shadow_effect.rb +252 -240
  68. data/lib/aspose_slides_cloud/models/input.rb +227 -215
  69. data/lib/aspose_slides_cloud/models/input_file.rb +250 -238
  70. data/lib/aspose_slides_cloud/models/interactive_sequence.rb +224 -212
  71. data/lib/aspose_slides_cloud/models/layout_slide.rb +278 -288
  72. data/lib/aspose_slides_cloud/models/layout_slides.rb +209 -219
  73. data/lib/aspose_slides_cloud/models/legend.rb +321 -309
  74. data/lib/aspose_slides_cloud/models/line_format.rb +389 -377
  75. data/lib/aspose_slides_cloud/models/master_slide.rb +231 -241
  76. data/lib/aspose_slides_cloud/models/master_slides.rb +209 -219
  77. data/lib/aspose_slides_cloud/models/merge.rb +231 -248
  78. data/lib/aspose_slides_cloud/models/merging_source.rb +219 -207
  79. data/lib/aspose_slides_cloud/models/no_fill.rb +219 -236
  80. data/lib/aspose_slides_cloud/models/normal_view_restored_properties.rb +217 -0
  81. data/lib/aspose_slides_cloud/models/notes_slide.rb +217 -227
  82. data/lib/aspose_slides_cloud/models/notes_slide_export_format.rb +43 -43
  83. data/lib/aspose_slides_cloud/models/notes_slide_header_footer.rb +267 -0
  84. data/lib/aspose_slides_cloud/models/object_exist.rb +227 -215
  85. data/lib/aspose_slides_cloud/models/ole_object_frame.rb +259 -447
  86. data/lib/aspose_slides_cloud/models/one_value_chart_data_point.rb +210 -200
  87. data/lib/aspose_slides_cloud/models/one_value_series.rb +248 -428
  88. data/lib/aspose_slides_cloud/models/ordered_merge_request.rb +209 -197
  89. data/lib/aspose_slides_cloud/models/outer_shadow_effect.rb +252 -240
  90. data/lib/aspose_slides_cloud/models/output_file.rb +240 -228
  91. data/lib/aspose_slides_cloud/models/paragraph.rb +517 -527
  92. data/lib/aspose_slides_cloud/models/paragraphs.rb +209 -219
  93. data/lib/aspose_slides_cloud/models/path_input_file.rb +240 -266
  94. data/lib/aspose_slides_cloud/models/path_output_file.rb +239 -256
  95. data/lib/aspose_slides_cloud/models/pattern_fill.rb +266 -283
  96. data/lib/aspose_slides_cloud/models/pdf_export_options.rb +547 -519
  97. data/lib/aspose_slides_cloud/models/picture_fill.rb +351 -368
  98. data/lib/aspose_slides_cloud/models/picture_frame.rb +245 -459
  99. data/lib/aspose_slides_cloud/models/pipeline.rb +219 -207
  100. data/lib/aspose_slides_cloud/models/placeholder.rb +325 -335
  101. data/lib/aspose_slides_cloud/models/placeholders.rb +209 -219
  102. data/lib/aspose_slides_cloud/models/plot_area.rb +311 -299
  103. data/lib/aspose_slides_cloud/models/portion.rb +589 -599
  104. data/lib/aspose_slides_cloud/models/portions.rb +209 -219
  105. data/lib/aspose_slides_cloud/models/pptx_export_options.rb +247 -246
  106. data/lib/aspose_slides_cloud/models/presentation_to_merge.rb +229 -217
  107. data/lib/aspose_slides_cloud/models/presentations_merge_request.rb +221 -209
  108. data/lib/aspose_slides_cloud/models/preset_shadow_effect.rb +286 -274
  109. data/lib/aspose_slides_cloud/models/reflection_effect.rb +441 -429
  110. data/lib/aspose_slides_cloud/models/remove_shape.rb +229 -246
  111. data/lib/aspose_slides_cloud/models/remove_slide.rb +234 -251
  112. data/lib/aspose_slides_cloud/models/reorder_slide.rb +249 -266
  113. data/lib/aspose_slides_cloud/models/replace_text.rb +269 -286
  114. data/lib/aspose_slides_cloud/models/request_input_file.rb +235 -261
  115. data/lib/aspose_slides_cloud/models/reset_slide.rb +234 -251
  116. data/lib/aspose_slides_cloud/models/resource_base.rb +219 -207
  117. data/lib/aspose_slides_cloud/models/resource_uri.rb +237 -225
  118. data/lib/aspose_slides_cloud/models/response_output_file.rb +219 -236
  119. data/lib/aspose_slides_cloud/models/save.rb +266 -283
  120. data/lib/aspose_slides_cloud/models/save_shape.rb +276 -293
  121. data/lib/aspose_slides_cloud/models/save_slide.rb +301 -318
  122. data/lib/aspose_slides_cloud/models/scale_type.rb +41 -41
  123. data/lib/aspose_slides_cloud/models/scatter_chart_data_point.rb +225 -215
  124. data/lib/aspose_slides_cloud/models/scatter_series.rb +248 -428
  125. data/lib/aspose_slides_cloud/models/section.rb +234 -0
  126. data/lib/aspose_slides_cloud/models/sections.rb +209 -0
  127. data/lib/aspose_slides_cloud/models/series.rb +422 -389
  128. data/lib/aspose_slides_cloud/models/series_marker.rb +281 -269
  129. data/lib/aspose_slides_cloud/models/shape.rb +255 -467
  130. data/lib/aspose_slides_cloud/models/shape_base.rb +375 -406
  131. data/lib/aspose_slides_cloud/models/shape_export_format.rb +44 -44
  132. data/lib/aspose_slides_cloud/models/shape_image_export_options.rb +286 -274
  133. data/lib/aspose_slides_cloud/models/shape_thumbnail_bounds.rb +41 -41
  134. data/lib/aspose_slides_cloud/models/shapes.rb +209 -219
  135. data/lib/aspose_slides_cloud/models/size_type.rb +55 -55
  136. data/lib/aspose_slides_cloud/models/slide.rb +322 -332
  137. data/lib/aspose_slides_cloud/models/slide_animation.rb +221 -231
  138. data/lib/aspose_slides_cloud/models/slide_background.rb +266 -276
  139. data/lib/aspose_slides_cloud/models/slide_comment.rb +239 -227
  140. data/lib/aspose_slides_cloud/models/slide_comments.rb +209 -219
  141. data/lib/aspose_slides_cloud/models/slide_export_format.rb +59 -58
  142. data/lib/aspose_slides_cloud/models/slide_replace_result.rb +223 -347
  143. data/lib/aspose_slides_cloud/models/slides.rb +209 -219
  144. data/lib/aspose_slides_cloud/models/smart_art.rb +342 -530
  145. data/lib/aspose_slides_cloud/models/smart_art_node.rb +293 -281
  146. data/lib/aspose_slides_cloud/models/smart_art_shape.rb +235 -422
  147. data/lib/aspose_slides_cloud/models/soft_edge_effect.rb +212 -200
  148. data/lib/aspose_slides_cloud/models/solid_fill.rb +229 -246
  149. data/lib/aspose_slides_cloud/models/split_document_result.rb +209 -219
  150. data/lib/aspose_slides_cloud/models/storage_exist.rb +212 -200
  151. data/lib/aspose_slides_cloud/models/storage_file.rb +257 -245
  152. data/lib/aspose_slides_cloud/models/svg_export_options.rb +379 -378
  153. data/lib/aspose_slides_cloud/models/swf_export_options.rb +529 -528
  154. data/lib/aspose_slides_cloud/models/table.rb +350 -538
  155. data/lib/aspose_slides_cloud/models/table_cell.rb +403 -391
  156. data/lib/aspose_slides_cloud/models/table_column.rb +212 -200
  157. data/lib/aspose_slides_cloud/models/table_row.rb +239 -227
  158. data/lib/aspose_slides_cloud/models/task.rb +240 -228
  159. data/lib/aspose_slides_cloud/models/text_item.rb +217 -205
  160. data/lib/aspose_slides_cloud/models/text_items.rb +209 -219
  161. data/lib/aspose_slides_cloud/models/theme.rb +237 -247
  162. data/lib/aspose_slides_cloud/models/tiff_export_options.rb +423 -422
  163. data/lib/aspose_slides_cloud/models/update_background.rb +241 -258
  164. data/lib/aspose_slides_cloud/models/update_shape.rb +239 -256
  165. data/lib/aspose_slides_cloud/models/video_frame.rb +329 -543
  166. data/lib/aspose_slides_cloud/models/view_properties.rb +357 -0
  167. data/lib/aspose_slides_cloud/models/waterfall_chart_data_point.rb +206 -0
  168. data/lib/aspose_slides_cloud/models/waterfall_series.rb +247 -0
  169. data/lib/aspose_slides_cloud/models/xps_export_options.rb +243 -242
  170. data/lib/aspose_slides_cloud/type_registry.rb +320 -0
  171. data/lib/aspose_slides_cloud/version.rb +25 -25
  172. data/spec/api/slides_api_spec.rb +35926 -24406
  173. data/spec/extra/extra_spec.rb +235 -101
  174. data/spec/spec_utils.rb +183 -176
  175. data/testConfig.json +7 -7
  176. data/testRules.json +472 -340
  177. metadata +18 -3
@@ -1,573 +1,359 @@
1
- =begin
2
- Copyright (c) 2019 Aspose Pty Ltd
3
-
4
- Permission is hereby granted, free of charge, to any person obtaining a copy
5
- of this software and associated documentation files (the "Software"), to deal
6
- in the Software without restriction, including without limitation the rights
7
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
- copies of the Software, and to permit persons to whom the Software is
9
- furnished to do so, subject to the following conditions:
10
-
11
- The above copyright notice and this permission notice shall be included in all
12
- copies or substantial portions of the Software.
13
-
14
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20
- SOFTWARE.
21
- =end
22
-
23
- require 'date'
24
-
25
- module AsposeSlidesCloud
26
- # Represents AudioFrame resource.
27
- class AudioFrame
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
-
34
- # Gets or sets the name.
35
- attr_accessor :name
36
-
37
- # Gets or sets the width.
38
- attr_accessor :width
39
-
40
- # Gets or sets the height.
41
- attr_accessor :height
42
-
43
- # Gets or sets the alternative text.
44
- attr_accessor :alternative_text
45
-
46
- # The title of alternative text associated with the shape.
47
- attr_accessor :alternative_text_title
48
-
49
- # Gets or sets a value indicating whether this ShapeBase is hidden.
50
- attr_accessor :hidden
51
-
52
- # Gets or sets the X
53
- attr_accessor :x
54
-
55
- # Gets or sets the Y.
56
- attr_accessor :y
57
-
58
- # Gets z-order position of shape
59
- attr_accessor :z_order_position
60
-
61
- # Gets or sets the link to shapes.
62
- attr_accessor :shapes
63
-
64
- # Gets or sets the fill format.
65
- attr_accessor :fill_format
66
-
67
- # Gets or sets the effect format.
68
- attr_accessor :effect_format
69
-
70
- # Gets or sets the line format.
71
- attr_accessor :line_format
72
-
73
- # Shape type.
74
- attr_accessor :type
75
-
76
- # Combined shape type.
77
- attr_accessor :shape_type
78
-
79
- # Geometry shape type.
80
- attr_accessor :geometry_shape_type
81
-
82
- # Returns or sets a last track index.
83
- attr_accessor :audio_cd_end_track
84
-
85
- # Returns or sets a last track time.
86
- attr_accessor :audio_cd_end_track_time
87
-
88
- # Returns or sets a start track index.
89
- attr_accessor :audio_cd_start_track
90
-
91
- # Returns or sets a start track time.
92
- attr_accessor :audio_cd_start_track_time
93
-
94
- # Determines whether a sound is embedded to a presentation.
95
- attr_accessor :embedded
96
-
97
- # Determines whether an AudioFrame is hidden.
98
- attr_accessor :hide_at_showing
99
-
100
- # Determines whether an audio is looped.
101
- attr_accessor :play_loop_mode
102
-
103
- # Returns or sets the audio play mode.
104
- attr_accessor :play_mode
105
-
106
- # Returns or sets the audio volume.
107
- attr_accessor :volume
108
-
109
- # Audio data encoded in base64.
110
- attr_accessor :base64_data
111
-
112
- class EnumAttributeValidator
113
- attr_reader :datatype
114
- attr_reader :allowable_values
115
-
116
- def initialize(datatype, allowable_values)
117
- @allowable_values = allowable_values.map do |value|
118
- case datatype.to_s
119
- when /Integer/i
120
- value.to_i
121
- when /Float/i
122
- value.to_f
123
- else
124
- value
125
- end
126
- end
127
- end
128
-
129
- def valid?(value)
130
- !value || allowable_values.any?{ |s| s.casecmp(value) == 0 }
131
- end
132
- end
133
-
134
- # Attribute mapping from ruby-style variable name to JSON key.
135
- def self.attribute_map
136
- {
137
- :'self_uri' => :'SelfUri',
138
- :'alternate_links' => :'AlternateLinks',
139
- :'name' => :'Name',
140
- :'width' => :'Width',
141
- :'height' => :'Height',
142
- :'alternative_text' => :'AlternativeText',
143
- :'alternative_text_title' => :'AlternativeTextTitle',
144
- :'hidden' => :'Hidden',
145
- :'x' => :'X',
146
- :'y' => :'Y',
147
- :'z_order_position' => :'ZOrderPosition',
148
- :'shapes' => :'Shapes',
149
- :'fill_format' => :'FillFormat',
150
- :'effect_format' => :'EffectFormat',
151
- :'line_format' => :'LineFormat',
152
- :'type' => :'Type',
153
- :'shape_type' => :'ShapeType',
154
- :'geometry_shape_type' => :'GeometryShapeType',
155
- :'audio_cd_end_track' => :'AudioCdEndTrack',
156
- :'audio_cd_end_track_time' => :'AudioCdEndTrackTime',
157
- :'audio_cd_start_track' => :'AudioCdStartTrack',
158
- :'audio_cd_start_track_time' => :'AudioCdStartTrackTime',
159
- :'embedded' => :'Embedded',
160
- :'hide_at_showing' => :'HideAtShowing',
161
- :'play_loop_mode' => :'PlayLoopMode',
162
- :'play_mode' => :'PlayMode',
163
- :'volume' => :'Volume',
164
- :'base64_data' => :'Base64Data'
165
- }
166
- end
167
-
168
- # Attribute type mapping.
169
- def self.swagger_types
170
- {
171
- :'self_uri' => :'ResourceUri',
172
- :'alternate_links' => :'Array<ResourceUri>',
173
- :'name' => :'String',
174
- :'width' => :'Float',
175
- :'height' => :'Float',
176
- :'alternative_text' => :'String',
177
- :'alternative_text_title' => :'String',
178
- :'hidden' => :'BOOLEAN',
179
- :'x' => :'Float',
180
- :'y' => :'Float',
181
- :'z_order_position' => :'Integer',
182
- :'shapes' => :'ResourceUriElement',
183
- :'fill_format' => :'FillFormat',
184
- :'effect_format' => :'EffectFormat',
185
- :'line_format' => :'LineFormat',
186
- :'type' => :'String',
187
- :'shape_type' => :'String',
188
- :'geometry_shape_type' => :'String',
189
- :'audio_cd_end_track' => :'Integer',
190
- :'audio_cd_end_track_time' => :'Integer',
191
- :'audio_cd_start_track' => :'Integer',
192
- :'audio_cd_start_track_time' => :'Integer',
193
- :'embedded' => :'BOOLEAN',
194
- :'hide_at_showing' => :'BOOLEAN',
195
- :'play_loop_mode' => :'BOOLEAN',
196
- :'play_mode' => :'String',
197
- :'volume' => :'String',
198
- :'base64_data' => :'String'
199
- }
200
- end
201
-
202
- # Initializes the object
203
- # @param [Hash] attributes Model attributes in the form of hash
204
- def initialize(attributes = {})
205
- return unless attributes.is_a?(Hash)
206
-
207
- # convert string to symbol for hash key
208
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
209
-
210
- if attributes.has_key?(:'SelfUri')
211
- self.self_uri = attributes[:'SelfUri']
212
- end
213
-
214
- if attributes.has_key?(:'AlternateLinks')
215
- if (value = attributes[:'AlternateLinks']).is_a?(Array)
216
- self.alternate_links = value
217
- end
218
- end
219
-
220
- if attributes.has_key?(:'Name')
221
- self.name = attributes[:'Name']
222
- end
223
-
224
- if attributes.has_key?(:'Width')
225
- self.width = attributes[:'Width']
226
- end
227
-
228
- if attributes.has_key?(:'Height')
229
- self.height = attributes[:'Height']
230
- end
231
-
232
- if attributes.has_key?(:'AlternativeText')
233
- self.alternative_text = attributes[:'AlternativeText']
234
- end
235
-
236
- if attributes.has_key?(:'AlternativeTextTitle')
237
- self.alternative_text_title = attributes[:'AlternativeTextTitle']
238
- end
239
-
240
- if attributes.has_key?(:'Hidden')
241
- self.hidden = attributes[:'Hidden']
242
- end
243
-
244
- if attributes.has_key?(:'X')
245
- self.x = attributes[:'X']
246
- end
247
-
248
- if attributes.has_key?(:'Y')
249
- self.y = attributes[:'Y']
250
- end
251
-
252
- if attributes.has_key?(:'ZOrderPosition')
253
- self.z_order_position = attributes[:'ZOrderPosition']
254
- end
255
-
256
- if attributes.has_key?(:'Shapes')
257
- self.shapes = attributes[:'Shapes']
258
- end
259
-
260
- if attributes.has_key?(:'FillFormat')
261
- self.fill_format = attributes[:'FillFormat']
262
- end
263
-
264
- if attributes.has_key?(:'EffectFormat')
265
- self.effect_format = attributes[:'EffectFormat']
266
- end
267
-
268
- if attributes.has_key?(:'LineFormat')
269
- self.line_format = attributes[:'LineFormat']
270
- end
271
-
272
- if attributes.has_key?(:'Type')
273
- self.type = attributes[:'Type']
274
- else
275
- self.type = "AudioFrame"
276
- end
277
-
278
- if attributes.has_key?(:'ShapeType')
279
- self.shape_type = attributes[:'ShapeType']
280
- else
281
- self.shape_type = "AudioFrame"
282
- end
283
-
284
- if attributes.has_key?(:'GeometryShapeType')
285
- self.geometry_shape_type = attributes[:'GeometryShapeType']
286
- end
287
-
288
- if attributes.has_key?(:'AudioCdEndTrack')
289
- self.audio_cd_end_track = attributes[:'AudioCdEndTrack']
290
- end
291
-
292
- if attributes.has_key?(:'AudioCdEndTrackTime')
293
- self.audio_cd_end_track_time = attributes[:'AudioCdEndTrackTime']
294
- end
295
-
296
- if attributes.has_key?(:'AudioCdStartTrack')
297
- self.audio_cd_start_track = attributes[:'AudioCdStartTrack']
298
- end
299
-
300
- if attributes.has_key?(:'AudioCdStartTrackTime')
301
- self.audio_cd_start_track_time = attributes[:'AudioCdStartTrackTime']
302
- end
303
-
304
- if attributes.has_key?(:'Embedded')
305
- self.embedded = attributes[:'Embedded']
306
- end
307
-
308
- if attributes.has_key?(:'HideAtShowing')
309
- self.hide_at_showing = attributes[:'HideAtShowing']
310
- end
311
-
312
- if attributes.has_key?(:'PlayLoopMode')
313
- self.play_loop_mode = attributes[:'PlayLoopMode']
314
- end
315
-
316
- if attributes.has_key?(:'PlayMode')
317
- self.play_mode = attributes[:'PlayMode']
318
- end
319
-
320
- if attributes.has_key?(:'Volume')
321
- self.volume = attributes[:'Volume']
322
- end
323
-
324
- if attributes.has_key?(:'Base64Data')
325
- self.base64_data = attributes[:'Base64Data']
326
- end
327
- end
328
-
329
- # Show invalid properties with the reasons. Usually used together with valid?
330
- # @return Array for valid properties with the reasons
331
- def list_invalid_properties
332
- invalid_properties = Array.new
333
- if @z_order_position.nil?
334
- invalid_properties.push('invalid value for "z_order_position", z_order_position cannot be nil.')
335
- end
336
-
337
- if @type.nil?
338
- invalid_properties.push('invalid value for "type", type cannot be nil.')
339
- end
340
-
341
- if @shape_type.nil?
342
- invalid_properties.push('invalid value for "shape_type", shape_type cannot be nil.')
343
- end
344
-
345
- if @geometry_shape_type.nil?
346
- invalid_properties.push('invalid value for "geometry_shape_type", geometry_shape_type cannot be nil.')
347
- end
348
-
349
- invalid_properties
350
- end
351
-
352
- # Check to see if the all the properties in the model are valid
353
- # @return true if the model is valid
354
- def valid?
355
- return false if @z_order_position.nil?
356
- return false if @type.nil?
357
- type_validator = EnumAttributeValidator.new('String', ['Shape', 'Chart', 'Table', 'PictureFrame', 'VideoFrame', 'AudioFrame', 'SmartArt', 'OleObjectFrame', 'GroupShape', 'GraphicalObject', 'Connector', 'SmartArtShape'])
358
- return false unless type_validator.valid?(@type)
359
- return false if @shape_type.nil?
360
- shape_type_validator = EnumAttributeValidator.new('String', ['Custom', 'Line', 'LineInverse', 'Triangle', 'RightTriangle', 'Rectangle', 'Diamond', 'Parallelogram', 'Trapezoid', 'NonIsoscelesTrapezoid', 'Pentagon', 'Hexagon', 'Heptagon', 'Octagon', 'Decagon', 'Dodecagon', 'FourPointedStar', 'FivePointedStar', 'SixPointedStar', 'SevenPointedStar', 'EightPointedStar', 'TenPointedStar', 'TwelvePointedStar', 'SixteenPointedStar', 'TwentyFourPointedStar', 'ThirtyTwoPointedStar', 'RoundCornerRectangle', 'OneRoundCornerRectangle', 'TwoSamesideRoundCornerRectangle', 'TwoDiagonalRoundCornerRectangle', 'OneSnipOneRoundCornerRectangle', 'OneSnipCornerRectangle', 'TwoSamesideSnipCornerRectangle', 'TwoDiagonalSnipCornerRectangle', 'Plaque', 'Ellipse', 'Teardrop', 'HomePlate', 'Chevron', 'PieWedge', 'Pie', 'BlockArc', 'Donut', 'NoSmoking', 'RightArrow', 'LeftArrow', 'UpArrow', 'DownArrow', 'StripedRightArrow', 'NotchedRightArrow', 'BentUpArrow', 'LeftRightArrow', 'UpDownArrow', 'LeftUpArrow', 'LeftRightUpArrow', 'QuadArrow', 'CalloutLeftArrow', 'CalloutRightArrow', 'CalloutUpArrow', 'CalloutDownArrow', 'CalloutLeftRightArrow', 'CalloutUpDownArrow', 'CalloutQuadArrow', 'BentArrow', 'UTurnArrow', 'CircularArrow', 'LeftCircularArrow', 'LeftRightCircularArrow', 'CurvedRightArrow', 'CurvedLeftArrow', 'CurvedUpArrow', 'CurvedDownArrow', 'SwooshArrow', 'Cube', 'Can', 'LightningBolt', 'Heart', 'Sun', 'Moon', 'SmileyFace', 'IrregularSeal1', 'IrregularSeal2', 'FoldedCorner', 'Bevel', 'Frame', 'HalfFrame', 'Corner', 'DiagonalStripe', 'Chord', 'CurvedArc', 'LeftBracket', 'RightBracket', 'LeftBrace', 'RightBrace', 'BracketPair', 'BracePair', 'StraightConnector1', 'BentConnector2', 'BentConnector3', 'BentConnector4', 'BentConnector5', 'CurvedConnector2', 'CurvedConnector3', 'CurvedConnector4', 'CurvedConnector5', 'Callout1', 'Callout2', 'Callout3', 'Callout1WithAccent', 'Callout2WithAccent', 'Callout3WithAccent', 'Callout1WithBorder', 'Callout2WithBorder', 'Callout3WithBorder', 'Callout1WithBorderAndAccent', 'Callout2WithBorderAndAccent', 'Callout3WithBorderAndAccent', 'CalloutWedgeRectangle', 'CalloutWedgeRoundRectangle', 'CalloutWedgeEllipse', 'CalloutCloud', 'Cloud', 'Ribbon', 'Ribbon2', 'EllipseRibbon', 'EllipseRibbon2', 'LeftRightRibbon', 'VerticalScroll', 'HorizontalScroll', 'Wave', 'DoubleWave', 'Plus', 'ProcessFlow', 'DecisionFlow', 'InputOutputFlow', 'PredefinedProcessFlow', 'InternalStorageFlow', 'DocumentFlow', 'MultiDocumentFlow', 'TerminatorFlow', 'PreparationFlow', 'ManualInputFlow', 'ManualOperationFlow', 'ConnectorFlow', 'PunchedCardFlow', 'PunchedTapeFlow', 'SummingJunctionFlow', 'OrFlow', 'CollateFlow', 'SortFlow', 'ExtractFlow', 'MergeFlow', 'OfflineStorageFlow', 'OnlineStorageFlow', 'MagneticTapeFlow', 'MagneticDiskFlow', 'MagneticDrumFlow', 'DisplayFlow', 'DelayFlow', 'AlternateProcessFlow', 'OffPageConnectorFlow', 'BlankButton', 'HomeButton', 'HelpButton', 'InformationButton', 'ForwardOrNextButton', 'BackOrPreviousButton', 'EndButton', 'BeginningButton', 'ReturnButton', 'DocumentButton', 'SoundButton', 'MovieButton', 'Gear6', 'Gear9', 'Funnel', 'PlusMath', 'MinusMath', 'MultiplyMath', 'DivideMath', 'EqualMath', 'NotEqualMath', 'CornerTabs', 'SquareTabs', 'PlaqueTabs', 'ChartX', 'ChartStar', 'ChartPlus', 'Chart', 'Table', 'PictureFrame', 'VideoFrame', 'AudioFrame', 'Diagram', 'OleObjectFrame', 'GroupShape', 'GraphicalObject', 'NotDefined'])
361
- return false unless shape_type_validator.valid?(@shape_type)
362
- return false if @geometry_shape_type.nil?
363
- geometry_shape_type_validator = EnumAttributeValidator.new('String', ['Custom', 'Line', 'LineInverse', 'Triangle', 'RightTriangle', 'Rectangle', 'Diamond', 'Parallelogram', 'Trapezoid', 'NonIsoscelesTrapezoid', 'Pentagon', 'Hexagon', 'Heptagon', 'Octagon', 'Decagon', 'Dodecagon', 'FourPointedStar', 'FivePointedStar', 'SixPointedStar', 'SevenPointedStar', 'EightPointedStar', 'TenPointedStar', 'TwelvePointedStar', 'SixteenPointedStar', 'TwentyFourPointedStar', 'ThirtyTwoPointedStar', 'RoundCornerRectangle', 'OneRoundCornerRectangle', 'TwoSamesideRoundCornerRectangle', 'TwoDiagonalRoundCornerRectangle', 'OneSnipOneRoundCornerRectangle', 'OneSnipCornerRectangle', 'TwoSamesideSnipCornerRectangle', 'TwoDiagonalSnipCornerRectangle', 'Plaque', 'Ellipse', 'Teardrop', 'HomePlate', 'Chevron', 'PieWedge', 'Pie', 'BlockArc', 'Donut', 'NoSmoking', 'RightArrow', 'LeftArrow', 'UpArrow', 'DownArrow', 'StripedRightArrow', 'NotchedRightArrow', 'BentUpArrow', 'LeftRightArrow', 'UpDownArrow', 'LeftUpArrow', 'LeftRightUpArrow', 'QuadArrow', 'CalloutLeftArrow', 'CalloutRightArrow', 'CalloutUpArrow', 'CalloutDownArrow', 'CalloutLeftRightArrow', 'CalloutUpDownArrow', 'CalloutQuadArrow', 'BentArrow', 'UTurnArrow', 'CircularArrow', 'LeftCircularArrow', 'LeftRightCircularArrow', 'CurvedRightArrow', 'CurvedLeftArrow', 'CurvedUpArrow', 'CurvedDownArrow', 'SwooshArrow', 'Cube', 'Can', 'LightningBolt', 'Heart', 'Sun', 'Moon', 'SmileyFace', 'IrregularSeal1', 'IrregularSeal2', 'FoldedCorner', 'Bevel', 'Frame', 'HalfFrame', 'Corner', 'DiagonalStripe', 'Chord', 'CurvedArc', 'LeftBracket', 'RightBracket', 'LeftBrace', 'RightBrace', 'BracketPair', 'BracePair', 'StraightConnector1', 'BentConnector2', 'BentConnector3', 'BentConnector4', 'BentConnector5', 'CurvedConnector2', 'CurvedConnector3', 'CurvedConnector4', 'CurvedConnector5', 'Callout1', 'Callout2', 'Callout3', 'Callout1WithAccent', 'Callout2WithAccent', 'Callout3WithAccent', 'Callout1WithBorder', 'Callout2WithBorder', 'Callout3WithBorder', 'Callout1WithBorderAndAccent', 'Callout2WithBorderAndAccent', 'Callout3WithBorderAndAccent', 'CalloutWedgeRectangle', 'CalloutWedgeRoundRectangle', 'CalloutWedgeEllipse', 'CalloutCloud', 'Cloud', 'Ribbon', 'Ribbon2', 'EllipseRibbon', 'EllipseRibbon2', 'LeftRightRibbon', 'VerticalScroll', 'HorizontalScroll', 'Wave', 'DoubleWave', 'Plus', 'ProcessFlow', 'DecisionFlow', 'InputOutputFlow', 'PredefinedProcessFlow', 'InternalStorageFlow', 'DocumentFlow', 'MultiDocumentFlow', 'TerminatorFlow', 'PreparationFlow', 'ManualInputFlow', 'ManualOperationFlow', 'ConnectorFlow', 'PunchedCardFlow', 'PunchedTapeFlow', 'SummingJunctionFlow', 'OrFlow', 'CollateFlow', 'SortFlow', 'ExtractFlow', 'MergeFlow', 'OfflineStorageFlow', 'OnlineStorageFlow', 'MagneticTapeFlow', 'MagneticDiskFlow', 'MagneticDrumFlow', 'DisplayFlow', 'DelayFlow', 'AlternateProcessFlow', 'OffPageConnectorFlow', 'BlankButton', 'HomeButton', 'HelpButton', 'InformationButton', 'ForwardOrNextButton', 'BackOrPreviousButton', 'EndButton', 'BeginningButton', 'ReturnButton', 'DocumentButton', 'SoundButton', 'MovieButton', 'Gear6', 'Gear9', 'Funnel', 'PlusMath', 'MinusMath', 'MultiplyMath', 'DivideMath', 'EqualMath', 'NotEqualMath', 'CornerTabs', 'SquareTabs', 'PlaqueTabs', 'ChartX', 'ChartStar', 'ChartPlus', 'NotDefined'])
364
- return false unless geometry_shape_type_validator.valid?(@geometry_shape_type)
365
- play_mode_validator = EnumAttributeValidator.new('String', ['Auto', 'OnClick', 'AllSlides', 'Mixed'])
366
- return false unless play_mode_validator.valid?(@play_mode)
367
- volume_validator = EnumAttributeValidator.new('String', ['Mute', 'Low', 'Medium', 'Loud', 'Mixed'])
368
- return false unless volume_validator.valid?(@volume)
369
- true
370
- end
371
-
372
- # Custom attribute writer method checking allowed values (enum).
373
- # @param [Object] type Object to be assigned
374
- def type=(type)
375
- validator = EnumAttributeValidator.new('String', ['Shape', 'Chart', 'Table', 'PictureFrame', 'VideoFrame', 'AudioFrame', 'SmartArt', 'OleObjectFrame', 'GroupShape', 'GraphicalObject', 'Connector', 'SmartArtShape'])
376
- unless validator.valid?(type)
377
- fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
378
- end
379
- @type = type
380
- end
381
-
382
- # Custom attribute writer method checking allowed values (enum).
383
- # @param [Object] shape_type Object to be assigned
384
- def shape_type=(shape_type)
385
- validator = EnumAttributeValidator.new('String', ['Custom', 'Line', 'LineInverse', 'Triangle', 'RightTriangle', 'Rectangle', 'Diamond', 'Parallelogram', 'Trapezoid', 'NonIsoscelesTrapezoid', 'Pentagon', 'Hexagon', 'Heptagon', 'Octagon', 'Decagon', 'Dodecagon', 'FourPointedStar', 'FivePointedStar', 'SixPointedStar', 'SevenPointedStar', 'EightPointedStar', 'TenPointedStar', 'TwelvePointedStar', 'SixteenPointedStar', 'TwentyFourPointedStar', 'ThirtyTwoPointedStar', 'RoundCornerRectangle', 'OneRoundCornerRectangle', 'TwoSamesideRoundCornerRectangle', 'TwoDiagonalRoundCornerRectangle', 'OneSnipOneRoundCornerRectangle', 'OneSnipCornerRectangle', 'TwoSamesideSnipCornerRectangle', 'TwoDiagonalSnipCornerRectangle', 'Plaque', 'Ellipse', 'Teardrop', 'HomePlate', 'Chevron', 'PieWedge', 'Pie', 'BlockArc', 'Donut', 'NoSmoking', 'RightArrow', 'LeftArrow', 'UpArrow', 'DownArrow', 'StripedRightArrow', 'NotchedRightArrow', 'BentUpArrow', 'LeftRightArrow', 'UpDownArrow', 'LeftUpArrow', 'LeftRightUpArrow', 'QuadArrow', 'CalloutLeftArrow', 'CalloutRightArrow', 'CalloutUpArrow', 'CalloutDownArrow', 'CalloutLeftRightArrow', 'CalloutUpDownArrow', 'CalloutQuadArrow', 'BentArrow', 'UTurnArrow', 'CircularArrow', 'LeftCircularArrow', 'LeftRightCircularArrow', 'CurvedRightArrow', 'CurvedLeftArrow', 'CurvedUpArrow', 'CurvedDownArrow', 'SwooshArrow', 'Cube', 'Can', 'LightningBolt', 'Heart', 'Sun', 'Moon', 'SmileyFace', 'IrregularSeal1', 'IrregularSeal2', 'FoldedCorner', 'Bevel', 'Frame', 'HalfFrame', 'Corner', 'DiagonalStripe', 'Chord', 'CurvedArc', 'LeftBracket', 'RightBracket', 'LeftBrace', 'RightBrace', 'BracketPair', 'BracePair', 'StraightConnector1', 'BentConnector2', 'BentConnector3', 'BentConnector4', 'BentConnector5', 'CurvedConnector2', 'CurvedConnector3', 'CurvedConnector4', 'CurvedConnector5', 'Callout1', 'Callout2', 'Callout3', 'Callout1WithAccent', 'Callout2WithAccent', 'Callout3WithAccent', 'Callout1WithBorder', 'Callout2WithBorder', 'Callout3WithBorder', 'Callout1WithBorderAndAccent', 'Callout2WithBorderAndAccent', 'Callout3WithBorderAndAccent', 'CalloutWedgeRectangle', 'CalloutWedgeRoundRectangle', 'CalloutWedgeEllipse', 'CalloutCloud', 'Cloud', 'Ribbon', 'Ribbon2', 'EllipseRibbon', 'EllipseRibbon2', 'LeftRightRibbon', 'VerticalScroll', 'HorizontalScroll', 'Wave', 'DoubleWave', 'Plus', 'ProcessFlow', 'DecisionFlow', 'InputOutputFlow', 'PredefinedProcessFlow', 'InternalStorageFlow', 'DocumentFlow', 'MultiDocumentFlow', 'TerminatorFlow', 'PreparationFlow', 'ManualInputFlow', 'ManualOperationFlow', 'ConnectorFlow', 'PunchedCardFlow', 'PunchedTapeFlow', 'SummingJunctionFlow', 'OrFlow', 'CollateFlow', 'SortFlow', 'ExtractFlow', 'MergeFlow', 'OfflineStorageFlow', 'OnlineStorageFlow', 'MagneticTapeFlow', 'MagneticDiskFlow', 'MagneticDrumFlow', 'DisplayFlow', 'DelayFlow', 'AlternateProcessFlow', 'OffPageConnectorFlow', 'BlankButton', 'HomeButton', 'HelpButton', 'InformationButton', 'ForwardOrNextButton', 'BackOrPreviousButton', 'EndButton', 'BeginningButton', 'ReturnButton', 'DocumentButton', 'SoundButton', 'MovieButton', 'Gear6', 'Gear9', 'Funnel', 'PlusMath', 'MinusMath', 'MultiplyMath', 'DivideMath', 'EqualMath', 'NotEqualMath', 'CornerTabs', 'SquareTabs', 'PlaqueTabs', 'ChartX', 'ChartStar', 'ChartPlus', 'Chart', 'Table', 'PictureFrame', 'VideoFrame', 'AudioFrame', 'Diagram', 'OleObjectFrame', 'GroupShape', 'GraphicalObject', 'NotDefined'])
386
- unless validator.valid?(shape_type)
387
- fail ArgumentError, 'invalid value for "shape_type", must be one of #{validator.allowable_values}.'
388
- end
389
- @shape_type = shape_type
390
- end
391
-
392
- # Custom attribute writer method checking allowed values (enum).
393
- # @param [Object] geometry_shape_type Object to be assigned
394
- def geometry_shape_type=(geometry_shape_type)
395
- validator = EnumAttributeValidator.new('String', ['Custom', 'Line', 'LineInverse', 'Triangle', 'RightTriangle', 'Rectangle', 'Diamond', 'Parallelogram', 'Trapezoid', 'NonIsoscelesTrapezoid', 'Pentagon', 'Hexagon', 'Heptagon', 'Octagon', 'Decagon', 'Dodecagon', 'FourPointedStar', 'FivePointedStar', 'SixPointedStar', 'SevenPointedStar', 'EightPointedStar', 'TenPointedStar', 'TwelvePointedStar', 'SixteenPointedStar', 'TwentyFourPointedStar', 'ThirtyTwoPointedStar', 'RoundCornerRectangle', 'OneRoundCornerRectangle', 'TwoSamesideRoundCornerRectangle', 'TwoDiagonalRoundCornerRectangle', 'OneSnipOneRoundCornerRectangle', 'OneSnipCornerRectangle', 'TwoSamesideSnipCornerRectangle', 'TwoDiagonalSnipCornerRectangle', 'Plaque', 'Ellipse', 'Teardrop', 'HomePlate', 'Chevron', 'PieWedge', 'Pie', 'BlockArc', 'Donut', 'NoSmoking', 'RightArrow', 'LeftArrow', 'UpArrow', 'DownArrow', 'StripedRightArrow', 'NotchedRightArrow', 'BentUpArrow', 'LeftRightArrow', 'UpDownArrow', 'LeftUpArrow', 'LeftRightUpArrow', 'QuadArrow', 'CalloutLeftArrow', 'CalloutRightArrow', 'CalloutUpArrow', 'CalloutDownArrow', 'CalloutLeftRightArrow', 'CalloutUpDownArrow', 'CalloutQuadArrow', 'BentArrow', 'UTurnArrow', 'CircularArrow', 'LeftCircularArrow', 'LeftRightCircularArrow', 'CurvedRightArrow', 'CurvedLeftArrow', 'CurvedUpArrow', 'CurvedDownArrow', 'SwooshArrow', 'Cube', 'Can', 'LightningBolt', 'Heart', 'Sun', 'Moon', 'SmileyFace', 'IrregularSeal1', 'IrregularSeal2', 'FoldedCorner', 'Bevel', 'Frame', 'HalfFrame', 'Corner', 'DiagonalStripe', 'Chord', 'CurvedArc', 'LeftBracket', 'RightBracket', 'LeftBrace', 'RightBrace', 'BracketPair', 'BracePair', 'StraightConnector1', 'BentConnector2', 'BentConnector3', 'BentConnector4', 'BentConnector5', 'CurvedConnector2', 'CurvedConnector3', 'CurvedConnector4', 'CurvedConnector5', 'Callout1', 'Callout2', 'Callout3', 'Callout1WithAccent', 'Callout2WithAccent', 'Callout3WithAccent', 'Callout1WithBorder', 'Callout2WithBorder', 'Callout3WithBorder', 'Callout1WithBorderAndAccent', 'Callout2WithBorderAndAccent', 'Callout3WithBorderAndAccent', 'CalloutWedgeRectangle', 'CalloutWedgeRoundRectangle', 'CalloutWedgeEllipse', 'CalloutCloud', 'Cloud', 'Ribbon', 'Ribbon2', 'EllipseRibbon', 'EllipseRibbon2', 'LeftRightRibbon', 'VerticalScroll', 'HorizontalScroll', 'Wave', 'DoubleWave', 'Plus', 'ProcessFlow', 'DecisionFlow', 'InputOutputFlow', 'PredefinedProcessFlow', 'InternalStorageFlow', 'DocumentFlow', 'MultiDocumentFlow', 'TerminatorFlow', 'PreparationFlow', 'ManualInputFlow', 'ManualOperationFlow', 'ConnectorFlow', 'PunchedCardFlow', 'PunchedTapeFlow', 'SummingJunctionFlow', 'OrFlow', 'CollateFlow', 'SortFlow', 'ExtractFlow', 'MergeFlow', 'OfflineStorageFlow', 'OnlineStorageFlow', 'MagneticTapeFlow', 'MagneticDiskFlow', 'MagneticDrumFlow', 'DisplayFlow', 'DelayFlow', 'AlternateProcessFlow', 'OffPageConnectorFlow', 'BlankButton', 'HomeButton', 'HelpButton', 'InformationButton', 'ForwardOrNextButton', 'BackOrPreviousButton', 'EndButton', 'BeginningButton', 'ReturnButton', 'DocumentButton', 'SoundButton', 'MovieButton', 'Gear6', 'Gear9', 'Funnel', 'PlusMath', 'MinusMath', 'MultiplyMath', 'DivideMath', 'EqualMath', 'NotEqualMath', 'CornerTabs', 'SquareTabs', 'PlaqueTabs', 'ChartX', 'ChartStar', 'ChartPlus', 'NotDefined'])
396
- unless validator.valid?(geometry_shape_type)
397
- fail ArgumentError, 'invalid value for "geometry_shape_type", must be one of #{validator.allowable_values}.'
398
- end
399
- @geometry_shape_type = geometry_shape_type
400
- end
401
-
402
- # Custom attribute writer method checking allowed values (enum).
403
- # @param [Object] play_mode Object to be assigned
404
- def play_mode=(play_mode)
405
- validator = EnumAttributeValidator.new('String', ['Auto', 'OnClick', 'AllSlides', 'Mixed'])
406
- unless validator.valid?(play_mode)
407
- fail ArgumentError, 'invalid value for "play_mode", must be one of #{validator.allowable_values}.'
408
- end
409
- @play_mode = play_mode
410
- end
411
-
412
- # Custom attribute writer method checking allowed values (enum).
413
- # @param [Object] volume Object to be assigned
414
- def volume=(volume)
415
- validator = EnumAttributeValidator.new('String', ['Mute', 'Low', 'Medium', 'Loud', 'Mixed'])
416
- unless validator.valid?(volume)
417
- fail ArgumentError, 'invalid value for "volume", must be one of #{validator.allowable_values}.'
418
- end
419
- @volume = volume
420
- end
421
-
422
- # Checks equality by comparing each attribute.
423
- # @param [Object] Object to be compared
424
- def ==(o)
425
- return true if self.equal?(o)
426
- self.class == o.class &&
427
- self_uri == o.self_uri &&
428
- alternate_links == o.alternate_links &&
429
- name == o.name &&
430
- width == o.width &&
431
- height == o.height &&
432
- alternative_text == o.alternative_text &&
433
- alternative_text_title == o.alternative_text_title &&
434
- hidden == o.hidden &&
435
- x == o.x &&
436
- y == o.y &&
437
- z_order_position == o.z_order_position &&
438
- shapes == o.shapes &&
439
- fill_format == o.fill_format &&
440
- effect_format == o.effect_format &&
441
- line_format == o.line_format &&
442
- type == o.type &&
443
- shape_type == o.shape_type &&
444
- geometry_shape_type == o.geometry_shape_type &&
445
- audio_cd_end_track == o.audio_cd_end_track &&
446
- audio_cd_end_track_time == o.audio_cd_end_track_time &&
447
- audio_cd_start_track == o.audio_cd_start_track &&
448
- audio_cd_start_track_time == o.audio_cd_start_track_time &&
449
- embedded == o.embedded &&
450
- hide_at_showing == o.hide_at_showing &&
451
- play_loop_mode == o.play_loop_mode &&
452
- play_mode == o.play_mode &&
453
- volume == o.volume &&
454
- base64_data == o.base64_data
455
- end
456
-
457
- # @see the `==` method
458
- # @param [Object] Object to be compared
459
- def eql?(o)
460
- self == o
461
- end
462
-
463
- # Calculates hash code according to all attributes.
464
- # @return [Fixnum] Hash code
465
- def hash
466
- [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, line_format, type, shape_type, geometry_shape_type, audio_cd_end_track, audio_cd_end_track_time, audio_cd_start_track, audio_cd_start_track_time, embedded, hide_at_showing, play_loop_mode, play_mode, volume, base64_data].hash
467
- end
468
-
469
- # Builds the object from hash
470
- # @param [Hash] attributes Model attributes in the form of hash
471
- # @return [Object] Returns the model itself
472
- def build_from_hash(attributes)
473
- return nil unless attributes.is_a?(Hash)
474
- self.class.swagger_types.each_pair do |key, type|
475
- if type =~ /\AArray<(.*)>/i
476
- # check to ensure the input is an array given that the the attribute
477
- # is documented as an array but the input is not
478
- if attributes[self.class.attribute_map[key]].is_a?(Array)
479
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
480
- end
481
- elsif !attributes[self.class.attribute_map[key]].nil?
482
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
483
- end # or else data not found in attributes(hash), not an issue as the data can be optional
484
- end
485
-
486
- self
487
- end
488
-
489
- # Deserializes the data based on type
490
- # @param string type Data type
491
- # @param string value Value to be deserialized
492
- # @return [Object] Deserialized data
493
- def _deserialize(type, value)
494
- case type.to_sym
495
- when :DateTime
496
- DateTime.parse(value)
497
- when :Date
498
- Date.parse(value)
499
- when :String
500
- value.to_s
501
- when :Integer
502
- value.to_i
503
- when :Float
504
- value.to_f
505
- when :BOOLEAN
506
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
507
- true
508
- else
509
- false
510
- end
511
- when :Object
512
- # generic object (usually a Hash), return directly
513
- value
514
- when /\AArray<(?<inner_type>.+)>\z/
515
- inner_type = Regexp.last_match[:inner_type]
516
- value.map { |v| _deserialize(inner_type, v) }
517
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
518
- k_type = Regexp.last_match[:k_type]
519
- v_type = Regexp.last_match[:v_type]
520
- {}.tap do |hash|
521
- value.each do |k, v|
522
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
523
- end
524
- end
525
- else # model
526
- temp_model = AsposeSlidesCloud.const_get(type).new
527
- temp_model.build_from_hash(value)
528
- end
529
- end
530
-
531
- # Returns the string representation of the object
532
- # @return [String] String presentation of the object
533
- def to_s
534
- to_hash.to_s
535
- end
536
-
537
- # to_body is an alias to to_hash (backward compatibility)
538
- # @return [Hash] Returns the object in the form of hash
539
- def to_body
540
- to_hash
541
- end
542
-
543
- # Returns the object in the form of hash
544
- # @return [Hash] Returns the object in the form of hash
545
- def to_hash
546
- hash = {}
547
- self.class.attribute_map.each_pair do |attr, param|
548
- value = self.send(attr)
549
- next if value.nil?
550
- hash[param] = _to_hash(value)
551
- end
552
- hash
553
- end
554
-
555
- # Outputs non-array value in the form of hash
556
- # For object, use to_hash. Otherwise, just return the value
557
- # @param [Object] value Any valid value
558
- # @return [Hash] Returns the value in the form of hash
559
- def _to_hash(value)
560
- if value.is_a?(Array)
561
- value.compact.map { |v| _to_hash(v) }
562
- elsif value.is_a?(Hash)
563
- {}.tap do |hash|
564
- value.each { |k, v| hash[k] = _to_hash(v) }
565
- end
566
- elsif value.respond_to? :to_hash
567
- value.to_hash
568
- else
569
- value
570
- end
571
- end
572
- end
573
- end
1
+ =begin
2
+ Copyright (c) 2019 Aspose Pty Ltd
3
+
4
+ Permission is hereby granted, free of charge, to any person obtaining a copy
5
+ of this software and associated documentation files (the "Software"), to deal
6
+ in the Software without restriction, including without limitation the rights
7
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
+ copies of the Software, and to permit persons to whom the Software is
9
+ furnished to do so, subject to the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be included in all
12
+ copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20
+ SOFTWARE.
21
+ =end
22
+
23
+ require 'date'
24
+
25
+ module AsposeSlidesCloud
26
+ # Represents AudioFrame resource.
27
+ class AudioFrame < GeometryShape
28
+ # Returns or sets a last track index.
29
+ attr_accessor :audio_cd_end_track
30
+
31
+ # Returns or sets a last track time.
32
+ attr_accessor :audio_cd_end_track_time
33
+
34
+ # Returns or sets a start track index.
35
+ attr_accessor :audio_cd_start_track
36
+
37
+ # Returns or sets a start track time.
38
+ attr_accessor :audio_cd_start_track_time
39
+
40
+ # Determines whether a sound is embedded to a presentation.
41
+ attr_accessor :embedded
42
+
43
+ # Determines whether an AudioFrame is hidden.
44
+ attr_accessor :hide_at_showing
45
+
46
+ # Determines whether an audio is looped.
47
+ attr_accessor :play_loop_mode
48
+
49
+ # Returns or sets the audio play mode.
50
+ attr_accessor :play_mode
51
+
52
+ # Returns or sets the audio volume.
53
+ attr_accessor :volume
54
+
55
+ # Audio data encoded in base64.
56
+ attr_accessor :base64_data
57
+
58
+ class EnumAttributeValidator
59
+ attr_reader :datatype
60
+ attr_reader :allowable_values
61
+
62
+ def initialize(datatype, allowable_values)
63
+ @allowable_values = allowable_values.map do |value|
64
+ case datatype.to_s
65
+ when /Integer/i
66
+ value.to_i
67
+ when /Float/i
68
+ value.to_f
69
+ else
70
+ value
71
+ end
72
+ end
73
+ end
74
+
75
+ def valid?(value)
76
+ !value || allowable_values.any?{ |s| s.casecmp(value) == 0 }
77
+ end
78
+ end
79
+
80
+ # Attribute mapping from ruby-style variable name to JSON key.
81
+ def self.attribute_map
82
+ super.merge({
83
+ :'audio_cd_end_track' => :'AudioCdEndTrack',
84
+ :'audio_cd_end_track_time' => :'AudioCdEndTrackTime',
85
+ :'audio_cd_start_track' => :'AudioCdStartTrack',
86
+ :'audio_cd_start_track_time' => :'AudioCdStartTrackTime',
87
+ :'embedded' => :'Embedded',
88
+ :'hide_at_showing' => :'HideAtShowing',
89
+ :'play_loop_mode' => :'PlayLoopMode',
90
+ :'play_mode' => :'PlayMode',
91
+ :'volume' => :'Volume',
92
+ :'base64_data' => :'Base64Data',
93
+ })
94
+ end
95
+
96
+ # Attribute type mapping.
97
+ def self.swagger_types
98
+ super.merge({
99
+ :'audio_cd_end_track' => :'Integer',
100
+ :'audio_cd_end_track_time' => :'Integer',
101
+ :'audio_cd_start_track' => :'Integer',
102
+ :'audio_cd_start_track_time' => :'Integer',
103
+ :'embedded' => :'BOOLEAN',
104
+ :'hide_at_showing' => :'BOOLEAN',
105
+ :'play_loop_mode' => :'BOOLEAN',
106
+ :'play_mode' => :'String',
107
+ :'volume' => :'String',
108
+ :'base64_data' => :'String',
109
+ })
110
+ end
111
+
112
+ # Initializes the object
113
+ # @param [Hash] attributes Model attributes in the form of hash
114
+ def initialize(attributes = {})
115
+ super
116
+
117
+ if attributes.has_key?(:'AudioCdEndTrack')
118
+ self.audio_cd_end_track = attributes[:'AudioCdEndTrack']
119
+ end
120
+
121
+ if attributes.has_key?(:'AudioCdEndTrackTime')
122
+ self.audio_cd_end_track_time = attributes[:'AudioCdEndTrackTime']
123
+ end
124
+
125
+ if attributes.has_key?(:'AudioCdStartTrack')
126
+ self.audio_cd_start_track = attributes[:'AudioCdStartTrack']
127
+ end
128
+
129
+ if attributes.has_key?(:'AudioCdStartTrackTime')
130
+ self.audio_cd_start_track_time = attributes[:'AudioCdStartTrackTime']
131
+ end
132
+
133
+ if attributes.has_key?(:'Embedded')
134
+ self.embedded = attributes[:'Embedded']
135
+ end
136
+
137
+ if attributes.has_key?(:'HideAtShowing')
138
+ self.hide_at_showing = attributes[:'HideAtShowing']
139
+ end
140
+
141
+ if attributes.has_key?(:'PlayLoopMode')
142
+ self.play_loop_mode = attributes[:'PlayLoopMode']
143
+ end
144
+
145
+ if attributes.has_key?(:'PlayMode')
146
+ self.play_mode = attributes[:'PlayMode']
147
+ end
148
+
149
+ if attributes.has_key?(:'Volume')
150
+ self.volume = attributes[:'Volume']
151
+ end
152
+
153
+ if attributes.has_key?(:'Base64Data')
154
+ self.base64_data = attributes[:'Base64Data']
155
+ end
156
+ self.type = "AudioFrame"
157
+ end
158
+
159
+ # Show invalid properties with the reasons. Usually used together with valid?
160
+ # @return Array for valid properties with the reasons
161
+ def list_invalid_properties
162
+ invalid_properties = super
163
+ invalid_properties
164
+ end
165
+
166
+ # Check to see if the all the properties in the model are valid
167
+ # @return true if the model is valid
168
+ def valid?
169
+ return false if !super
170
+ play_mode_validator = EnumAttributeValidator.new('String', ['Auto', 'OnClick', 'AllSlides', 'Mixed'])
171
+ return false unless play_mode_validator.valid?(@play_mode)
172
+ volume_validator = EnumAttributeValidator.new('String', ['Mute', 'Low', 'Medium', 'Loud', 'Mixed'])
173
+ return false unless volume_validator.valid?(@volume)
174
+ true
175
+ end
176
+
177
+ # Custom attribute writer method checking allowed values (enum).
178
+ # @param [Object] play_mode Object to be assigned
179
+ def play_mode=(play_mode)
180
+ validator = EnumAttributeValidator.new('String', ['Auto', 'OnClick', 'AllSlides', 'Mixed'])
181
+ unless validator.valid?(play_mode)
182
+ fail ArgumentError, 'invalid value for "play_mode", must be one of #{validator.allowable_values}.'
183
+ end
184
+ @play_mode = play_mode
185
+ end
186
+
187
+ # Custom attribute writer method checking allowed values (enum).
188
+ # @param [Object] volume Object to be assigned
189
+ def volume=(volume)
190
+ validator = EnumAttributeValidator.new('String', ['Mute', 'Low', 'Medium', 'Loud', 'Mixed'])
191
+ unless validator.valid?(volume)
192
+ fail ArgumentError, 'invalid value for "volume", must be one of #{validator.allowable_values}.'
193
+ end
194
+ @volume = volume
195
+ end
196
+
197
+ # Checks equality by comparing each attribute.
198
+ # @param [Object] Object to be compared
199
+ def ==(o)
200
+ return true if self.equal?(o)
201
+ self.class == o.class &&
202
+ self_uri == o.self_uri &&
203
+ alternate_links == o.alternate_links &&
204
+ name == o.name &&
205
+ width == o.width &&
206
+ height == o.height &&
207
+ alternative_text == o.alternative_text &&
208
+ alternative_text_title == o.alternative_text_title &&
209
+ hidden == o.hidden &&
210
+ x == o.x &&
211
+ y == o.y &&
212
+ z_order_position == o.z_order_position &&
213
+ shapes == o.shapes &&
214
+ fill_format == o.fill_format &&
215
+ effect_format == o.effect_format &&
216
+ line_format == o.line_format &&
217
+ type == o.type &&
218
+ shape_type == o.shape_type &&
219
+ audio_cd_end_track == o.audio_cd_end_track &&
220
+ audio_cd_end_track_time == o.audio_cd_end_track_time &&
221
+ audio_cd_start_track == o.audio_cd_start_track &&
222
+ audio_cd_start_track_time == o.audio_cd_start_track_time &&
223
+ embedded == o.embedded &&
224
+ hide_at_showing == o.hide_at_showing &&
225
+ play_loop_mode == o.play_loop_mode &&
226
+ play_mode == o.play_mode &&
227
+ volume == o.volume &&
228
+ base64_data == o.base64_data
229
+ end
230
+
231
+ # @see the `==` method
232
+ # @param [Object] Object to be compared
233
+ def eql?(o)
234
+ self == o
235
+ end
236
+
237
+ # Calculates hash code according to all attributes.
238
+ # @return [Fixnum] Hash code
239
+ def hash
240
+ [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, line_format, type, shape_type, audio_cd_end_track, audio_cd_end_track_time, audio_cd_start_track, audio_cd_start_track_time, embedded, hide_at_showing, play_loop_mode, play_mode, volume, base64_data].hash
241
+ end
242
+
243
+ # Builds the object from hash
244
+ # @param [Hash] attributes Model attributes in the form of hash
245
+ # @return [Object] Returns the model itself
246
+ def build_from_hash(attributes)
247
+ return nil unless attributes.is_a?(Hash)
248
+ self.class.swagger_types.each_pair do |key, type|
249
+ mapKey = self.class.attribute_map[key]
250
+ if !mapKey.nil?
251
+ val = attributes[mapKey]
252
+ if val.nil?
253
+ mapKeyString = mapKey.to_s
254
+ mapKeyString[0] = mapKeyString[0].downcase
255
+ mapKey = mapKeyString.to_sym
256
+ val = attributes[mapKey]
257
+ end
258
+ if !val.nil?
259
+ if type =~ /\AArray<(.*)>/i
260
+ # check to ensure the input is an array given that the the attribute
261
+ # is documented as an array but the input is not
262
+ if val.is_a?(Array)
263
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
264
+ end
265
+ else
266
+ self.send("#{key}=", _deserialize(type, val))
267
+ end
268
+ end
269
+ end
270
+ end
271
+
272
+ self
273
+ end
274
+
275
+ # Deserializes the data based on type
276
+ # @param string type Data type
277
+ # @param string value Value to be deserialized
278
+ # @return [Object] Deserialized data
279
+ def _deserialize(type, value)
280
+ case type.to_sym
281
+ when :DateTime
282
+ DateTime.parse(value)
283
+ when :Date
284
+ Date.parse(value)
285
+ when :String
286
+ value.to_s
287
+ when :Integer
288
+ value.to_i
289
+ when :Float
290
+ value.to_f
291
+ when :BOOLEAN
292
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
293
+ true
294
+ else
295
+ false
296
+ end
297
+ when :Object
298
+ # generic object (usually a Hash), return directly
299
+ value
300
+ when /\AArray<(?<inner_type>.+)>\z/
301
+ inner_type = Regexp.last_match[:inner_type]
302
+ value.map { |v| _deserialize(inner_type, v) }
303
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
304
+ k_type = Regexp.last_match[:k_type]
305
+ v_type = Regexp.last_match[:v_type]
306
+ {}.tap do |hash|
307
+ value.each do |k, v|
308
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
309
+ end
310
+ end
311
+ else # model
312
+ temp_model = AsposeSlidesCloud.const_get(type).new
313
+ temp_model.build_from_hash(value)
314
+ end
315
+ end
316
+
317
+ # Returns the string representation of the object
318
+ # @return [String] String presentation of the object
319
+ def to_s
320
+ to_hash.to_s
321
+ end
322
+
323
+ # to_body is an alias to to_hash (backward compatibility)
324
+ # @return [Hash] Returns the object in the form of hash
325
+ def to_body
326
+ to_hash
327
+ end
328
+
329
+ # Returns the object in the form of hash
330
+ # @return [Hash] Returns the object in the form of hash
331
+ def to_hash
332
+ hash = {}
333
+ self.class.attribute_map.each_pair do |attr, param|
334
+ value = self.send(attr)
335
+ next if value.nil?
336
+ hash[param] = _to_hash(value)
337
+ end
338
+ hash
339
+ end
340
+
341
+ # Outputs non-array value in the form of hash
342
+ # For object, use to_hash. Otherwise, just return the value
343
+ # @param [Object] value Any valid value
344
+ # @return [Hash] Returns the value in the form of hash
345
+ def _to_hash(value)
346
+ if value.is_a?(Array)
347
+ value.compact.map { |v| _to_hash(v) }
348
+ elsif value.is_a?(Hash)
349
+ {}.tap do |hash|
350
+ value.each { |k, v| hash[k] = _to_hash(v) }
351
+ end
352
+ elsif value.respond_to? :to_hash
353
+ value.to_hash
354
+ else
355
+ value
356
+ end
357
+ end
358
+ end
359
+ end