aspose_slides_cloud 21.12.1 → 22.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (67) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +9 -40
  3. data/TestData/test-unprotected.pptx +0 -0
  4. data/TestData/test.pptx +0 -0
  5. data/aspose_slides_cloud.gemspec +1 -1
  6. data/lib/aspose_slides_cloud/api/slides_api.rb +442 -30
  7. data/lib/aspose_slides_cloud/api_client.rb +1 -1
  8. data/lib/aspose_slides_cloud/configuration.rb +1 -1
  9. data/lib/aspose_slides_cloud/models/accent_element.rb +239 -0
  10. data/lib/aspose_slides_cloud/models/arc_to_path_segment.rb +279 -0
  11. data/lib/aspose_slides_cloud/models/array_element.rb +305 -0
  12. data/lib/aspose_slides_cloud/models/audio_frame.rb +26 -4
  13. data/lib/aspose_slides_cloud/models/bar_element.rb +251 -0
  14. data/lib/aspose_slides_cloud/models/block_element.rb +231 -0
  15. data/lib/aspose_slides_cloud/models/border_box_element.rb +309 -0
  16. data/lib/aspose_slides_cloud/models/box_element.rb +279 -0
  17. data/lib/aspose_slides_cloud/models/chart.rb +3 -1
  18. data/lib/aspose_slides_cloud/models/close_path_segment.rb +219 -0
  19. data/lib/aspose_slides_cloud/models/connector.rb +3 -1
  20. data/lib/aspose_slides_cloud/models/cubic_bezier_to_path_segment.rb +309 -0
  21. data/lib/aspose_slides_cloud/models/delimiter_element.rb +293 -0
  22. data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
  23. data/lib/aspose_slides_cloud/models/fraction_element.rb +261 -0
  24. data/lib/aspose_slides_cloud/models/function_element.rb +239 -0
  25. data/lib/aspose_slides_cloud/models/geometry_path.rb +263 -0
  26. data/lib/aspose_slides_cloud/models/geometry_paths.rb +209 -0
  27. data/lib/aspose_slides_cloud/models/geometry_shape.rb +3 -1
  28. data/lib/aspose_slides_cloud/models/gif_export_options.rb +230 -0
  29. data/lib/aspose_slides_cloud/models/graphical_object.rb +3 -1
  30. data/lib/aspose_slides_cloud/models/group_shape.rb +3 -1
  31. data/lib/aspose_slides_cloud/models/grouping_character_element.rb +283 -0
  32. data/lib/aspose_slides_cloud/models/hyperlink.rb +348 -0
  33. data/lib/aspose_slides_cloud/models/left_sub_superscript_element.rb +249 -0
  34. data/lib/aspose_slides_cloud/models/limit_element.rb +249 -0
  35. data/lib/aspose_slides_cloud/models/line_to_path_segment.rb +249 -0
  36. data/lib/aspose_slides_cloud/models/math_element.rb +240 -0
  37. data/lib/aspose_slides_cloud/models/math_paragraph.rb +253 -0
  38. data/lib/aspose_slides_cloud/models/matrix_element.rb +337 -0
  39. data/lib/aspose_slides_cloud/models/move_to_path_segment.rb +249 -0
  40. data/lib/aspose_slides_cloud/models/nary_operator_element.rb +311 -0
  41. data/lib/aspose_slides_cloud/models/ole_object_frame.rb +3 -1
  42. data/lib/aspose_slides_cloud/models/path_segment.rb +240 -0
  43. data/lib/aspose_slides_cloud/models/picture_frame.rb +3 -1
  44. data/lib/aspose_slides_cloud/models/portion.rb +32 -2
  45. data/lib/aspose_slides_cloud/models/quadratic_bezier_to_path_segment.rb +279 -0
  46. data/lib/aspose_slides_cloud/models/radical_element.rb +249 -0
  47. data/lib/aspose_slides_cloud/models/right_sub_superscript_element.rb +259 -0
  48. data/lib/aspose_slides_cloud/models/save.rb +2 -2
  49. data/lib/aspose_slides_cloud/models/save_slide.rb +2 -2
  50. data/lib/aspose_slides_cloud/models/shape.rb +3 -1
  51. data/lib/aspose_slides_cloud/models/shape_base.rb +21 -1
  52. data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
  53. data/lib/aspose_slides_cloud/models/smart_art.rb +3 -1
  54. data/lib/aspose_slides_cloud/models/smart_art_shape.rb +3 -1
  55. data/lib/aspose_slides_cloud/models/subscript_element.rb +239 -0
  56. data/lib/aspose_slides_cloud/models/superscript_element.rb +239 -0
  57. data/lib/aspose_slides_cloud/models/table.rb +3 -1
  58. data/lib/aspose_slides_cloud/models/text_element.rb +229 -0
  59. data/lib/aspose_slides_cloud/models/video_frame.rb +5 -3
  60. data/lib/aspose_slides_cloud/models/xaml_export_options.rb +210 -0
  61. data/lib/aspose_slides_cloud/type_registry.rb +72 -0
  62. data/lib/aspose_slides_cloud/version.rb +1 -1
  63. data/lib/aspose_slides_cloud.rb +33 -0
  64. data/spec/api/slides_api_spec.rb +1203 -4
  65. data/spec/spec_utils.rb +7 -1
  66. data/testRules.json +9 -0
  67. metadata +39 -6
