aspose_slides_cloud 19.12.0 → 20.7.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/lib/aspose_slides_cloud.rb +8 -0
- data/lib/aspose_slides_cloud/api/slides_api.rb +2156 -525
- data/lib/aspose_slides_cloud/api/slides_api_requests.rb +792 -124
- data/lib/aspose_slides_cloud/api_client.rb +7 -3
- data/lib/aspose_slides_cloud/models/add_layout_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/add_master_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/add_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/add_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/api_info.rb +20 -8
- data/lib/aspose_slides_cloud/models/arrow_head_properties.rb +20 -23
- data/lib/aspose_slides_cloud/models/audio_frame.rb +20 -8
- data/lib/aspose_slides_cloud/models/axes.rb +20 -8
- data/lib/aspose_slides_cloud/models/axis.rb +20 -168
- data/lib/aspose_slides_cloud/models/base64_input_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/blur_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/box_and_whisker_series.rb +504 -0
- data/lib/aspose_slides_cloud/models/bubble_chart_data_point.rb +20 -8
- data/lib/aspose_slides_cloud/models/bubble_series.rb +24 -45
- data/lib/aspose_slides_cloud/models/chart.rb +23 -11
- data/lib/aspose_slides_cloud/models/chart_category.rb +249 -0
- data/lib/aspose_slides_cloud/models/chart_title.rb +20 -8
- data/lib/aspose_slides_cloud/models/chart_wall.rb +20 -18
- data/lib/aspose_slides_cloud/models/color_scheme.rb +20 -8
- data/lib/aspose_slides_cloud/models/common_slide_view_properties.rb +217 -0
- data/lib/aspose_slides_cloud/models/connector.rb +20 -8
- data/lib/aspose_slides_cloud/models/custom_dash_pattern.rb +20 -8
- data/lib/aspose_slides_cloud/models/disc_usage.rb +20 -8
- data/lib/aspose_slides_cloud/models/document.rb +31 -9
- data/lib/aspose_slides_cloud/models/document_properties.rb +20 -8
- data/lib/aspose_slides_cloud/models/document_property.rb +20 -8
- data/lib/aspose_slides_cloud/models/document_replace_result.rb +31 -9
- data/lib/aspose_slides_cloud/models/effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/effect_format.rb +20 -8
- data/lib/aspose_slides_cloud/models/entity_exists.rb +212 -0
- data/lib/aspose_slides_cloud/models/error.rb +20 -8
- data/lib/aspose_slides_cloud/models/error_details.rb +20 -8
- data/lib/aspose_slides_cloud/models/export_format.rb +1 -0
- data/lib/aspose_slides_cloud/models/export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/file_version.rb +20 -8
- data/lib/aspose_slides_cloud/models/file_versions.rb +20 -8
- data/lib/aspose_slides_cloud/models/files_list.rb +20 -8
- data/lib/aspose_slides_cloud/models/files_upload_result.rb +20 -8
- data/lib/aspose_slides_cloud/models/fill_format.rb +20 -8
- data/lib/aspose_slides_cloud/models/fill_overlay_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/font_scheme.rb +20 -8
- data/lib/aspose_slides_cloud/models/font_set.rb +20 -8
- data/lib/aspose_slides_cloud/models/format_scheme.rb +20 -8
- data/lib/aspose_slides_cloud/models/geometry_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/glow_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/gradient_fill.rb +20 -8
- data/lib/aspose_slides_cloud/models/gradient_fill_stop.rb +20 -8
- data/lib/aspose_slides_cloud/models/graphical_object.rb +20 -8
- data/lib/aspose_slides_cloud/models/group_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/html_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/i_shape_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/image.rb +20 -8
- data/lib/aspose_slides_cloud/models/image_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/images.rb +20 -8
- data/lib/aspose_slides_cloud/models/inner_shadow_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/input.rb +20 -8
- data/lib/aspose_slides_cloud/models/input_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/interactive_sequence.rb +20 -8
- data/lib/aspose_slides_cloud/models/layout_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/layout_slides.rb +20 -8
- data/lib/aspose_slides_cloud/models/legend.rb +20 -38
- data/lib/aspose_slides_cloud/models/line_format.rb +20 -43
- data/lib/aspose_slides_cloud/models/master_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/master_slides.rb +20 -8
- data/lib/aspose_slides_cloud/models/merge.rb +20 -8
- data/lib/aspose_slides_cloud/models/merging_source.rb +20 -8
- data/lib/aspose_slides_cloud/models/no_fill.rb +20 -8
- data/lib/aspose_slides_cloud/models/normal_view_restored_properties.rb +217 -0
- data/lib/aspose_slides_cloud/models/notes_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/object_exist.rb +20 -8
- data/lib/aspose_slides_cloud/models/ole_object_frame.rb +20 -8
- data/lib/aspose_slides_cloud/models/one_value_chart_data_point.rb +20 -8
- data/lib/aspose_slides_cloud/models/one_value_series.rb +24 -45
- data/lib/aspose_slides_cloud/models/ordered_merge_request.rb +20 -8
- data/lib/aspose_slides_cloud/models/outer_shadow_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/output_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/paragraph.rb +21 -9
- data/lib/aspose_slides_cloud/models/paragraphs.rb +20 -8
- data/lib/aspose_slides_cloud/models/path_input_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/path_output_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/pattern_fill.rb +20 -8
- data/lib/aspose_slides_cloud/models/pdf_export_options.rb +53 -14
- data/lib/aspose_slides_cloud/models/picture_fill.rb +20 -8
- data/lib/aspose_slides_cloud/models/picture_frame.rb +20 -8
- data/lib/aspose_slides_cloud/models/pipeline.rb +20 -8
- data/lib/aspose_slides_cloud/models/placeholder.rb +20 -8
- data/lib/aspose_slides_cloud/models/placeholders.rb +20 -8
- data/lib/aspose_slides_cloud/models/plot_area.rb +20 -33
- data/lib/aspose_slides_cloud/models/portion.rb +20 -8
- data/lib/aspose_slides_cloud/models/portions.rb +28 -16
- data/lib/aspose_slides_cloud/models/pptx_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/presentation_to_merge.rb +20 -8
- data/lib/aspose_slides_cloud/models/presentations_merge_request.rb +20 -8
- data/lib/aspose_slides_cloud/models/preset_shadow_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/reflection_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/remove_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/remove_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/reorder_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/replace_text.rb +20 -8
- data/lib/aspose_slides_cloud/models/request_input_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/reset_slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/resource_base.rb +20 -8
- data/lib/aspose_slides_cloud/models/resource_uri.rb +20 -8
- data/lib/aspose_slides_cloud/models/resource_uri_element.rb +20 -8
- data/lib/aspose_slides_cloud/models/response_output_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/save.rb +22 -10
- data/lib/aspose_slides_cloud/models/save_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/save_slide.rb +22 -10
- data/lib/aspose_slides_cloud/models/scatter_chart_data_point.rb +20 -8
- data/lib/aspose_slides_cloud/models/scatter_series.rb +24 -45
- data/lib/aspose_slides_cloud/models/series.rb +47 -49
- data/lib/aspose_slides_cloud/models/series_marker.rb +20 -18
- data/lib/aspose_slides_cloud/models/shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/shape_base.rb +20 -8
- data/lib/aspose_slides_cloud/models/shape_image_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/shapes.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide_animation.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide_background.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide_comment.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide_comments.rb +20 -8
- data/lib/aspose_slides_cloud/models/slide_export_format.rb +1 -0
- data/lib/aspose_slides_cloud/models/slide_replace_result.rb +20 -8
- data/lib/aspose_slides_cloud/models/slides.rb +20 -8
- data/lib/aspose_slides_cloud/models/smart_art.rb +20 -8
- data/lib/aspose_slides_cloud/models/smart_art_node.rb +20 -8
- data/lib/aspose_slides_cloud/models/smart_art_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/soft_edge_effect.rb +20 -8
- data/lib/aspose_slides_cloud/models/solid_fill.rb +20 -8
- data/lib/aspose_slides_cloud/models/split_document_result.rb +20 -8
- data/lib/aspose_slides_cloud/models/storage_exist.rb +20 -8
- data/lib/aspose_slides_cloud/models/storage_file.rb +20 -8
- data/lib/aspose_slides_cloud/models/svg_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/swf_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/table.rb +20 -48
- data/lib/aspose_slides_cloud/models/table_cell.rb +20 -48
- data/lib/aspose_slides_cloud/models/table_column.rb +20 -8
- data/lib/aspose_slides_cloud/models/table_row.rb +20 -8
- data/lib/aspose_slides_cloud/models/task.rb +20 -8
- data/lib/aspose_slides_cloud/models/text_item.rb +20 -8
- data/lib/aspose_slides_cloud/models/text_items.rb +20 -8
- data/lib/aspose_slides_cloud/models/theme.rb +20 -8
- data/lib/aspose_slides_cloud/models/tiff_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/models/update_background.rb +20 -8
- data/lib/aspose_slides_cloud/models/update_shape.rb +20 -8
- data/lib/aspose_slides_cloud/models/video_frame.rb +20 -8
- data/lib/aspose_slides_cloud/models/view_properties.rb +379 -0
- data/lib/aspose_slides_cloud/models/waterfall_series.rb +452 -0
- data/lib/aspose_slides_cloud/models/xps_export_options.rb +20 -8
- data/lib/aspose_slides_cloud/version.rb +1 -1
- data/spec/api/slides_api_spec.rb +17214 -12046
- data/spec/extra/extra_spec.rb +111 -9
- data/spec/spec_utils.rb +8 -1
- data/testRules.json +80 -8
- metadata +9 -2
@@ -155,15 +155,27 @@ module AsposeSlidesCloud
|
|
155
155
|
def build_from_hash(attributes)
|
156
156
|
return nil unless attributes.is_a?(Hash)
|
157
157
|
self.class.swagger_types.each_pair do |key, type|
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
if
|
162
|
-
|
158
|
+
mapKey = self.class.attribute_map[key]
|
159
|
+
if !mapKey.nil?
|
160
|
+
val = attributes[mapKey]
|
161
|
+
if val.nil?
|
162
|
+
mapKeyString = mapKey.to_s
|
163
|
+
mapKeyString[0] = mapKeyString[0].downcase
|
164
|
+
mapKey = mapKeyString.to_sym
|
165
|
+
val = attributes[mapKey]
|
163
166
|
end
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
+
if !val.nil?
|
168
|
+
if type =~ /\AArray<(.*)>/i
|
169
|
+
# check to ensure the input is an array given that the the attribute
|
170
|
+
# is documented as an array but the input is not
|
171
|
+
if val.is_a?(Array)
|
172
|
+
self.send("#{key}=", val.map { |v| _deserialize($1, v) })
|
173
|
+
end
|
174
|
+
else
|
175
|
+
self.send("#{key}=", _deserialize(type, val))
|
176
|
+
end
|
177
|
+
end
|
178
|
+
end
|
167
179
|
end
|
168
180
|
|
169
181
|
self
|
@@ -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
|
-
|
118
|
-
|
119
|
-
|
120
|
-
if
|
121
|
-
|
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
|
-
|
124
|
-
|
125
|
-
|
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
|
@@ -0,0 +1,504 @@
|
|
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
|
+
# 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
|
+
|
85
|
+
# Quartile method.
|
86
|
+
attr_accessor :quartile_method
|
87
|
+
|
88
|
+
# True if inner points are shown.
|
89
|
+
attr_accessor :show_inner_points
|
90
|
+
|
91
|
+
# True if mean line is shown.
|
92
|
+
attr_accessor :show_mean_line
|
93
|
+
|
94
|
+
# True if mean markers are shown.
|
95
|
+
attr_accessor :show_mean_markers
|
96
|
+
|
97
|
+
# True if outlier points are shown.
|
98
|
+
attr_accessor :show_outlier_points
|
99
|
+
|
100
|
+
class EnumAttributeValidator
|
101
|
+
attr_reader :datatype
|
102
|
+
attr_reader :allowable_values
|
103
|
+
|
104
|
+
def initialize(datatype, allowable_values)
|
105
|
+
@allowable_values = allowable_values.map do |value|
|
106
|
+
case datatype.to_s
|
107
|
+
when /Integer/i
|
108
|
+
value.to_i
|
109
|
+
when /Float/i
|
110
|
+
value.to_f
|
111
|
+
else
|
112
|
+
value
|
113
|
+
end
|
114
|
+
end
|
115
|
+
end
|
116
|
+
|
117
|
+
def valid?(value)
|
118
|
+
!value || allowable_values.any?{ |s| s.casecmp(value) == 0 }
|
119
|
+
end
|
120
|
+
end
|
121
|
+
|
122
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
123
|
+
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',
|
144
|
+
:'quartile_method' => :'QuartileMethod',
|
145
|
+
:'show_inner_points' => :'ShowInnerPoints',
|
146
|
+
:'show_mean_line' => :'ShowMeanLine',
|
147
|
+
:'show_mean_markers' => :'ShowMeanMarkers',
|
148
|
+
:'show_outlier_points' => :'ShowOutlierPoints'
|
149
|
+
}
|
150
|
+
end
|
151
|
+
|
152
|
+
# Attribute type mapping.
|
153
|
+
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>',
|
174
|
+
:'quartile_method' => :'String',
|
175
|
+
:'show_inner_points' => :'BOOLEAN',
|
176
|
+
:'show_mean_line' => :'BOOLEAN',
|
177
|
+
:'show_mean_markers' => :'BOOLEAN',
|
178
|
+
:'show_outlier_points' => :'BOOLEAN'
|
179
|
+
}
|
180
|
+
end
|
181
|
+
|
182
|
+
# Initializes the object
|
183
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
184
|
+
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
|
+
else
|
261
|
+
self.data_point_type = "OneValue"
|
262
|
+
end
|
263
|
+
|
264
|
+
if attributes.has_key?(:'DataPoints')
|
265
|
+
if (value = attributes[:'DataPoints']).is_a?(Array)
|
266
|
+
self.data_points = value
|
267
|
+
end
|
268
|
+
end
|
269
|
+
|
270
|
+
if attributes.has_key?(:'QuartileMethod')
|
271
|
+
self.quartile_method = attributes[:'QuartileMethod']
|
272
|
+
end
|
273
|
+
|
274
|
+
if attributes.has_key?(:'ShowInnerPoints')
|
275
|
+
self.show_inner_points = attributes[:'ShowInnerPoints']
|
276
|
+
end
|
277
|
+
|
278
|
+
if attributes.has_key?(:'ShowMeanLine')
|
279
|
+
self.show_mean_line = attributes[:'ShowMeanLine']
|
280
|
+
end
|
281
|
+
|
282
|
+
if attributes.has_key?(:'ShowMeanMarkers')
|
283
|
+
self.show_mean_markers = attributes[:'ShowMeanMarkers']
|
284
|
+
end
|
285
|
+
|
286
|
+
if attributes.has_key?(:'ShowOutlierPoints')
|
287
|
+
self.show_outlier_points = attributes[:'ShowOutlierPoints']
|
288
|
+
end
|
289
|
+
end
|
290
|
+
|
291
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
292
|
+
# @return Array for valid properties with the reasons
|
293
|
+
def list_invalid_properties
|
294
|
+
invalid_properties = Array.new
|
295
|
+
if @data_point_type.nil?
|
296
|
+
invalid_properties.push('invalid value for "data_point_type", data_point_type cannot be nil.')
|
297
|
+
end
|
298
|
+
|
299
|
+
invalid_properties
|
300
|
+
end
|
301
|
+
|
302
|
+
# Check to see if the all the properties in the model are valid
|
303
|
+
# @return true if the model is valid
|
304
|
+
def valid?
|
305
|
+
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'])
|
306
|
+
return false unless type_validator.valid?(@type)
|
307
|
+
return false if @data_point_type.nil?
|
308
|
+
data_point_type_validator = EnumAttributeValidator.new('String', ['OneValue', 'Scatter', 'Bubble'])
|
309
|
+
return false unless data_point_type_validator.valid?(@data_point_type)
|
310
|
+
quartile_method_validator = EnumAttributeValidator.new('String', ['Exclusive', 'Inclusive'])
|
311
|
+
return false unless quartile_method_validator.valid?(@quartile_method)
|
312
|
+
true
|
313
|
+
end
|
314
|
+
|
315
|
+
# Custom attribute writer method checking allowed values (enum).
|
316
|
+
# @param [Object] type Object to be assigned
|
317
|
+
def type=(type)
|
318
|
+
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'])
|
319
|
+
unless validator.valid?(type)
|
320
|
+
fail ArgumentError, 'invalid value for "type", must be one of #{validator.allowable_values}.'
|
321
|
+
end
|
322
|
+
@type = type
|
323
|
+
end
|
324
|
+
|
325
|
+
# Custom attribute writer method checking allowed values (enum).
|
326
|
+
# @param [Object] data_point_type Object to be assigned
|
327
|
+
def data_point_type=(data_point_type)
|
328
|
+
validator = EnumAttributeValidator.new('String', ['OneValue', 'Scatter', 'Bubble'])
|
329
|
+
unless validator.valid?(data_point_type)
|
330
|
+
fail ArgumentError, 'invalid value for "data_point_type", must be one of #{validator.allowable_values}.'
|
331
|
+
end
|
332
|
+
@data_point_type = data_point_type
|
333
|
+
end
|
334
|
+
|
335
|
+
# Custom attribute writer method checking allowed values (enum).
|
336
|
+
# @param [Object] quartile_method Object to be assigned
|
337
|
+
def quartile_method=(quartile_method)
|
338
|
+
validator = EnumAttributeValidator.new('String', ['Exclusive', 'Inclusive'])
|
339
|
+
unless validator.valid?(quartile_method)
|
340
|
+
fail ArgumentError, 'invalid value for "quartile_method", must be one of #{validator.allowable_values}.'
|
341
|
+
end
|
342
|
+
@quartile_method = quartile_method
|
343
|
+
end
|
344
|
+
|
345
|
+
# Checks equality by comparing each attribute.
|
346
|
+
# @param [Object] Object to be compared
|
347
|
+
def ==(o)
|
348
|
+
return true if self.equal?(o)
|
349
|
+
self.class == o.class &&
|
350
|
+
type == o.type &&
|
351
|
+
name == o.name &&
|
352
|
+
is_color_varied == o.is_color_varied &&
|
353
|
+
inverted_solid_fill_color == o.inverted_solid_fill_color &&
|
354
|
+
smooth == o.smooth &&
|
355
|
+
plot_on_second_axis == o.plot_on_second_axis &&
|
356
|
+
order == o.order &&
|
357
|
+
number_format_of_y_values == o.number_format_of_y_values &&
|
358
|
+
number_format_of_x_values == o.number_format_of_x_values &&
|
359
|
+
number_format_of_values == o.number_format_of_values &&
|
360
|
+
number_format_of_bubble_sizes == o.number_format_of_bubble_sizes &&
|
361
|
+
invert_if_negative == o.invert_if_negative &&
|
362
|
+
explosion == o.explosion &&
|
363
|
+
marker == o.marker &&
|
364
|
+
fill_format == o.fill_format &&
|
365
|
+
effect_format == o.effect_format &&
|
366
|
+
line_format == o.line_format &&
|
367
|
+
data_point_type == o.data_point_type &&
|
368
|
+
data_points == o.data_points &&
|
369
|
+
quartile_method == o.quartile_method &&
|
370
|
+
show_inner_points == o.show_inner_points &&
|
371
|
+
show_mean_line == o.show_mean_line &&
|
372
|
+
show_mean_markers == o.show_mean_markers &&
|
373
|
+
show_outlier_points == o.show_outlier_points
|
374
|
+
end
|
375
|
+
|
376
|
+
# @see the `==` method
|
377
|
+
# @param [Object] Object to be compared
|
378
|
+
def eql?(o)
|
379
|
+
self == o
|
380
|
+
end
|
381
|
+
|
382
|
+
# Calculates hash code according to all attributes.
|
383
|
+
# @return [Fixnum] Hash code
|
384
|
+
def hash
|
385
|
+
[type, name, is_color_varied, inverted_solid_fill_color, smooth, plot_on_second_axis, order, number_format_of_y_values, number_format_of_x_values, number_format_of_values, number_format_of_bubble_sizes, invert_if_negative, explosion, marker, fill_format, effect_format, line_format, data_point_type, data_points, quartile_method, show_inner_points, show_mean_line, show_mean_markers, show_outlier_points].hash
|
386
|
+
end
|
387
|
+
|
388
|
+
# Builds the object from hash
|
389
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
390
|
+
# @return [Object] Returns the model itself
|
391
|
+
def build_from_hash(attributes)
|
392
|
+
return nil unless attributes.is_a?(Hash)
|
393
|
+
self.class.swagger_types.each_pair do |key, type|
|
394
|
+
mapKey = self.class.attribute_map[key]
|
395
|
+
if !mapKey.nil?
|
396
|
+
val = attributes[mapKey]
|
397
|
+
if val.nil?
|
398
|
+
mapKeyString = mapKey.to_s
|
399
|
+
mapKeyString[0] = mapKeyString[0].downcase
|
400
|
+
mapKey = mapKeyString.to_sym
|
401
|
+
val = attributes[mapKey]
|
402
|
+
end
|
403
|
+
if !val.nil?
|
404
|
+
if type =~ /\AArray<(.*)>/i
|
405
|
+
# check to ensure the input is an array given that the the attribute
|
406
|
+
# is documented as an array but the input is not
|
407
|
+
if val.is_a?(Array)
|
408
|
+
self.send("#{key}=", val.map { |v| _deserialize($1, v) })
|
409
|
+
end
|
410
|
+
else
|
411
|
+
self.send("#{key}=", _deserialize(type, val))
|
412
|
+
end
|
413
|
+
end
|
414
|
+
end
|
415
|
+
end
|
416
|
+
|
417
|
+
self
|
418
|
+
end
|
419
|
+
|
420
|
+
# Deserializes the data based on type
|
421
|
+
# @param string type Data type
|
422
|
+
# @param string value Value to be deserialized
|
423
|
+
# @return [Object] Deserialized data
|
424
|
+
def _deserialize(type, value)
|
425
|
+
case type.to_sym
|
426
|
+
when :DateTime
|
427
|
+
DateTime.parse(value)
|
428
|
+
when :Date
|
429
|
+
Date.parse(value)
|
430
|
+
when :String
|
431
|
+
value.to_s
|
432
|
+
when :Integer
|
433
|
+
value.to_i
|
434
|
+
when :Float
|
435
|
+
value.to_f
|
436
|
+
when :BOOLEAN
|
437
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
438
|
+
true
|
439
|
+
else
|
440
|
+
false
|
441
|
+
end
|
442
|
+
when :Object
|
443
|
+
# generic object (usually a Hash), return directly
|
444
|
+
value
|
445
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
446
|
+
inner_type = Regexp.last_match[:inner_type]
|
447
|
+
value.map { |v| _deserialize(inner_type, v) }
|
448
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
449
|
+
k_type = Regexp.last_match[:k_type]
|
450
|
+
v_type = Regexp.last_match[:v_type]
|
451
|
+
{}.tap do |hash|
|
452
|
+
value.each do |k, v|
|
453
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
454
|
+
end
|
455
|
+
end
|
456
|
+
else # model
|
457
|
+
temp_model = AsposeSlidesCloud.const_get(type).new
|
458
|
+
temp_model.build_from_hash(value)
|
459
|
+
end
|
460
|
+
end
|
461
|
+
|
462
|
+
# Returns the string representation of the object
|
463
|
+
# @return [String] String presentation of the object
|
464
|
+
def to_s
|
465
|
+
to_hash.to_s
|
466
|
+
end
|
467
|
+
|
468
|
+
# to_body is an alias to to_hash (backward compatibility)
|
469
|
+
# @return [Hash] Returns the object in the form of hash
|
470
|
+
def to_body
|
471
|
+
to_hash
|
472
|
+
end
|
473
|
+
|
474
|
+
# Returns the object in the form of hash
|
475
|
+
# @return [Hash] Returns the object in the form of hash
|
476
|
+
def to_hash
|
477
|
+
hash = {}
|
478
|
+
self.class.attribute_map.each_pair do |attr, param|
|
479
|
+
value = self.send(attr)
|
480
|
+
next if value.nil?
|
481
|
+
hash[param] = _to_hash(value)
|
482
|
+
end
|
483
|
+
hash
|
484
|
+
end
|
485
|
+
|
486
|
+
# Outputs non-array value in the form of hash
|
487
|
+
# For object, use to_hash. Otherwise, just return the value
|
488
|
+
# @param [Object] value Any valid value
|
489
|
+
# @return [Hash] Returns the value in the form of hash
|
490
|
+
def _to_hash(value)
|
491
|
+
if value.is_a?(Array)
|
492
|
+
value.compact.map { |v| _to_hash(v) }
|
493
|
+
elsif value.is_a?(Hash)
|
494
|
+
{}.tap do |hash|
|
495
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
496
|
+
end
|
497
|
+
elsif value.respond_to? :to_hash
|
498
|
+
value.to_hash
|
499
|
+
else
|
500
|
+
value
|
501
|
+
end
|
502
|
+
end
|
503
|
+
end
|
504
|
+
end
|