aspose_slides_cloud 20.5.0 → 20.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (171) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -3
  3. data/TestData/ChartTest.pptx +0 -0
  4. data/TestData/Sections.pptx +0 -0
  5. data/lib/aspose_slides_cloud.rb +12 -5
  6. data/lib/aspose_slides_cloud/api/slides_api.rb +4571 -1683
  7. data/lib/aspose_slides_cloud/api/slides_api_requests.rb +1191 -185
  8. data/lib/aspose_slides_cloud/api_client.rb +30 -23
  9. data/lib/aspose_slides_cloud/configuration.rb +7 -2
  10. data/lib/aspose_slides_cloud/models/add_layout_slide.rb +31 -48
  11. data/lib/aspose_slides_cloud/models/add_master_slide.rb +31 -48
  12. data/lib/aspose_slides_cloud/models/add_shape.rb +31 -48
  13. data/lib/aspose_slides_cloud/models/add_slide.rb +31 -48
  14. data/lib/aspose_slides_cloud/models/api_info.rb +22 -10
  15. data/lib/aspose_slides_cloud/models/arrow_head_properties.rb +22 -10
  16. data/lib/aspose_slides_cloud/models/audio_frame.rb +32 -246
  17. data/lib/aspose_slides_cloud/models/axes.rb +22 -10
  18. data/lib/aspose_slides_cloud/models/axis.rb +22 -10
  19. data/lib/aspose_slides_cloud/models/base64_input_file.rb +31 -57
  20. data/lib/aspose_slides_cloud/models/blur_effect.rb +22 -10
  21. data/lib/aspose_slides_cloud/models/box_and_whisker_series.rb +31 -222
  22. data/lib/aspose_slides_cloud/models/bubble_chart_data_point.rb +30 -48
  23. data/lib/aspose_slides_cloud/models/bubble_series.rb +31 -211
  24. data/lib/aspose_slides_cloud/models/chart.rb +32 -220
  25. data/lib/aspose_slides_cloud/models/chart_category.rb +54 -20
  26. data/lib/aspose_slides_cloud/models/chart_title.rb +22 -10
  27. data/lib/aspose_slides_cloud/models/chart_wall.rb +22 -10
  28. data/lib/aspose_slides_cloud/models/color_scheme.rb +30 -40
  29. data/lib/aspose_slides_cloud/models/common_slide_view_properties.rb +22 -10
  30. data/lib/aspose_slides_cloud/models/connector.rb +32 -244
  31. data/lib/aspose_slides_cloud/models/custom_dash_pattern.rb +22 -10
  32. data/lib/aspose_slides_cloud/models/{resource_uri_element.rb → data_point.rb} +24 -22
  33. data/lib/aspose_slides_cloud/models/disc_usage.rb +22 -10
  34. data/lib/aspose_slides_cloud/models/document.rb +35 -45
  35. data/lib/aspose_slides_cloud/models/document_properties.rb +30 -40
  36. data/lib/aspose_slides_cloud/models/document_property.rb +30 -40
  37. data/lib/aspose_slides_cloud/models/document_replace_result.rb +30 -94
  38. data/lib/aspose_slides_cloud/models/effect.rb +22 -10
  39. data/lib/aspose_slides_cloud/models/effect_format.rb +22 -10
  40. data/lib/aspose_slides_cloud/models/entity_exists.rb +212 -0
  41. data/lib/aspose_slides_cloud/models/error.rb +22 -10
  42. data/lib/aspose_slides_cloud/models/error_details.rb +22 -10
  43. data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
  44. data/lib/aspose_slides_cloud/models/export_options.rb +33 -11
  45. data/lib/aspose_slides_cloud/models/file_version.rb +30 -75
  46. data/lib/aspose_slides_cloud/models/file_versions.rb +22 -10
  47. data/lib/aspose_slides_cloud/models/files_list.rb +22 -10
  48. data/lib/aspose_slides_cloud/models/files_upload_result.rb +22 -10
  49. data/lib/aspose_slides_cloud/models/fill_format.rb +22 -10
  50. data/lib/aspose_slides_cloud/models/fill_overlay_effect.rb +22 -10
  51. data/lib/aspose_slides_cloud/models/font_scheme.rb +30 -40
  52. data/lib/aspose_slides_cloud/models/font_set.rb +22 -10
  53. data/lib/aspose_slides_cloud/models/format_scheme.rb +30 -40
  54. data/lib/aspose_slides_cloud/models/geometry_shape.rb +33 -212
  55. data/lib/aspose_slides_cloud/models/glow_effect.rb +22 -10
  56. data/lib/aspose_slides_cloud/models/gradient_fill.rb +31 -48
  57. data/lib/aspose_slides_cloud/models/gradient_fill_stop.rb +22 -10
  58. data/lib/aspose_slides_cloud/models/graphical_object.rb +31 -219
  59. data/lib/aspose_slides_cloud/models/group_shape.rb +31 -219
  60. data/lib/aspose_slides_cloud/models/header_footer.rb +247 -0
  61. data/lib/aspose_slides_cloud/models/html_export_options.rb +33 -32
  62. data/lib/aspose_slides_cloud/models/i_shape_export_options.rb +22 -20
  63. data/lib/aspose_slides_cloud/models/image.rb +30 -40
  64. data/lib/aspose_slides_cloud/models/image_export_options.rb +33 -32
  65. data/lib/aspose_slides_cloud/models/images.rb +30 -40
  66. data/lib/aspose_slides_cloud/models/inner_shadow_effect.rb +22 -10
  67. data/lib/aspose_slides_cloud/models/input.rb +22 -10
  68. data/lib/aspose_slides_cloud/models/input_file.rb +22 -10
  69. data/lib/aspose_slides_cloud/models/interactive_sequence.rb +22 -10
  70. data/lib/aspose_slides_cloud/models/layout_slide.rb +31 -41
  71. data/lib/aspose_slides_cloud/models/layout_slides.rb +30 -40
  72. data/lib/aspose_slides_cloud/models/legend.rb +22 -10
  73. data/lib/aspose_slides_cloud/models/line_format.rb +22 -10
  74. data/lib/aspose_slides_cloud/models/master_slide.rb +31 -41
  75. data/lib/aspose_slides_cloud/models/master_slides.rb +30 -40
  76. data/lib/aspose_slides_cloud/models/merge.rb +31 -48
  77. data/lib/aspose_slides_cloud/models/merging_source.rb +22 -10
  78. data/lib/aspose_slides_cloud/models/no_fill.rb +29 -46
  79. data/lib/aspose_slides_cloud/models/normal_view_restored_properties.rb +22 -10
  80. data/lib/aspose_slides_cloud/models/notes_slide.rb +30 -40
  81. data/lib/aspose_slides_cloud/models/notes_slide_header_footer.rb +267 -0
  82. data/lib/aspose_slides_cloud/models/object_exist.rb +22 -10
  83. data/lib/aspose_slides_cloud/models/ole_object_frame.rb +32 -220
  84. data/lib/aspose_slides_cloud/models/one_value_chart_data_point.rb +30 -20
  85. data/lib/aspose_slides_cloud/models/one_value_series.rb +31 -211
  86. data/lib/aspose_slides_cloud/models/ordered_merge_request.rb +22 -10
  87. data/lib/aspose_slides_cloud/models/outer_shadow_effect.rb +22 -10
  88. data/lib/aspose_slides_cloud/models/output_file.rb +22 -10
  89. data/lib/aspose_slides_cloud/models/paragraph.rb +30 -40
  90. data/lib/aspose_slides_cloud/models/paragraphs.rb +30 -40
  91. data/lib/aspose_slides_cloud/models/path_input_file.rb +31 -57
  92. data/lib/aspose_slides_cloud/models/path_output_file.rb +31 -48
  93. data/lib/aspose_slides_cloud/models/pattern_fill.rb +31 -48
  94. data/lib/aspose_slides_cloud/models/pdf_export_options.rb +63 -35
  95. data/lib/aspose_slides_cloud/models/picture_fill.rb +32 -49
  96. data/lib/aspose_slides_cloud/models/picture_frame.rb +32 -246
  97. data/lib/aspose_slides_cloud/models/pipeline.rb +22 -10
  98. data/lib/aspose_slides_cloud/models/placeholder.rb +30 -40
  99. data/lib/aspose_slides_cloud/models/placeholders.rb +30 -40
  100. data/lib/aspose_slides_cloud/models/plot_area.rb +22 -10
  101. data/lib/aspose_slides_cloud/models/portion.rb +30 -40
  102. data/lib/aspose_slides_cloud/models/portions.rb +36 -46
  103. data/lib/aspose_slides_cloud/models/pptx_export_options.rb +33 -32
  104. data/lib/aspose_slides_cloud/models/presentation_to_merge.rb +22 -10
  105. data/lib/aspose_slides_cloud/models/presentations_merge_request.rb +22 -10
  106. data/lib/aspose_slides_cloud/models/preset_shadow_effect.rb +22 -10
  107. data/lib/aspose_slides_cloud/models/reflection_effect.rb +22 -10
  108. data/lib/aspose_slides_cloud/models/remove_shape.rb +31 -48
  109. data/lib/aspose_slides_cloud/models/remove_slide.rb +31 -48
  110. data/lib/aspose_slides_cloud/models/reorder_slide.rb +31 -48
  111. data/lib/aspose_slides_cloud/models/replace_text.rb +31 -48
  112. data/lib/aspose_slides_cloud/models/request_input_file.rb +31 -57
  113. data/lib/aspose_slides_cloud/models/reset_slide.rb +31 -48
  114. data/lib/aspose_slides_cloud/models/resource_base.rb +22 -10
  115. data/lib/aspose_slides_cloud/models/resource_uri.rb +22 -10
  116. data/lib/aspose_slides_cloud/models/response_output_file.rb +29 -46
  117. data/lib/aspose_slides_cloud/models/save.rb +33 -50
  118. data/lib/aspose_slides_cloud/models/save_shape.rb +31 -48
  119. data/lib/aspose_slides_cloud/models/save_slide.rb +33 -50
  120. data/lib/aspose_slides_cloud/models/scatter_chart_data_point.rb +30 -20
  121. data/lib/aspose_slides_cloud/models/scatter_series.rb +31 -211
  122. data/lib/aspose_slides_cloud/models/section.rb +234 -0
  123. data/lib/aspose_slides_cloud/models/sections.rb +209 -0
  124. data/lib/aspose_slides_cloud/models/series.rb +45 -12
  125. data/lib/aspose_slides_cloud/models/series_marker.rb +22 -10
  126. data/lib/aspose_slides_cloud/models/shape.rb +32 -244
  127. data/lib/aspose_slides_cloud/models/shape_base.rb +31 -62
  128. data/lib/aspose_slides_cloud/models/shape_image_export_options.rb +22 -10
  129. data/lib/aspose_slides_cloud/models/shapes.rb +30 -40
  130. data/lib/aspose_slides_cloud/models/slide.rb +37 -47
  131. data/lib/aspose_slides_cloud/models/slide_animation.rb +30 -40
  132. data/lib/aspose_slides_cloud/models/slide_background.rb +30 -40
  133. data/lib/aspose_slides_cloud/models/slide_comment.rb +22 -10
  134. data/lib/aspose_slides_cloud/models/slide_comments.rb +30 -40
  135. data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
  136. data/lib/aspose_slides_cloud/models/slide_replace_result.rb +30 -154
  137. data/lib/aspose_slides_cloud/models/slides.rb +30 -40
  138. data/lib/aspose_slides_cloud/models/smart_art.rb +32 -220
  139. data/lib/aspose_slides_cloud/models/smart_art_node.rb +23 -11
  140. data/lib/aspose_slides_cloud/models/smart_art_shape.rb +30 -217
  141. data/lib/aspose_slides_cloud/models/soft_edge_effect.rb +22 -10
  142. data/lib/aspose_slides_cloud/models/solid_fill.rb +31 -48
  143. data/lib/aspose_slides_cloud/models/split_document_result.rb +30 -40
  144. data/lib/aspose_slides_cloud/models/storage_exist.rb +22 -10
  145. data/lib/aspose_slides_cloud/models/storage_file.rb +22 -10
  146. data/lib/aspose_slides_cloud/models/svg_export_options.rb +33 -32
  147. data/lib/aspose_slides_cloud/models/swf_export_options.rb +33 -32
  148. data/lib/aspose_slides_cloud/models/table.rb +32 -220
  149. data/lib/aspose_slides_cloud/models/table_cell.rb +22 -10
  150. data/lib/aspose_slides_cloud/models/table_column.rb +22 -10
  151. data/lib/aspose_slides_cloud/models/table_row.rb +22 -10
  152. data/lib/aspose_slides_cloud/models/task.rb +22 -10
  153. data/lib/aspose_slides_cloud/models/text_item.rb +22 -10
  154. data/lib/aspose_slides_cloud/models/text_items.rb +30 -40
  155. data/lib/aspose_slides_cloud/models/theme.rb +32 -42
  156. data/lib/aspose_slides_cloud/models/tiff_export_options.rb +33 -32
  157. data/lib/aspose_slides_cloud/models/update_background.rb +31 -48
  158. data/lib/aspose_slides_cloud/models/update_shape.rb +31 -48
  159. data/lib/aspose_slides_cloud/models/video_frame.rb +32 -246
  160. data/lib/aspose_slides_cloud/models/view_properties.rb +30 -40
  161. data/lib/aspose_slides_cloud/models/waterfall_chart_data_point.rb +206 -0
  162. data/lib/aspose_slides_cloud/models/waterfall_series.rb +31 -222
  163. data/lib/aspose_slides_cloud/models/xps_export_options.rb +33 -32
  164. data/lib/aspose_slides_cloud/type_registry.rb +320 -0
  165. data/lib/aspose_slides_cloud/version.rb +1 -1
  166. data/spec/api/slides_api_spec.rb +25246 -14028
  167. data/spec/extra/extra_spec.rb +156 -22
  168. data/spec/spec_utils.rb +11 -4
  169. data/testConfig.json +2 -2
  170. data/testRules.json +172 -77
  171. metadata +12 -3