@@ -0,0 +1,311 @@
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
+ # Specifies an N-ary mathematical object, such as Summation and Integral.
27
+ class NaryOperatorElement < MathElement
28
+ # Base argument
29
+ attr_accessor :base
30
+
31
+ # Subscript argument
32
+ attr_accessor :subscript
33
+
34
+ # Superscript argument
35
+ attr_accessor :superscript
36
+
37
+ # Nary Operator Character
38
+ attr_accessor :operator
39
+
40
+ # The location of limits (subscript and superscript)
41
+ attr_accessor :limit_location
42
+
43
+ # Operator Character grows vertically to match its operand height
44
+ attr_accessor :grow_to_match_operand_height
45
+
46
+ # Hide Subscript
47
+ attr_accessor :hide_subscript
48
+
49
+ # Hide Superscript
50
+ attr_accessor :hide_superscript
51
+
52
+ class EnumAttributeValidator
53
+ attr_reader :datatype
54
+ attr_reader :allowable_values
55
+
56
+ def initialize(datatype, allowable_values)
57
+ @allowable_values = allowable_values.map do |value|
58
+ case datatype.to_s
59
+ when /Integer/i
60
+ value.to_i
61
+ when /Float/i
62
+ value.to_f
63
+ else
64
+ value
65
+ end
66
+ end
67
+ end
68
+
69
+ def valid?(value)
70
+ !value || allowable_values.any?{ |s| s.casecmp(value) == 0 }
71
+ end
72
+ end
73
+
74
+ # Attribute mapping from ruby-style variable name to JSON key.
75
+ def self.attribute_map
76
+ super.merge({
77
+ :'base' => :'Base',
78
+ :'subscript' => :'Subscript',
79
+ :'superscript' => :'Superscript',
80
+ :'operator' => :'Operator',
81
+ :'limit_location' => :'LimitLocation',
82
+ :'grow_to_match_operand_height' => :'GrowToMatchOperandHeight',
83
+ :'hide_subscript' => :'HideSubscript',
84
+ :'hide_superscript' => :'HideSuperscript',
85
+ })
86
+ end
87
+
88
+ # Attribute type mapping.
89
+ def self.swagger_types
90
+ super.merge({
91
+ :'base' => :'MathElement',
92
+ :'subscript' => :'MathElement',
93
+ :'superscript' => :'MathElement',
94
+ :'operator' => :'String',
95
+ :'limit_location' => :'String',
96
+ :'grow_to_match_operand_height' => :'BOOLEAN',
97
+ :'hide_subscript' => :'BOOLEAN',
98
+ :'hide_superscript' => :'BOOLEAN',
99
+ })
100
+ end
101
+
102
+ # Initializes the object
103
+ # @param [Hash] attributes Model attributes in the form of hash
104
+ def initialize(attributes = {})
105
+ super
106
+
107
+ if attributes.has_key?(:'Base')
108
+ self.base = attributes[:'Base']
109
+ end
110
+
111
+ if attributes.has_key?(:'Subscript')
112
+ self.subscript = attributes[:'Subscript']
113
+ end
114
+
115
+ if attributes.has_key?(:'Superscript')
116
+ self.superscript = attributes[:'Superscript']
117
+ end
118
+
119
+ if attributes.has_key?(:'Operator')
120
+ self.operator = attributes[:'Operator']
121
+ end
122
+
123
+ if attributes.has_key?(:'LimitLocation')
124
+ self.limit_location = attributes[:'LimitLocation']
125
+ end
126
+
127
+ if attributes.has_key?(:'GrowToMatchOperandHeight')
128
+ self.grow_to_match_operand_height = attributes[:'GrowToMatchOperandHeight']
129
+ end
130
+
131
+ if attributes.has_key?(:'HideSubscript')
132
+ self.hide_subscript = attributes[:'HideSubscript']
133
+ end
134
+
135
+ if attributes.has_key?(:'HideSuperscript')
136
+ self.hide_superscript = attributes[:'HideSuperscript']
137
+ end
138
+ self.type = "NaryOperator"
139
+ end
140
+
141
+ # Show invalid properties with the reasons. Usually used together with valid?
142
+ # @return Array for valid properties with the reasons
143
+ def list_invalid_properties
144
+ invalid_properties = super
145
+ invalid_properties
146
+ end
147
+
148
+ # Check to see if the all the properties in the model are valid
149
+ # @return true if the model is valid
150
+ def valid?
151
+ return false if !super
152
+ limit_location_validator = EnumAttributeValidator.new('String', ['NotDefined', 'UnderOver', 'SubscriptSuperscript'])
153
+ return false unless limit_location_validator.valid?(@limit_location)
154
+ true
155
+ end
156
+
157
+ # Custom attribute writer method checking allowed values (enum).
158
+ # @param [Object] limit_location Object to be assigned
159
+ def limit_location=(limit_location)
160
+ validator = EnumAttributeValidator.new('String', ['NotDefined', 'UnderOver', 'SubscriptSuperscript'])
161
+ unless validator.valid?(limit_location)
162
+ fail ArgumentError, 'invalid value for "limit_location", must be one of #{validator.allowable_values}.'
163
+ end
164
+ @limit_location = limit_location
165
+ end
166
+
167
+ # Checks equality by comparing each attribute.
168
+ # @param [Object] Object to be compared
169
+ def ==(o)
170
+ return true if self.equal?(o)
171
+ self.class == o.class &&
172
+ type == o.type &&
173
+ base == o.base &&
174
+ subscript == o.subscript &&
175
+ superscript == o.superscript &&
176
+ operator == o.operator &&
177
+ limit_location == o.limit_location &&
178
+ grow_to_match_operand_height == o.grow_to_match_operand_height &&
179
+ hide_subscript == o.hide_subscript &&
180
+ hide_superscript == o.hide_superscript
181
+ end
182
+
183
+ # @see the `==` method
184
+ # @param [Object] Object to be compared
185
+ def eql?(o)
186
+ self == o
187
+ end
188
+
189
+ # Calculates hash code according to all attributes.
190
+ # @return [Fixnum] Hash code
191
+ def hash
192
+ [type, base, subscript, superscript, operator, limit_location, grow_to_match_operand_height, hide_subscript, hide_superscript].hash
193
+ end
194
+
195
+ # Builds the object from hash
196
+ # @param [Hash] attributes Model attributes in the form of hash
197
+ # @return [Object] Returns the model itself
198
+ def build_from_hash(attributes)
199
+ return nil unless attributes.is_a?(Hash)
200
+ self.class.swagger_types.each_pair do |key, type|
201
+ mapKey = self.class.attribute_map[key]
202
+ if !mapKey.nil?
203
+ val = attributes[mapKey]
204
+ if val.nil?
205
+ mapKeyString = mapKey.to_s
206
+ mapKeyString[0] = mapKeyString[0].downcase
207
+ mapKey = mapKeyString.to_sym
208
+ val = attributes[mapKey]
209
+ end
210
+ if !val.nil?
211
+ if type =~ /\AArray<(.*)>/i
212
+ # check to ensure the input is an array given that the the attribute
213
+ # is documented as an array but the input is not
214
+ if val.is_a?(Array)
215
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
216
+ end
217
+ else
218
+ self.send("#{key}=", _deserialize(type, val))
219
+ end
220
+ end
221
+ end
222
+ end
223
+
224
+ self
225
+ end
226
+
227
+ # Deserializes the data based on type
228
+ # @param string type Data type
229
+ # @param string value Value to be deserialized
230
+ # @return [Object] Deserialized data
231
+ def _deserialize(type, value)
232
+ case type.to_sym
233
+ when :DateTime
234
+ DateTime.parse(value)
235
+ when :Date
236
+ Date.parse(value)
237
+ when :String
238
+ value.to_s
239
+ when :Integer
240
+ value.to_i
241
+ when :Float
242
+ value.to_f
243
+ when :BOOLEAN
244
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
245
+ true
246
+ else
247
+ false
248
+ end
249
+ when :Object
250
+ # generic object (usually a Hash), return directly
251
+ value
252
+ when /\AArray<(?<inner_type>.+)>\z/
253
+ inner_type = Regexp.last_match[:inner_type]
254
+ value.map { |v| _deserialize(inner_type, v) }
255
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
256
+ k_type = Regexp.last_match[:k_type]
257
+ v_type = Regexp.last_match[:v_type]
258
+ {}.tap do |hash|
259
+ value.each do |k, v|
260
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
261
+ end
262
+ end
263
+ else # model
264
+ temp_model = AsposeSlidesCloud.const_get(type).new
265
+ temp_model.build_from_hash(value)
266
+ end
267
+ end
268
+
269
+ # Returns the string representation of the object
270
+ # @return [String] String presentation of the object
271
+ def to_s
272
+ to_hash.to_s
273
+ end
274
+
275
+ # to_body is an alias to to_hash (backward compatibility)
276
+ # @return [Hash] Returns the object in the form of hash
277
+ def to_body
278
+ to_hash
279
+ end
280
+
281
+ # Returns the object in the form of hash
282
+ # @return [Hash] Returns the object in the form of hash
283
+ def to_hash
284
+ hash = {}
285
+ self.class.attribute_map.each_pair do |attr, param|
286
+ value = self.send(attr)
287
+ next if value.nil?
288
+ hash[param] = _to_hash(value)
289
+ end
290
+ hash
291
+ end
292
+
293
+ # Outputs non-array value in the form of hash
294
+ # For object, use to_hash. Otherwise, just return the value
295
+ # @param [Object] value Any valid value
296
+ # @return [Hash] Returns the value in the form of hash
297
+ def _to_hash(value)
298
+ if value.is_a?(Array)
299
+ value.compact.map { |v| _to_hash(v) }
300
+ elsif value.is_a?(Hash)
301
+ {}.tap do |hash|
302
+ value.each { |k, v| hash[k] = _to_hash(v) }
303
+ end
304
+ elsif value.respond_to? :to_hash
305
+ value.to_hash
306
+ else
307
+ value
308
+ end
309
+ end
310
+ end
311
+ end
@@ -124,6 +124,8 @@ module AsposeSlidesCloud
124
124
  effect_format == o.effect_format &&
