aspose_slides_cloud 23.10.0 → 24.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,121 @@
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
+ # Operation progress.
27
+ class OperationProgress < BaseObject
28
+ # Description.
29
+ attr_accessor :description
30
+
31
+ # Current Step Index.
32
+ attr_accessor :step_index
33
+
34
+ # Current Step Index.
35
+ attr_accessor :step_count
36
+
37
+ # Attribute mapping from ruby-style variable name to JSON key.
38
+ def self.attribute_map
39
+ {
40
+ :'description' => :'Description',
41
+ :'step_index' => :'StepIndex',
42
+ :'step_count' => :'StepCount',
43
+ }
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.swagger_types
48
+ {
49
+ :'description' => :'String',
50
+ :'step_index' => :'Integer',
51
+ :'step_count' => :'Integer',
52
+ }
53
+ end
54
+
55
+ # Initializes the object
56
+ # @param [Hash] attributes Model attributes in the form of hash
57
+ 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?(:'Description')
64
+ self.description = attributes[:'Description']
65
+ end
66
+
67
+ if attributes.has_key?(:'StepIndex')
68
+ self.step_index = attributes[:'StepIndex']
69
+ end
70
+
71
+ if attributes.has_key?(:'StepCount')
72
+ self.step_count = attributes[:'StepCount']
73
+ end
74
+ end
75
+
76
+ # Show invalid properties with the reasons. Usually used together with valid?
77
+ # @return Array for valid properties with the reasons
78
+ def list_invalid_properties
79
+ invalid_properties = Array.new
80
+ if @step_index.nil?
81
+ invalid_properties.push('invalid value for "step_index", step_index cannot be nil.')
82
+ end
83
+
84
+ if @step_count.nil?
85
+ invalid_properties.push('invalid value for "step_count", step_count cannot be nil.')
86
+ end
87
+
88
+ invalid_properties
89
+ end
90
+
91
+ # Check to see if the all the properties in the model are valid
92
+ # @return true if the model is valid
93
+ def valid?
94
+ return false if @step_index.nil?
95
+ return false if @step_count.nil?
96
+ true
97
+ end
98
+
99
+ # Checks equality by comparing each attribute.
100
+ # @param [Object] Object to be compared
101
+ def ==(o)
102
+ return true if self.equal?(o)
103
+ self.class == o.class &&
104
+ description == o.description &&
105
+ step_index == o.step_index &&
106
+ step_count == o.step_count
107
+ end
108
+
109
+ # @see the `==` method
110
+ # @param [Object] Object to be compared
111
+ def eql?(o)
112
+ self == o
113
+ end
114
+
115
+ # Calculates hash code according to all attributes.
116
+ # @return [Fixnum] Hash code
117
+ def hash
118
+ [description, step_index, step_count].hash
119
+ end
120
+ end
121
+ end
@@ -34,6 +34,9 @@ module AsposeSlidesCloud
34
34
  # Specifies if shapes of the master slide should be shown on the slide. True by default.
35
35
  attr_accessor :show_master_shapes
36
36
 
37
+ # Specifies if shapes of the master slide should be shown on the slide. True by default.
38
+ attr_accessor :slide_show_transition
39
+
37
40
  # Gets or sets the link to the layout slide.
38
41
  attr_accessor :layout_slide
39
42
 
@@ -64,6 +67,7 @@ module AsposeSlidesCloud
64
67
  :'width' => :'Width',
65
68
  :'height' => :'Height',
66
69
  :'show_master_shapes' => :'ShowMasterShapes',
70
+ :'slide_show_transition' => :'SlideShowTransition',
67
71
  :'layout_slide' => :'LayoutSlide',
68
72
  :'shapes' => :'Shapes',
69
73
  :'theme' => :'Theme',
@@ -81,6 +85,7 @@ module AsposeSlidesCloud
81
85
  :'width' => :'Float',
82
86
  :'height' => :'Float',
83
87
  :'show_master_shapes' => :'BOOLEAN',
88
+ :'slide_show_transition' => :'SlideShowTransition',
84
89
  :'layout_slide' => :'ResourceUri',
85
90
  :'shapes' => :'ResourceUri',
86
91
  :'theme' => :'ResourceUri',