@@ -43,7 +43,7 @@ module AsposeSlidesCloud
43
43
  :'horizontal_axis' => :'HorizontalAxis',
44
44
  :'vertical_axis' => :'VerticalAxis',
45
45
  :'secondary_horizontal_axis' => :'SecondaryHorizontalAxis',
46
- :'secondary_vertical_axis' => :'SecondaryVerticalAxis'
46
+ :'secondary_vertical_axis' => :'SecondaryVerticalAxis',
47
47
  }
48
48
  end
49
49
 
@@ -53,7 +53,7 @@ module AsposeSlidesCloud
53
53
  :'horizontal_axis' => :'Axis',
54
54
  :'vertical_axis' => :'Axis',
55
55
  :'secondary_horizontal_axis' => :'Axis',
56
- :'secondary_vertical_axis' => :'Axis'
56
+ :'secondary_vertical_axis' => :'Axis',
57
57
  }
58
58
  end
59
59
 
@@ -124,15 +124,27 @@ module AsposeSlidesCloud
124
124
  def build_from_hash(attributes)
125
125
  return nil unless attributes.is_a?(Hash)
126
126
  self.class.swagger_types.each_pair do |key, type|
127
- if type =~ /\AArray<(.*)>/i
128
- # check to ensure the input is an array given that the the attribute
129
- # is documented as an array but the input is not
130
- if attributes[self.class.attribute_map[key]].is_a?(Array)
131
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
127
+ mapKey = self.class.attribute_map[key]
128
+ if !mapKey.nil?
129
+ val = attributes[mapKey]
130
+ if val.nil?
131
+ mapKeyString = mapKey.to_s
132
+ mapKeyString[0] = mapKeyString[0].downcase
133
+ mapKey = mapKeyString.to_sym
134
+ val = attributes[mapKey]
132
135
  end