125
125
  three_d_format == o.three_d_format &&
126
126
  line_format == o.line_format &&
127
+ hyperlink_click == o.hyperlink_click &&
128
+ hyperlink_mouse_over == o.hyperlink_mouse_over &&
127
129
  type == o.type &&
128
130
  is_object_icon == o.is_object_icon &&
129
131
  substitute_picture_title == o.substitute_picture_title
@@ -138,7 +140,7 @@ module AsposeSlidesCloud
138
140
  # Calculates hash code according to all attributes.
139
141
  # @return [Fixnum] Hash code
140
142
  def hash
141
- [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, three_d_format, line_format, type, is_object_icon, substitute_picture_title].hash
143
+ [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, three_d_format, line_format, hyperlink_click, hyperlink_mouse_over, type, is_object_icon, substitute_picture_title].hash
142
144
  end
143
145
 
144
146
  # Builds the object from hash
@@ -0,0 +1,240 @@
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 segment of geometry path
27
+ class PathSegment
28
+ attr_accessor :type
29
+
30
+ class EnumAttributeValidator
31
+ attr_reader :datatype
32
+ attr_reader :allowable_values
33
+
34
+ def initialize(datatype, allowable_values)
35
+ @allowable_values = allowable_values.map do |value|
36
+ case datatype.to_s
37
+ when /Integer/i
38
+ value.to_i
39
+ when /Float/i
40
+ value.to_f
41
+ else
42
+ value
43
+ end
44
+ end
45
+ end
46
+
47
+ def valid?(value)
48
+ !value || allowable_values.any?{ |s| s.casecmp(value) == 0 }
49
+ end
50
+ end
51
+
52
+ # Attribute mapping from ruby-style variable name to JSON key.
53
+ def self.attribute_map
54
+ {
55
+ :'type' => :'Type',
56
+ }
57
+ end
58
+
59
+ # Attribute type mapping.
60
+ def self.swagger_types
61
+ {
62
+ :'type' => :'String',
63
+ }
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ return unless attributes.is_a?(Hash)
70
+
71
+ # convert string to symbol for hash key
72
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
73
+
74
+ if attributes.has_key?(:'Type')
75
+ self.type = attributes[:'Type']
76
+ end
77
+ end
78
+
79
+ # Show invalid properties with the reasons. Usually used together with valid?
80
+ # @return Array for valid properties with the reasons
81
+ def list_invalid_properties
82
+ invalid_properties = Array.new
83
+ invalid_properties
84
+ end
85
+
86
+ # Check to see if the all the properties in the model are valid
87
+ # @return true if the model is valid
88
+ def valid?
89
+ type_validator = EnumAttributeValidator.new('String', ['Close', 'MoveTo', 'LineTo', 'ArcTo', 'QuadBezierTo', 'CubicBezierTo'])
90
+ return false unless type_validator.valid?(@type)
91
+ true
92
+ end
93
+
94
+ # Custom attribute writer method checking allowed values (enum).
95
+ # @param [Object] type Object to be assigned
96
+ def type=(type)
97
+ validator = EnumAttributeValidator.new('String', ['Close', 'MoveTo', 'LineTo', 'ArcTo', 'QuadBezierTo', 'CubicBezierTo'])
98
+ unless validator.valid?(type)
99
+ fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
100
+ end
101
+ @type = type
102
+ end
103
+
104
+ # Checks equality by comparing each attribute.
105
+ # @param [Object] Object to be compared
106
+ def ==(o)
107
+ return true if self.equal?(o)
108
+ self.class == o.class &&
109
+ type == o.type
110
+ end
111
+
112
+ # @see the `==` method
113
+ # @param [Object] Object to be compared
114
+ def eql?(o)
115
+ self == o
116
+ end
117
+
118
+ # Calculates hash code according to all attributes.
119
+ # @return [Fixnum] Hash code
120
+ def hash
121
+ [type].hash
122
+ end
123
+
124
+ # Builds the object from hash
125
+ # @param [Hash] attributes Model attributes in the form of hash
126
+ # @return [Object] Returns the model itself
127
+ def build_from_hash(attributes)
128
+ return nil unless attributes.is_a?(Hash)
129
+ self.class.swagger_types.each_pair do |key, type|
130
+ mapKey = self.class.attribute_map[key]
131
+ if !mapKey.nil?
132
+ val = attributes[mapKey]
133
+ if val.nil?
134
+ mapKeyString = mapKey.to_s
135
+ mapKeyString[0] = mapKeyString[0].downcase
136
+ mapKey = mapKeyString.to_sym
137
+ val = attributes[mapKey]
138
+ end
139
+ if !val.nil?
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 val.is_a?(Array)
144
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
145
+ end
146
+ else
147
+ self.send("#{key}=", _deserialize(type, val))
148
+ end
149
+ end
150
+ end
151
+ end
152
+
153
+ self
154
+ end
155
+
156
+ # Deserializes the data based on type
157
+ # @param string type Data type
158
+ # @param string value Value to be deserialized
159
+ # @return [Object] Deserialized data
160
+ def _deserialize(type, value)
161
+ case type.to_sym
162
+ when :DateTime
163
+ DateTime.parse(value)
164
+ when :Date
165
+ Date.parse(value)
166
+ when :String
167
+ value.to_s
168
+ when :Integer
169
+ value.to_i
170
+ when :Float
171
+ value.to_f
172
+ when :BOOLEAN
173
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
174
+ true
175
+ else
176
+ false
177
+ end
178
+ when :Object
179
+ # generic object (usually a Hash), return directly
180
+ value
181
+ when /\AArray<(?<inner_type>.+)>\z/
182
+ inner_type = Regexp.last_match[:inner_type]
183
+ value.map { |v| _deserialize(inner_type, v) }
184
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
185
+ k_type = Regexp.last_match[:k_type]
186
+ v_type = Regexp.last_match[:v_type]
187
+ {}.tap do |hash|
188
+ value.each do |k, v|
189
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
190
+ end
191
+ end
192
+ else # model
193
+ temp_model = AsposeSlidesCloud.const_get(type).new
194
+ temp_model.build_from_hash(value)
195
+ end
196
+ end
197
+
198
+ # Returns the string representation of the object
199
+ # @return [String] String presentation of the object
200
+ def to_s
201
+ to_hash.to_s
202
+ end
203
+
204
+ # to_body is an alias to to_hash (backward compatibility)
205
+ # @return [Hash] Returns the object in the form of hash
206
+ def to_body
207
+ to_hash
208
+ end
209
+
210
+ # Returns the object in the form of hash
211
+ # @return [Hash] Returns the object in the form of hash
212
+ def to_hash
213
+ hash = {}
214
+ self.class.attribute_map.each_pair do |attr, param|
215
+ value = self.send(attr)
216
+ next if value.nil?
217
+ hash[param] = _to_hash(value)
218
+ end
219
+ hash
220
+ end
221
+
222
+ # Outputs non-array value in the form of hash
223
+ # For object, use to_hash. Otherwise, just return the value
224
+ # @param [Object] value Any valid value
225
+ # @return [Hash] Returns the value in the form of hash
226
+ def _to_hash(value)
227
+ if value.is_a?(Array)
228
+ value.compact.map { |v| _to_hash(v) }
229
+ elsif value.is_a?(Hash)
230
+ {}.tap do |hash|
231
+ value.each { |k, v| hash[k] = _to_hash(v) }
232
+ end
233
+ elsif value.respond_to? :to_hash
234
+ value.to_hash
235
+ else
236
+ value
237
+ end
238
+ end
239
+ end
240
+ end
@@ -110,6 +110,8 @@ module AsposeSlidesCloud
110
110
  effect_format == o.effect_format &&