@@ -109,6 +114,10 @@ module AsposeSlidesCloud
109
114
  self.show_master_shapes = attributes[:'ShowMasterShapes']
110
115
  end
111
116
 
117
+ if attributes.has_key?(:'SlideShowTransition')
118
+ self.slide_show_transition = attributes[:'SlideShowTransition']
119
+ end
120
+
112
121
  if attributes.has_key?(:'LayoutSlide')
113
122
  self.layout_slide = attributes[:'LayoutSlide']
114
123
  end
@@ -181,6 +190,7 @@ module AsposeSlidesCloud
181
190
  width == o.width &&
182
191
  height == o.height &&
183
192
  show_master_shapes == o.show_master_shapes &&
193
+ slide_show_transition == o.slide_show_transition &&
184
194
  layout_slide == o.layout_slide &&
185
195
  shapes == o.shapes &&
186
196
  theme == o.theme &&
@@ -200,7 +210,7 @@ module AsposeSlidesCloud
200
210
  # Calculates hash code according to all attributes.
201
211
  # @return [Fixnum] Hash code
202
212
  def hash
203
- [self_uri, alternate_links, width, height, show_master_shapes, layout_slide, shapes, theme, placeholders, images, comments, background, notes_slide].hash
213
+ [self_uri, alternate_links, width, height, show_master_shapes, slide_show_transition, layout_slide, shapes, theme, placeholders, images, comments, background, notes_slide].hash
204
214
  end
205
215
  end
206
216
  end
@@ -81,6 +81,7 @@ module AsposeSlidesCloud
81
81
  width == o.width &&
82
82
  height == o.height &&
83
83
  show_master_shapes == o.show_master_shapes &&
84
+ slide_show_transition == o.slide_show_transition &&
84
85
  layout_slide == o.layout_slide &&
85
86
  shapes == o.shapes &&
86
87
  theme == o.theme &&
@@ -101,7 +102,7 @@ module AsposeSlidesCloud
101
102
  # Calculates hash code according to all attributes.
102
103
  # @return [Fixnum] Hash code
103
104
  def hash
104
- [self_uri, alternate_links, width, height, show_master_shapes, layout_slide, shapes, theme, placeholders, images, comments, background, notes_slide, matches].hash
105
+ [self_uri, alternate_links, width, height, show_master_shapes, slide_show_transition, layout_slide, shapes, theme, placeholders, images, comments, background, notes_slide, matches].hash
105
106
  end
106
107
  end
107
108
  end