133
- elsif !attributes[self.class.attribute_map[key]].nil?
134
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
135
- end # or else data not found in attributes(hash), not an issue as the data can be optional
136
+ if !val.nil?
137
+ if type =~ /\AArray<(.*)>/i
138
+ # check to ensure the input is an array given that the the attribute
139
+ # is documented as an array but the input is not
140
+ if val.is_a?(Array)
141
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
142
+ end
143
+ else
144
+ self.send("#{key}=", _deserialize(type, val))
145
+ end
146
+ end
147
+ end
136
148
  end
137
149
 
138
150
  self
@@ -193,7 +193,7 @@ module AsposeSlidesCloud
193
193
  :'tick_label_rotation_angle' => :'TickLabelRotationAngle',
194
194
  :'fill_format' => :'FillFormat',
195
195
  :'effect_format' => :'EffectFormat',
196
- :'line_format' => :'LineFormat'
196
+ :'line_format' => :'LineFormat',
197
197
  }
198
198
  end
199
199
 
@@ -235,7 +235,7 @@ module AsposeSlidesCloud
235
235
  :'tick_label_rotation_angle' => :'Float',
236
236
  :'fill_format' => :'FillFormat',
237
237
  :'effect_format' => :'EffectFormat',
238
- :'line_format' => :'LineFormat'
238
+ :'line_format' => :'LineFormat',
239
239
  }