111
111
  three_d_format == o.three_d_format &&
112
112
  line_format == o.line_format &&
113
+ hyperlink_click == o.hyperlink_click &&
114
+ hyperlink_mouse_over == o.hyperlink_mouse_over &&
113
115
  type == o.type &&
114
116
  shape_type == o.shape_type &&
115
117
  picture_fill_format == o.picture_fill_format
@@ -124,7 +126,7 @@ module AsposeSlidesCloud
124
126
  # Calculates hash code according to all attributes.
125
127
  # @return [Fixnum] Hash code
126
128
  def hash
127
- [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, three_d_format, line_format, type, shape_type, picture_fill_format].hash
129
+ [self_uri, alternate_links, name, width, height, alternative_text, alternative_text_title, hidden, x, y, z_order_position, shapes, fill_format, effect_format, three_d_format, line_format, hyperlink_click, hyperlink_mouse_over, type, shape_type, picture_fill_format].hash
128
130
  end
129
131
 
130
132
  # Builds the object from hash
@@ -28,6 +28,9 @@ module AsposeSlidesCloud
28
28
  # Text.
29
29
  attr_accessor :text
30
30
 
31
+ # Math paragraph.
32
+ attr_accessor :math_paragraph
33
+
31
34
  # True for bold font.
32
35
  attr_accessor :font_bold