@@ -0,0 +1,489 @@
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
+ # Slide Show Transition.
27
+ class SlideShowTransition < BaseObject
28
+ # Transition Type
29
+ attr_accessor :type
30
+
31
+ # Advance After
32
+ attr_accessor :advance_after
33
+
34
+ # Advance After Time
35
+ attr_accessor :advance_after_time
36
+
37
+ # Advance On Click
38
+ attr_accessor :advance_on_click
39
+
40
+ # Sound Is Built In
41
+ attr_accessor :sound_is_built_in
42
+
43
+ # Sound Loop
44
+ attr_accessor :sound_loop
45
+
46
+ # Sound Mode
47
+ attr_accessor :sound_mode
48
+
49
+ # Sound Name
50
+ attr_accessor :sound_name
51
+
52
+ # Speed
53
+ attr_accessor :speed
54
+
55
+ # Corner Direction.
56
+ attr_accessor :corner_direction
57
+
58
+ # Eight Direction.
59
+ attr_accessor :eight_direction
60
+
61
+ # In/Out Direction.
62
+ attr_accessor :in_out_direction
63
+
64
+ # Has Bounce.
65
+ attr_accessor :has_bounce
66
+
67
+ # Side Direction.
68
+ attr_accessor :side_direction
69
+
70
+ # Pattern.
71
+ attr_accessor :pattern
72
+
73
+ # Left/Right Direction.
74
+ attr_accessor :left_right_direction
75
+
76
+ # Morph Type.
77
+ attr_accessor :morph_type
78
+
79
+ # From Black.
80
+ attr_accessor :from_black
81
+
82
+ # Orientation Direction.
83
+ attr_accessor :orientation_direction
84
+
85
+ # Through Black.
86
+ attr_accessor :through_black
87
+
88
+ # Orientation.
89
+ attr_accessor :corner_and_center_direction
90
+
91
+ # Shred Pattern.
92
+ attr_accessor :shred_pattern
93
+
94
+ # Orientation.
95
+ attr_accessor :orientation
96
+
97
+ # Spokes.
98
+ attr_accessor :spokes
99
+
100
+ # Attribute mapping from ruby-style variable name to JSON key.
101
+ def self.attribute_map
102
+ {
103
+ :'type' => :'Type',
104
+ :'advance_after' => :'AdvanceAfter',
105
+ :'advance_after_time' => :'AdvanceAfterTime',
106
+ :'advance_on_click' => :'AdvanceOnClick',
107
+ :'sound_is_built_in' => :'SoundIsBuiltIn',
108
+ :'sound_loop' => :'SoundLoop',
109
+ :'sound_mode' => :'SoundMode',
110
+ :'sound_name' => :'SoundName',
111
+ :'speed' => :'Speed',
112
+ :'corner_direction' => :'CornerDirection',
113
+ :'eight_direction' => :'EightDirection',
114
+ :'in_out_direction' => :'InOutDirection',
115
+ :'has_bounce' => :'HasBounce',
116
+ :'side_direction' => :'SideDirection',
117
+ :'pattern' => :'Pattern',
118
+ :'left_right_direction' => :'LeftRightDirection',
119
+ :'morph_type' => :'MorphType',
120
+ :'from_black' => :'FromBlack',
121
+ :'orientation_direction' => :'OrientationDirection',
122
+ :'through_black' => :'ThroughBlack',
123
+ :'corner_and_center_direction' => :'CornerAndCenterDirection',
124
+ :'shred_pattern' => :'ShredPattern',
125
+ :'orientation' => :'Orientation',
126
+ :'spokes' => :'Spokes',
127
+ }
128
+ end
129
+
130
+ # Attribute type mapping.
131
+ def self.swagger_types
132
+ {
133
+ :'type' => :'String',
134
+ :'advance_after' => :'BOOLEAN',
135
+ :'advance_after_time' => :'Integer',
136
+ :'advance_on_click' => :'BOOLEAN',
137
+ :'sound_is_built_in' => :'BOOLEAN',
138
+ :'sound_loop' => :'BOOLEAN',
139
+ :'sound_mode' => :'String',
140
+ :'sound_name' => :'String',
141
+ :'speed' => :'String',
142
+ :'corner_direction' => :'String',
143
+ :'eight_direction' => :'String',
144
+ :'in_out_direction' => :'String',
145
+ :'has_bounce' => :'BOOLEAN',
146
+ :'side_direction' => :'String',
147
+ :'pattern' => :'String',
148
+ :'left_right_direction' => :'String',
149
+ :'morph_type' => :'String',
150
+ :'from_black' => :'BOOLEAN',
151
+ :'orientation_direction' => :'String',
152
+ :'through_black' => :'BOOLEAN',
153
+ :'corner_and_center_direction' => :'String',
154
+ :'shred_pattern' => :'String',
155
+ :'orientation' => :'String',
156
+ :'spokes' => :'Integer',
157
+ }
158
+ end
159
+
160
+ # Initializes the object
161
+ # @param [Hash] attributes Model attributes in the form of hash
162
+ def initialize(attributes = {})
163
+ return unless attributes.is_a?(Hash)
164
+
165
+ # convert string to symbol for hash key
166
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
167
+
168
+ if attributes.has_key?(:'Type')
169
+ self.type = attributes[:'Type']
170
+ end
171
+
172
+ if attributes.has_key?(:'AdvanceAfter')
173
+ self.advance_after = attributes[:'AdvanceAfter']
174
+ end
175
+
176
+ if attributes.has_key?(:'AdvanceAfterTime')
177
+ self.advance_after_time = attributes[:'AdvanceAfterTime']
178
+ end
179
+
180
+ if attributes.has_key?(:'AdvanceOnClick')
181
+ self.advance_on_click = attributes[:'AdvanceOnClick']
182
+ end
183
+
184
+ if attributes.has_key?(:'SoundIsBuiltIn')
185
+ self.sound_is_built_in = attributes[:'SoundIsBuiltIn']
186
+ end
187
+
188
+ if attributes.has_key?(:'SoundLoop')
189
+ self.sound_loop = attributes[:'SoundLoop']
190
+ end
191
+
192
+ if attributes.has_key?(:'SoundMode')
193
+ self.sound_mode = attributes[:'SoundMode']
194
+ end
195
+
196
+ if attributes.has_key?(:'SoundName')
197
+ self.sound_name = attributes[:'SoundName']
198
+ end
199
+
200
+ if attributes.has_key?(:'Speed')
201
+ self.speed = attributes[:'Speed']
202
+ end
203
+
204
+ if attributes.has_key?(:'CornerDirection')
205
+ self.corner_direction = attributes[:'CornerDirection']
206
+ end
207
+
208
+ if attributes.has_key?(:'EightDirection')
209
+ self.eight_direction = attributes[:'EightDirection']
210
+ end
211
+
212
+ if attributes.has_key?(:'InOutDirection')
213
+ self.in_out_direction = attributes[:'InOutDirection']
214
+ end
215
+
216
+ if attributes.has_key?(:'HasBounce')
217
+ self.has_bounce = attributes[:'HasBounce']
218
+ end
219
+
220
+ if attributes.has_key?(:'SideDirection')
221
+ self.side_direction = attributes[:'SideDirection']
222
+ end
223
+
224
+ if attributes.has_key?(:'Pattern')
225
+ self.pattern = attributes[:'Pattern']
226
+ end
227
+
228
+ if attributes.has_key?(:'LeftRightDirection')
229
+ self.left_right_direction = attributes[:'LeftRightDirection']
230
+ end
231
+
232
+ if attributes.has_key?(:'MorphType')
233
+ self.morph_type = attributes[:'MorphType']
234
+ end
235
+
236
+ if attributes.has_key?(:'FromBlack')
237
+ self.from_black = attributes[:'FromBlack']
238
+ end
239
+
240
+ if attributes.has_key?(:'OrientationDirection')
241
+ self.orientation_direction = attributes[:'OrientationDirection']
242
+ end
243
+
244
+ if attributes.has_key?(:'ThroughBlack')
245
+ self.through_black = attributes[:'ThroughBlack']
246
+ end
247
+
248
+ if attributes.has_key?(:'CornerAndCenterDirection')
249
+ self.corner_and_center_direction = attributes[:'CornerAndCenterDirection']
250
+ end
251
+
252
+ if attributes.has_key?(:'ShredPattern')
253
+ self.shred_pattern = attributes[:'ShredPattern']
254
+ end
255
+
256
+ if attributes.has_key?(:'Orientation')
257
+ self.orientation = attributes[:'Orientation']
258
+ end
259
+
260
+ if attributes.has_key?(:'Spokes')
261
+ self.spokes = attributes[:'Spokes']
262
+ end
263
+ end
264
+
265
+ # Show invalid properties with the reasons. Usually used together with valid?
266
+ # @return Array for valid properties with the reasons
267
+ def list_invalid_properties
268
+ invalid_properties = Array.new
269
+ invalid_properties
270
+ end
271
+
272
+ # Check to see if the all the properties in the model are valid
273
+ # @return true if the model is valid
274
+ def valid?
275
+ type_validator = EnumAttributeValidator.new('String', ['None', 'Blinds', 'Checker', 'Circle', 'Comb', 'Cover', 'Cut', 'Diamond', 'Dissolve', 'Fade', 'Newsflash', 'Plus', 'Pull', 'Push', 'Random', 'RandomBar', 'Split', 'Strips', 'Wedge', 'Wheel', 'Wipe', 'Zoom', 'Vortex', 'Switch', 'Flip', 'Ripple', 'Honeycomb', 'Cube', 'Box', 'Rotate', 'Orbit', 'Doors', 'Window', 'Ferris', 'Gallery', 'Conveyor', 'Pan', 'Glitter', 'Warp', 'Flythrough', 'Flash', 'Shred', 'Reveal', 'WheelReverse', 'FallOver', 'Drape', 'Curtains', 'Wind', 'Prestige', 'Fracture', 'Crush', 'PeelOff', 'PageCurlDouble', 'PageCurlSingle', 'Airplane', 'Origami', 'Morph'])
276
+ return false unless type_validator.valid?(@type)
277
+ sound_mode_validator = EnumAttributeValidator.new('String', ['StartSound', 'StopPrevoiusSound', 'NotDefined'])
278
+ return false unless sound_mode_validator.valid?(@sound_mode)
279
+ speed_validator = EnumAttributeValidator.new('String', ['Fast', 'Medium', 'Slow'])
280
+ return false unless speed_validator.valid?(@speed)
281
+ corner_direction_validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp'])
282
+ return false unless corner_direction_validator.valid?(@corner_direction)
283
+ eight_direction_validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp', 'Left', 'Up', 'Down', 'Right'])
284
+ return false unless eight_direction_validator.valid?(@eight_direction)
285
+ in_out_direction_validator = EnumAttributeValidator.new('String', ['In', 'Out'])
286
+ return false unless in_out_direction_validator.valid?(@in_out_direction)
287
+ side_direction_validator = EnumAttributeValidator.new('String', ['Left', 'Up', 'Down', 'Right'])
288
+ return false unless side_direction_validator.valid?(@side_direction)
289
+ pattern_validator = EnumAttributeValidator.new('String', ['Diamond', 'Hexagon'])
290
+ return false unless pattern_validator.valid?(@pattern)
291
+ left_right_direction_validator = EnumAttributeValidator.new('String', ['Left', 'Right'])
292
+ return false unless left_right_direction_validator.valid?(@left_right_direction)
293
+ morph_type_validator = EnumAttributeValidator.new('String', ['ByObject', 'ByWord', 'ByChar'])
294
+ return false unless morph_type_validator.valid?(@morph_type)
295
+ orientation_direction_validator = EnumAttributeValidator.new('String', ['Horizontal', 'Vertical'])
296
+ return false unless orientation_direction_validator.valid?(@orientation_direction)
297
+ corner_and_center_direction_validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp', 'Center'])
298
+ return false unless corner_and_center_direction_validator.valid?(@corner_and_center_direction)
299
+ shred_pattern_validator = EnumAttributeValidator.new('String', ['Strip', 'Rectangle'])
300
+ return false unless shred_pattern_validator.valid?(@shred_pattern)
301
+ orientation_validator = EnumAttributeValidator.new('String', ['Horizontal', 'Vertical'])
302
+ return false unless orientation_validator.valid?(@orientation)
303
+ true
304
+ end
305
+
306
+ # Custom attribute writer method checking allowed values (enum).
307
+ # @param [Object] type Object to be assigned
308
+ def type=(type)
309
+ validator = EnumAttributeValidator.new('String', ['None', 'Blinds', 'Checker', 'Circle', 'Comb', 'Cover', 'Cut', 'Diamond', 'Dissolve', 'Fade', 'Newsflash', 'Plus', 'Pull', 'Push', 'Random', 'RandomBar', 'Split', 'Strips', 'Wedge', 'Wheel', 'Wipe', 'Zoom', 'Vortex', 'Switch', 'Flip', 'Ripple', 'Honeycomb', 'Cube', 'Box', 'Rotate', 'Orbit', 'Doors', 'Window', 'Ferris', 'Gallery', 'Conveyor', 'Pan', 'Glitter', 'Warp', 'Flythrough', 'Flash', 'Shred', 'Reveal', 'WheelReverse', 'FallOver', 'Drape', 'Curtains', 'Wind', 'Prestige', 'Fracture', 'Crush', 'PeelOff', 'PageCurlDouble', 'PageCurlSingle', 'Airplane', 'Origami', 'Morph'])
310
+ unless validator.valid?(type)
311
+ fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
312
+ end
313
+ @type = type
314
+ end
315
+
316
+ # Custom attribute writer method checking allowed values (enum).
317
+ # @param [Object] sound_mode Object to be assigned
318
+ def sound_mode=(sound_mode)
319
+ validator = EnumAttributeValidator.new('String', ['StartSound', 'StopPrevoiusSound', 'NotDefined'])
320
+ unless validator.valid?(sound_mode)
321
+ fail ArgumentError, 'invalid value for "sound_mode", must be one of #{validator.allowable_values}.'
322
+ end
323
+ @sound_mode = sound_mode
324
+ end
325
+
326
+ # Custom attribute writer method checking allowed values (enum).
327
+ # @param [Object] speed Object to be assigned
328
+ def speed=(speed)
329
+ validator = EnumAttributeValidator.new('String', ['Fast', 'Medium', 'Slow'])
330
+ unless validator.valid?(speed)
331
+ fail ArgumentError, 'invalid value for "speed", must be one of #{validator.allowable_values}.'
332
+ end
333
+ @speed = speed
334
+ end
335
+
336
+ # Custom attribute writer method checking allowed values (enum).
337
+ # @param [Object] corner_direction Object to be assigned
338
+ def corner_direction=(corner_direction)
339
+ validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp'])
340
+ unless validator.valid?(corner_direction)
341
+ fail ArgumentError, 'invalid value for "corner_direction", must be one of #{validator.allowable_values}.'
342
+ end
343
+ @corner_direction = corner_direction
344
+ end
345
+
346
+ # Custom attribute writer method checking allowed values (enum).
347
+ # @param [Object] eight_direction Object to be assigned
348
+ def eight_direction=(eight_direction)
349
+ validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp', 'Left', 'Up', 'Down', 'Right'])
350
+ unless validator.valid?(eight_direction)
351
+ fail ArgumentError, 'invalid value for "eight_direction", must be one of #{validator.allowable_values}.'
352
+ end
353
+ @eight_direction = eight_direction
354
+ end
355
+
356
+ # Custom attribute writer method checking allowed values (enum).
357
+ # @param [Object] in_out_direction Object to be assigned
358
+ def in_out_direction=(in_out_direction)
359
+ validator = EnumAttributeValidator.new('String', ['In', 'Out'])
360
+ unless validator.valid?(in_out_direction)
361
+ fail ArgumentError, 'invalid value for "in_out_direction", must be one of #{validator.allowable_values}.'
362
+ end
363
+ @in_out_direction = in_out_direction
364
+ end
365
+
366
+ # Custom attribute writer method checking allowed values (enum).
367
+ # @param [Object] side_direction Object to be assigned
368
+ def side_direction=(side_direction)
369
+ validator = EnumAttributeValidator.new('String', ['Left', 'Up', 'Down', 'Right'])
370
+ unless validator.valid?(side_direction)
371
+ fail ArgumentError, 'invalid value for "side_direction", must be one of #{validator.allowable_values}.'
372
+ end
373
+ @side_direction = side_direction
374
+ end
375
+
376
+ # Custom attribute writer method checking allowed values (enum).
377
+ # @param [Object] pattern Object to be assigned
378
+ def pattern=(pattern)
379
+ validator = EnumAttributeValidator.new('String', ['Diamond', 'Hexagon'])
380
+ unless validator.valid?(pattern)
381
+ fail ArgumentError, 'invalid value for "pattern", must be one of #{validator.allowable_values}.'
382
+ end
383
+ @pattern = pattern
384
+ end
385
+
386
+ # Custom attribute writer method checking allowed values (enum).
387
+ # @param [Object] left_right_direction Object to be assigned
388
+ def left_right_direction=(left_right_direction)
389
+ validator = EnumAttributeValidator.new('String', ['Left', 'Right'])
390
+ unless validator.valid?(left_right_direction)
391
+ fail ArgumentError, 'invalid value for "left_right_direction", must be one of #{validator.allowable_values}.'
392
+ end
393
+ @left_right_direction = left_right_direction
394
+ end
395
+
396
+ # Custom attribute writer method checking allowed values (enum).
397
+ # @param [Object] morph_type Object to be assigned
398
+ def morph_type=(morph_type)
399
+ validator = EnumAttributeValidator.new('String', ['ByObject', 'ByWord', 'ByChar'])
400
+ unless validator.valid?(morph_type)
401
+ fail ArgumentError, 'invalid value for "morph_type", must be one of #{validator.allowable_values}.'
402
+ end
403
+ @morph_type = morph_type
404
+ end
405
+
406
+ # Custom attribute writer method checking allowed values (enum).
407
+ # @param [Object] orientation_direction Object to be assigned
408
+ def orientation_direction=(orientation_direction)
409
+ validator = EnumAttributeValidator.new('String', ['Horizontal', 'Vertical'])
410
+ unless validator.valid?(orientation_direction)
411
+ fail ArgumentError, 'invalid value for "orientation_direction", must be one of #{validator.allowable_values}.'
412
+ end
413
+ @orientation_direction = orientation_direction
414
+ end
415
+
416
+ # Custom attribute writer method checking allowed values (enum).
417
+ # @param [Object] corner_and_center_direction Object to be assigned
418
+ def corner_and_center_direction=(corner_and_center_direction)
419
+ validator = EnumAttributeValidator.new('String', ['LeftDown', 'LeftUp', 'RightDown', 'RightUp', 'Center'])
420
+ unless validator.valid?(corner_and_center_direction)
421
+ fail ArgumentError, 'invalid value for "corner_and_center_direction", must be one of #{validator.allowable_values}.'
422
+ end
423
+ @corner_and_center_direction = corner_and_center_direction
424
+ end
425
+
426
+ # Custom attribute writer method checking allowed values (enum).
427
+ # @param [Object] shred_pattern Object to be assigned
428
+ def shred_pattern=(shred_pattern)
429
+ validator = EnumAttributeValidator.new('String', ['Strip', 'Rectangle'])
430
+ unless validator.valid?(shred_pattern)
431
+ fail ArgumentError, 'invalid value for "shred_pattern", must be one of #{validator.allowable_values}.'
432
+ end
433
+ @shred_pattern = shred_pattern
434
+ end
435
+
436
+ # Custom attribute writer method checking allowed values (enum).
437
+ # @param [Object] orientation Object to be assigned
438
+ def orientation=(orientation)
439
+ validator = EnumAttributeValidator.new('String', ['Horizontal', 'Vertical'])
440
+ unless validator.valid?(orientation)
441
+ fail ArgumentError, 'invalid value for "orientation", must be one of #{validator.allowable_values}.'
442
+ end
443
+ @orientation = orientation
444
+ end
445
+
446
+ # Checks equality by comparing each attribute.
447
+ # @param [Object] Object to be compared
448
+ def ==(o)
449
+ return true if self.equal?(o)
450
+ self.class == o.class &&
451
+ type == o.type &&
452
+ advance_after == o.advance_after &&
453
+ advance_after_time == o.advance_after_time &&
454
+ advance_on_click == o.advance_on_click &&
455
+ sound_is_built_in == o.sound_is_built_in &&
456
+ sound_loop == o.sound_loop &&
457
+ sound_mode == o.sound_mode &&
458
+ sound_name == o.sound_name &&
459
+ speed == o.speed &&
460
+ corner_direction == o.corner_direction &&
461
+ eight_direction == o.eight_direction &&
462
+ in_out_direction == o.in_out_direction &&
463
+ has_bounce == o.has_bounce &&
464
+ side_direction == o.side_direction &&
465
+ pattern == o.pattern &&
466
+ left_right_direction == o.left_right_direction &&
467
+ morph_type == o.morph_type &&
468
+ from_black == o.from_black &&
469
+ orientation_direction == o.orientation_direction &&
470
+ through_black == o.through_black &&
471
+ corner_and_center_direction == o.corner_and_center_direction &&
472
+ shred_pattern == o.shred_pattern &&
473
+ orientation == o.orientation &&
474
+ spokes == o.spokes
475
+ end
476
+
477
+ # @see the `==` method
478
+ # @param [Object] Object to be compared
479
+ def eql?(o)
480
+ self == o
481
+ end
482
+
483
+ # Calculates hash code according to all attributes.
484
+ # @return [Fixnum] Hash code
485
+ def hash
486
+ [type, advance_after, advance_after_time, advance_on_click, sound_is_built_in, sound_loop, sound_mode, sound_name, speed, corner_direction, eight_direction, in_out_direction, has_bounce, side_direction, pattern, left_right_direction, morph_type, from_black, orientation_direction, through_black, corner_and_center_direction, shred_pattern, orientation, spokes].hash
487
+ end
488
+ end
489
+ end