240
240
  end
241
241
 
@@ -586,15 +586,27 @@ module AsposeSlidesCloud
586
586
  def build_from_hash(attributes)
587
587
  return nil unless attributes.is_a?(Hash)
588
588
  self.class.swagger_types.each_pair do |key, type|
589
- if type =~ /\AArray<(.*)>/i
590
- # check to ensure the input is an array given that the the attribute
591
- # is documented as an array but the input is not
592
- if attributes[self.class.attribute_map[key]].is_a?(Array)
593
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
589
+ mapKey = self.class.attribute_map[key]
590
+ if !mapKey.nil?
591
+ val = attributes[mapKey]
592
+ if val.nil?
593
+ mapKeyString = mapKey.to_s
594
+ mapKeyString[0] = mapKeyString[0].downcase
595
+ mapKey = mapKeyString.to_sym
596
+ val = attributes[mapKey]
594
597
  end
595
- elsif !attributes[self.class.attribute_map[key]].nil?
596
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
597
- end # or else data not found in attributes(hash), not an issue as the data can be optional
598
+ if !val.nil?
599
+ if type =~ /\AArray<(.*)>/i
600
+ # check to ensure the input is an array given that the the attribute
601
+ # is documented as an array but the input is not
602
+ if val.is_a?(Array)
603
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
604
+ end
605
+ else
606
+ self.send("#{key}=", _deserialize(type, val))
607
+ end
608
+ end
609
+ end
598
610
  end
599
611
 
600
612
  self
@@ -24,13 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # Represents base64 inline encoded file.
27
- class Base64InputFile
28
- # Get or sets password to open document.
29
- attr_accessor :password
30
-
31
- # File type.
32
- attr_accessor :type
33
-
27
+ class Base64InputFile < InputFile
34
28
  # Get or sets base64 data.
35
29
  attr_accessor :data
36
30
 
@@ -58,75 +52,43 @@ module AsposeSlidesCloud
58
52
 
59
53
  # Attribute mapping from ruby-style variable name to JSON key.
60
54
  def self.attribute_map
61
- {
62
- :'password' => :'Password',
63
- :'type' => :'Type',
64
- :'data' => :'Data'
65
- }
55
+ super.merge({
56
+ :'data' => :'Data',
57
+ })
66
58
  end
67
59
 
68
60
  # Attribute type mapping.
69
61
  def self.swagger_types
70
- {
71
- :'password' => :'String',
72
- :'type' => :'String',
73
- :'data' => :'String'
74
- }
62
+ super.merge({
63
+ :'data' => :'String',
64
+ })
75
65
  end
76
66
 
77
67
  # Initializes the object
78
68
  # @param [Hash] attributes Model attributes in the form of hash
79
69
  def initialize(attributes = {})
80
- return unless attributes.is_a?(Hash)
81
-
82
- # convert string to symbol for hash key
83
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
84
-
85
- if attributes.has_key?(:'Password')
86
- self.password = attributes[:'Password']
87
- end
88
-
89
- if attributes.has_key?(:'Type')
90
- self.type = attributes[:'Type']
91
- else
92
- self.type = "Base64"
93
- end
70
+ super
94
71
 
95
72
  if attributes.has_key?(:'Data')
96
73
  self.data = attributes[:'Data']
97
74
  end
75
+ self.type = "Base64"
98
76
  end
99
77
 
100
78
  # Show invalid properties with the reasons. Usually used together with valid?
101
79
  # @return Array for valid properties with the reasons
102
80
  def list_invalid_properties
103
- invalid_properties = Array.new
104
- if @type.nil?
105
- invalid_properties.push('invalid value for "type", type cannot be nil.')
106
- end
107
-
81
+ invalid_properties = super
108
82
  invalid_properties
109
83
  end
110
84
 
111
85
  # Check to see if the all the properties in the model are valid
112
86
  # @return true if the model is valid
113
87
  def valid?