33
36
 
@@ -100,6 +103,12 @@ module AsposeSlidesCloud
100
103
  # Underline line format.
101
104
  attr_accessor :underline_line_format
102
105
 
106
+ # Hyperlink defined for mouse click.
107
+ attr_accessor :hyperlink_click
108
+
109
+ # Hyperlink defined for mouse over.
110
+ attr_accessor :hyperlink_mouse_over
111
+
103
112
  class EnumAttributeValidator
104
113
  attr_reader :datatype
105
114
  attr_reader :allowable_values
@@ -126,6 +135,7 @@ module AsposeSlidesCloud
126
135
  def self.attribute_map
127
136
  super.merge({
128
137
  :'text' => :'Text',
138
+ :'math_paragraph' => :'MathParagraph',
129
139
  :'font_bold' => :'FontBold',
130
140
  :'font_italic' => :'FontItalic',
131
141
  :'font_underline' => :'FontUnderline',
@@ -150,6 +160,8 @@ module AsposeSlidesCloud
150
160
  :'line_format' => :'LineFormat',
151
161
  :'underline_fill_format' => :'UnderlineFillFormat',
152
162
  :'underline_line_format' => :'UnderlineLineFormat',
163
+ :'hyperlink_click' => :'HyperlinkClick',
164
+ :'hyperlink_mouse_over' => :'HyperlinkMouseOver',
153
165
  })