114
- return false if @type.nil?
115
- type_validator = EnumAttributeValidator.new('String', ['Path', 'Request', 'Base64'])
116
- return false unless type_validator.valid?(@type)
88
+ return false if !super
117
89
  true
118
90
  end
119
91
 
120
- # Custom attribute writer method checking allowed values (enum).
121
- # @param [Object] type Object to be assigned
122
- def type=(type)
123
- validator = EnumAttributeValidator.new('String', ['Path', 'Request', 'Base64'])
124
- unless validator.valid?(type)
125
- fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
126
- end
127
- @type = type
128
- end
129
-
130
92
  # Checks equality by comparing each attribute.
131
93
  # @param [Object] Object to be compared
132
94
  def ==(o)
@@ -155,15 +117,27 @@ module AsposeSlidesCloud
155
117
  def build_from_hash(attributes)
156
118
  return nil unless attributes.is_a?(Hash)
157
119
  self.class.swagger_types.each_pair do |key, type|
158
- if type =~ /\AArray<(.*)>/i
159
- # check to ensure the input is an array given that the the attribute
160
- # is documented as an array but the input is not
161
- if attributes[self.class.attribute_map[key]].is_a?(Array)
162
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
120
+ mapKey = self.class.attribute_map[key]
121
+ if !mapKey.nil?
122
+ val = attributes[mapKey]
123
+ if val.nil?
124
+ mapKeyString = mapKey.to_s
125
+ mapKeyString[0] = mapKeyString[0].downcase
126
+ mapKey = mapKeyString.to_sym
127
+ val = attributes[mapKey]
128
+ end
129
+ if !val.nil?
130
+ if type =~ /\AArray<(.*)>/i
131
+ # check to ensure the input is an array given that the the attribute
132
+ # is documented as an array but the input is not
133
+ if val.is_a?(Array)
134
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
135
+ end
136
+ else
137
+ self.send("#{key}=", _deserialize(type, val))
138
+ end
163
139
  end
164
- elsif !attributes[self.class.attribute_map[key]].nil?
165
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
166
- end # or else data not found in attributes(hash), not an issue as the data can be optional
140
+ end
167
141
  end
168
142
 
169
143
  self
@@ -35,7 +35,7 @@ module AsposeSlidesCloud
35
35
  def self.attribute_map
36
36
  {
37
37
  :'radius' => :'Radius',
38
- :'grow' => :'Grow'
38
+ :'grow' => :'Grow',
39
39
  }
40
40
  end
41
41
 
@@ -43,7 +43,7 @@ module AsposeSlidesCloud
43
43
  def self.swagger_types
44
44
  {
45
45
  :'radius' => :'Float',
46
- :'grow' => :'BOOLEAN'
46
+ :'grow' => :'BOOLEAN',
47
47
  }
48
48
  end
49
49
 
@@ -114,15 +114,27 @@ module AsposeSlidesCloud
114
114
  def build_from_hash(attributes)
115
115
  return nil unless attributes.is_a?(Hash)
116
116
  self.class.swagger_types.each_pair do |key, type|
117
- if type =~ /\AArray<(.*)>/i
118
- # check to ensure the input is an array given that the the attribute
119
- # is documented as an array but the input is not
120
- if attributes[self.class.attribute_map[key]].is_a?(Array)
121
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
117
+ mapKey = self.class.attribute_map[key]
118
+ if !mapKey.nil?
119
+ val = attributes[mapKey]
120
+ if val.nil?
121
+ mapKeyString = mapKey.to_s
122
+ mapKeyString[0] = mapKeyString[0].downcase
123
+ mapKey = mapKeyString.to_sym
124
+ val = attributes[mapKey]
122
125
  end
123
- elsif !attributes[self.class.attribute_map[key]].nil?
124
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
125
- end # or else data not found in attributes(hash), not an issue as the data can be optional
126
+ if !val.nil?
127
+ if type =~ /\AArray<(.*)>/i
128
+ # check to ensure the input is an array given that the the attribute
129
+ # is documented as an array but the input is not
130
+ if val.is_a?(Array)
131
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
132
+ end
133
+ else
134
+ self.send("#{key}=", _deserialize(type, val))
135
+ end
136
+ end
137
+ end
126
138
  end
127
139
 
128
140
  self
@@ -24,64 +24,7 @@ require 'date'
24
24
 
25
25
  module AsposeSlidesCloud
26
26
  # One value series.
27
- class BoxAndWhiskerSeries
28
- # Series type.
29
- attr_accessor :type
30
-
31
- # Series name.
32
- attr_accessor :name
33
-
34
- # True if each data marker in the series has a different color.
35
- attr_accessor :is_color_varied
36
-
37
- # Invert solid color for the series.
38
- attr_accessor :inverted_solid_fill_color
39
-
40
- # True if curve smoothing is turned on. Applies only to line and scatter connected by lines charts.
41
- attr_accessor :smooth
42
-
43
- # True if the series is plotted on second value axis.
44
- attr_accessor :plot_on_second_axis
45
-
46
- # Series order.
47
- attr_accessor :order
48
-
49
- # The number format for the series y values.
50
- attr_accessor :number_format_of_y_values
51
-
52
- # The number format for the series x values.
53
- attr_accessor :number_format_of_x_values
54
-
55
- # The number format for the series values.
56
- attr_accessor :number_format_of_values
57
-
58
- # The number format for the series bubble sizes.
59
- attr_accessor :number_format_of_bubble_sizes
60
-
61
- # True if the series shall invert its colors if the value is negative. Applies to bar, column and bubble series.
62
- attr_accessor :invert_if_negative
63
-
64
- # The distance of an open pie slice from the center of the pie chart is expressed as a percentage of the pie diameter.
65
- attr_accessor :explosion
66
-
67
- # Series marker.
68
- attr_accessor :marker
69
-
70
- # Fill properties set for the series.
71
- attr_accessor :fill_format
72
-
73
- # Effect properties set for the series.
74
- attr_accessor :effect_format
75
-
76
- # Line properties set for the series.
77
- attr_accessor :line_format
78
-
79
- # Data point type.
80
- attr_accessor :data_point_type
81
-
82
- # Gets or sets the values.
83
- attr_accessor :data_points
84
-
27
+ class BoxAndWhiskerSeries < OneValueSeries
85
28
  # Quartile method.