154
166
  end
155
167
 
@@ -157,6 +169,7 @@ module AsposeSlidesCloud
157
169
  def self.swagger_types
158
170
  super.merge({
159
171
  :'text' => :'String',
172
+ :'math_paragraph' => :'MathParagraph',
160
173
  :'font_bold' => :'String',
161
174
  :'font_italic' => :'String',
162
175
  :'font_underline' => :'String',
@@ -181,6 +194,8 @@ module AsposeSlidesCloud
181
194
  :'line_format' => :'LineFormat',
182
195
  :'underline_fill_format' => :'FillFormat',
183
196
  :'underline_line_format' => :'LineFormat',
197
+ :'hyperlink_click' => :'Hyperlink',
198
+ :'hyperlink_mouse_over' => :'Hyperlink',
184
199
  })
185
200
  end
186
201
 
@@ -193,6 +208,10 @@ module AsposeSlidesCloud
193
208
  self.text = attributes[:'Text']
194
209
  end
195
210
 
211
+ if attributes.has_key?(:'MathParagraph')
212
+ self.math_paragraph = attributes[:'MathParagraph']
213
+ end
214
+
196
215
  if attributes.has_key?(:'FontBold')
197
216
  self.font_bold = attributes[:'FontBold']
198
217
  end
@@ -288,6 +307,14 @@ module AsposeSlidesCloud
288
307
  if attributes.has_key?(:'UnderlineLineFormat')