86
29
  attr_accessor :quartile_method
87
30
 
@@ -121,149 +64,30 @@ module AsposeSlidesCloud
121
64
 
122
65
  # Attribute mapping from ruby-style variable name to JSON key.
123
66
  def self.attribute_map
124
- {
125
- :'type' => :'Type',
126
- :'name' => :'Name',
127
- :'is_color_varied' => :'IsColorVaried',
128
- :'inverted_solid_fill_color' => :'InvertedSolidFillColor',
129
- :'smooth' => :'Smooth',
130
- :'plot_on_second_axis' => :'PlotOnSecondAxis',
131
- :'order' => :'Order',
132
- :'number_format_of_y_values' => :'NumberFormatOfYValues',
133
- :'number_format_of_x_values' => :'NumberFormatOfXValues',
134
- :'number_format_of_values' => :'NumberFormatOfValues',
135
- :'number_format_of_bubble_sizes' => :'NumberFormatOfBubbleSizes',
136
- :'invert_if_negative' => :'InvertIfNegative',
137
- :'explosion' => :'Explosion',
138
- :'marker' => :'Marker',
139
- :'fill_format' => :'FillFormat',
140
- :'effect_format' => :'EffectFormat',
141
- :'line_format' => :'LineFormat',
142
- :'data_point_type' => :'DataPointType',
143
- :'data_points' => :'DataPoints',
67
+ super.merge({
144
68
  :'quartile_method' => :'QuartileMethod',
145
69
  :'show_inner_points' => :'ShowInnerPoints',
146
70
  :'show_mean_line' => :'ShowMeanLine',
147
71
  :'show_mean_markers' => :'ShowMeanMarkers',
148
- :'show_outlier_points' => :'ShowOutlierPoints'
149
- }
72
+ :'show_outlier_points' => :'ShowOutlierPoints',
73
+ })
150
74
  end
151
75
 
152
76
  # Attribute type mapping.
153
77
  def self.swagger_types
154
- {
155
- :'type' => :'String',
156
- :'name' => :'String',
157
- :'is_color_varied' => :'BOOLEAN',
158
- :'inverted_solid_fill_color' => :'String',
159
- :'smooth' => :'BOOLEAN',
160
- :'plot_on_second_axis' => :'BOOLEAN',
161
- :'order' => :'Integer',
162
- :'number_format_of_y_values' => :'String',
163
- :'number_format_of_x_values' => :'String',
164
- :'number_format_of_values' => :'String',
165
- :'number_format_of_bubble_sizes' => :'String',
166
- :'invert_if_negative' => :'BOOLEAN',
167
- :'explosion' => :'Integer',
168
- :'marker' => :'SeriesMarker',
169
- :'fill_format' => :'FillFormat',
170
- :'effect_format' => :'EffectFormat',
171
- :'line_format' => :'LineFormat',
172
- :'data_point_type' => :'String',
173
- :'data_points' => :'Array<OneValueChartDataPoint>',
78
+ super.merge({
174
79
  :'quartile_method' => :'String',
175
80
  :'show_inner_points' => :'BOOLEAN',
176
81
  :'show_mean_line' => :'BOOLEAN',
177
82
  :'show_mean_markers' => :'BOOLEAN',
178
- :'show_outlier_points' => :'BOOLEAN'
179
- }
83
+ :'show_outlier_points' => :'BOOLEAN',
84
+ })
180
85
  end
181
86
 
182
87
  # Initializes the object
183
88
  # @param [Hash] attributes Model attributes in the form of hash
184
89
  def initialize(attributes = {})
185
- return unless attributes.is_a?(Hash)
186
-
187
- # convert string to symbol for hash key
188
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
189
-
190
- if attributes.has_key?(:'Type')
191
- self.type = attributes[:'Type']
192
- end
193
-
194
- if attributes.has_key?(:'Name')
195
- self.name = attributes[:'Name']
196
- end
197
-
198
- if attributes.has_key?(:'IsColorVaried')
199
- self.is_color_varied = attributes[:'IsColorVaried']
200
- end
201
-
202
- if attributes.has_key?(:'InvertedSolidFillColor')
203
- self.inverted_solid_fill_color = attributes[:'InvertedSolidFillColor']
204
- end
205
-
206
- if attributes.has_key?(:'Smooth')
207
- self.smooth = attributes[:'Smooth']
208
- end
209
-
210
- if attributes.has_key?(:'PlotOnSecondAxis')
211
- self.plot_on_second_axis = attributes[:'PlotOnSecondAxis']
212
- end
213
-
214
- if attributes.has_key?(:'Order')
215
- self.order = attributes[:'Order']
216
- end
217
-
218
- if attributes.has_key?(:'NumberFormatOfYValues')
219
- self.number_format_of_y_values = attributes[:'NumberFormatOfYValues']
220
- end
221
-
222
- if attributes.has_key?(:'NumberFormatOfXValues')
223
- self.number_format_of_x_values = attributes[:'NumberFormatOfXValues']
224
- end
225
-
226
- if attributes.has_key?(:'NumberFormatOfValues')
227
- self.number_format_of_values = attributes[:'NumberFormatOfValues']
228
- end
229
-
230
- if attributes.has_key?(:'NumberFormatOfBubbleSizes')
231
- self.number_format_of_bubble_sizes = attributes[:'NumberFormatOfBubbleSizes']
232
- end
233
-
234
- if attributes.has_key?(:'InvertIfNegative')
235
- self.invert_if_negative = attributes[:'InvertIfNegative']
236
- end
237
-
238
- if attributes.has_key?(:'Explosion')
239
- self.explosion = attributes[:'Explosion']
240
- end
241
-
242
- if attributes.has_key?(:'Marker')
243
- self.marker = attributes[:'Marker']
244
- end
245
-
246
- if attributes.has_key?(:'FillFormat')
247
- self.fill_format = attributes[:'FillFormat']
248
- end
249
-
250
- if attributes.has_key?(:'EffectFormat')
251
- self.effect_format = attributes[:'EffectFormat']
252
- end
253
-
254
- if attributes.has_key?(:'LineFormat')
255
- self.line_format = attributes[:'LineFormat']
256
- end
257
-
258
- if attributes.has_key?(:'DataPointType')
259
- self.data_point_type = attributes[:'DataPointType']
260
- end
261
-
262
- if attributes.has_key?(:'DataPoints')
263
- if (value = attributes[:'DataPoints']).is_a?(Array)
264
- self.data_points = value
265
- end
266
- end
90
+ super
267
91
 
268
92
  if attributes.has_key?(:'QuartileMethod')
269
93
  self.quartile_method = attributes[:'QuartileMethod']
@@ -284,52 +108,25 @@ module AsposeSlidesCloud
284
108
  if attributes.has_key?(:'ShowOutlierPoints')
285
109
  self.show_outlier_points = attributes[:'ShowOutlierPoints']
286
110
  end
111
+ self.data_point_type = "OneValue"
287
112
  end
288
113
 
289
114
  # Show invalid properties with the reasons. Usually used together with valid?
290
115
  # @return Array for valid properties with the reasons
291
116
  def list_invalid_properties
292
- invalid_properties = Array.new
293
- if @data_point_type.nil?
294
- invalid_properties.push('invalid value for "data_point_type", data_point_type cannot be nil.')
295
- end
296
-
117
+ invalid_properties = super
297
118
  invalid_properties
298
119
  end
299
120
 
300
121
  # Check to see if the all the properties in the model are valid
301
122
  # @return true if the model is valid
302
123
  def valid?
303
- type_validator = EnumAttributeValidator.new('String', ['ClusteredColumn', 'StackedColumn', 'PercentsStackedColumn', 'ClusteredColumn3D', 'StackedColumn3D', 'PercentsStackedColumn3D', 'Column3D', 'ClusteredCylinder', 'StackedCylinder', 'PercentsStackedCylinder', 'Cylinder3D', 'ClusteredCone', 'StackedCone', 'PercentsStackedCone', 'Cone3D', 'ClusteredPyramid', 'StackedPyramid', 'PercentsStackedPyramid', 'Pyramid3D', 'Line', 'StackedLine', 'PercentsStackedLine', 'LineWithMarkers', 'StackedLineWithMarkers', 'PercentsStackedLineWithMarkers', 'Line3D', 'Pie', 'Pie3D', 'PieOfPie', 'ExplodedPie', 'ExplodedPie3D', 'BarOfPie', 'PercentsStackedBar', 'ClusteredBar3D', 'ClusteredBar', 'StackedBar', 'StackedBar3D', 'PercentsStackedBar3D', 'ClusteredHorizontalCylinder', 'StackedHorizontalCylinder', 'PercentsStackedHorizontalCylinder', 'ClusteredHorizontalCone', 'StackedHorizontalCone', 'PercentsStackedHorizontalCone', 'ClusteredHorizontalPyramid', 'StackedHorizontalPyramid', 'PercentsStackedHorizontalPyramid', 'Area', 'StackedArea', 'PercentsStackedArea', 'Area3D', 'StackedArea3D', 'PercentsStackedArea3D', 'ScatterWithMarkers', 'ScatterWithSmoothLinesAndMarkers', 'ScatterWithSmoothLines', 'ScatterWithStraightLinesAndMarkers', 'ScatterWithStraightLines', 'HighLowClose', 'OpenHighLowClose', 'VolumeHighLowClose', 'VolumeOpenHighLowClose', 'Surface3D', 'WireframeSurface3D', 'Contour', 'WireframeContour', 'Doughnut', 'ExplodedDoughnut', 'Bubble', 'BubbleWith3D', 'Radar', 'RadarWithMarkers', 'FilledRadar', 'SeriesOfMixedTypes', 'Treemap', 'Sunburst', 'Histogram', 'ParetoLine', 'BoxAndWhisker', 'Waterfall', 'Funnel'])
304
- return false unless type_validator.valid?(@type)
305
- return false if @data_point_type.nil?
306
- data_point_type_validator = EnumAttributeValidator.new('String', ['OneValue', 'Scatter', 'Bubble'])
307
- return false unless data_point_type_validator.valid?(@data_point_type)
124
+ return false if !super
308
125
  quartile_method_validator = EnumAttributeValidator.new('String', ['Exclusive', 'Inclusive'])