289
308
  self.underline_line_format = attributes[:'UnderlineLineFormat']
290
309
  end
310
+
311
+ if attributes.has_key?(:'HyperlinkClick')
312
+ self.hyperlink_click = attributes[:'HyperlinkClick']
313
+ end
314
+
315
+ if attributes.has_key?(:'HyperlinkMouseOver')
316
+ self.hyperlink_mouse_over = attributes[:'HyperlinkMouseOver']
317
+ end
291
318
  end
292
319
 
293
320
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -432,6 +459,7 @@ module AsposeSlidesCloud
432
459
  self_uri == o.self_uri &&
433
460
  alternate_links == o.alternate_links &&
434
461
  text == o.text &&
462
+ math_paragraph == o.math_paragraph &&
435
463
  font_bold == o.font_bold &&
436
464
  font_italic == o.font_italic &&
437
465
  font_underline == o.font_underline &&
@@ -455,7 +483,9 @@ module AsposeSlidesCloud
455
483
  effect_format == o.effect_format &&
456
484
  line_format == o.line_format &&
457
485
  underline_fill_format == o.underline_fill_format &&
458
- underline_line_format == o.underline_line_format
486
+ underline_line_format == o.underline_line_format &&
487
+ hyperlink_click == o.hyperlink_click &&
488
+ hyperlink_mouse_over == o.hyperlink_mouse_over
459
489
  end
460
490
 
461
491
  # @see the `==` method
@@ -467,7 +497,7 @@ module AsposeSlidesCloud
467
497
  # Calculates hash code according to all attributes.
468
498
  # @return [Fixnum] Hash code
469
499
  def hash
470
- [self_uri, alternate_links, text, font_bold, font_italic, font_underline, strikethrough_type, text_cap_type, escapement, spacing, font_color, highlight_color, font_height, normalise_height, proof_disabled, smart_tag_clean, kerning_minimal_size, kumimoji, language_id, alternative_language_id, is_hard_underline_fill, is_hard_underline_line, fill_format, effect_format, line_format, underline_fill_format, underline_line_format].hash
500
+ [self_uri, alternate_links, text, math_paragraph, font_bold, font_italic, font_underline, strikethrough_type, text_cap_type, escapement, spacing, font_color, highlight_color, font_height, normalise_height, proof_disabled, smart_tag_clean, kerning_minimal_size, kumimoji, language_id, alternative_language_id, is_hard_underline_fill, is_hard_underline_line, fill_format, effect_format, line_format, underline_fill_format, underline_line_format, hyperlink_click, hyperlink_mouse_over].hash
471
501
  end
472
502
 
473
503
  # Builds the object from hash