309
126
  return false unless quartile_method_validator.valid?(@quartile_method)
310
127
  true
311
128
  end
312
129
 
313
- # Custom attribute writer method checking allowed values (enum).
314
- # @param [Object] type Object to be assigned
315
- def type=(type)
316
- validator = EnumAttributeValidator.new('String', ['ClusteredColumn', 'StackedColumn', 'PercentsStackedColumn', 'ClusteredColumn3D', 'StackedColumn3D', 'PercentsStackedColumn3D', 'Column3D', 'ClusteredCylinder', 'StackedCylinder', 'PercentsStackedCylinder', 'Cylinder3D', 'ClusteredCone', 'StackedCone', 'PercentsStackedCone', 'Cone3D', 'ClusteredPyramid', 'StackedPyramid', 'PercentsStackedPyramid', 'Pyramid3D', 'Line', 'StackedLine', 'PercentsStackedLine', 'LineWithMarkers', 'StackedLineWithMarkers', 'PercentsStackedLineWithMarkers', 'Line3D', 'Pie', 'Pie3D', 'PieOfPie', 'ExplodedPie', 'ExplodedPie3D', 'BarOfPie', 'PercentsStackedBar', 'ClusteredBar3D', 'ClusteredBar', 'StackedBar', 'StackedBar3D', 'PercentsStackedBar3D', 'ClusteredHorizontalCylinder', 'StackedHorizontalCylinder', 'PercentsStackedHorizontalCylinder', 'ClusteredHorizontalCone', 'StackedHorizontalCone', 'PercentsStackedHorizontalCone', 'ClusteredHorizontalPyramid', 'StackedHorizontalPyramid', 'PercentsStackedHorizontalPyramid', 'Area', 'StackedArea', 'PercentsStackedArea', 'Area3D', 'StackedArea3D', 'PercentsStackedArea3D', 'ScatterWithMarkers', 'ScatterWithSmoothLinesAndMarkers', 'ScatterWithSmoothLines', 'ScatterWithStraightLinesAndMarkers', 'ScatterWithStraightLines', 'HighLowClose', 'OpenHighLowClose', 'VolumeHighLowClose', 'VolumeOpenHighLowClose', 'Surface3D', 'WireframeSurface3D', 'Contour', 'WireframeContour', 'Doughnut', 'ExplodedDoughnut', 'Bubble', 'BubbleWith3D', 'Radar', 'RadarWithMarkers', 'FilledRadar', 'SeriesOfMixedTypes', 'Treemap', 'Sunburst', 'Histogram', 'ParetoLine', 'BoxAndWhisker', 'Waterfall', 'Funnel'])
317
- unless validator.valid?(type)
318
- fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
319
- end
320
- @type = type
321
- end
322
-
323
- # Custom attribute writer method checking allowed values (enum).
324
- # @param [Object] data_point_type Object to be assigned
325
- def data_point_type=(data_point_type)
326
- validator = EnumAttributeValidator.new('String', ['OneValue', 'Scatter', 'Bubble'])
327
- unless validator.valid?(data_point_type)
328
- fail ArgumentError, 'invalid value for "data_point_type", must be one of #{validator.allowable_values}.'
329
- end
330
- @data_point_type = data_point_type
331
- end
332
-
333
130
  # Custom attribute writer method checking allowed values (enum).
334
131
  # @param [Object] quartile_method Object to be assigned
335
132
  def quartile_method=(quartile_method)
@@ -389,15 +186,27 @@ module AsposeSlidesCloud
389
186
  def build_from_hash(attributes)
390
187
  return nil unless attributes.is_a?(Hash)
391
188
  self.class.swagger_types.each_pair do |key, type|
392
- if type =~ /\AArray<(.*)>/i
393
- # check to ensure the input is an array given that the the attribute
394
- # is documented as an array but the input is not
395
- if attributes[self.class.attribute_map[key]].is_a?(Array)
396
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
189
+ mapKey = self.class.attribute_map[key]
190
+ if !mapKey.nil?
191
+ val = attributes[mapKey]
192
+ if val.nil?
193
+ mapKeyString = mapKey.to_s
194
+ mapKeyString[0] = mapKeyString[0].downcase
195
+ mapKey = mapKeyString.to_sym
196
+ val = attributes[mapKey]
397
197
  end
398
- elsif !attributes[self.class.attribute_map[key]].nil?
399
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
400
- end # or else data not found in attributes(hash), not an issue as the data can be optional
198
+ if !val.nil?
199
+ if type =~ /\AArray<(.*)>/i
200
+ # check to ensure the input is an array given that the the attribute
201
+ # is documented as an array but the input is not
202
+ if val.is_a?(Array)
203
+ self.send("#{key}=", val.map { |v| _deserialize($1, v) })
204
+ end
205
+ else
206
+ self.send("#{key}=", _deserialize(type, val))
207
+ end
208
+ end
209
+ end
401
210
  end
402
211
 
403
212
  self