aspose_diagram_cloud 18.10.3 → 19.10

Sign up to get free protection for your applications and to get access to all the features.
Files changed (104) hide show
  1. checksums.yaml +4 -4
  2. data/{aspose_diagram_cloud.gemspec → AsposeDiagramCloud.gemspec} +5 -5
  3. data/README.md +94 -124
  4. data/docs/{FileFormatRequest.md → CreateNewResponse.md} +2 -2
  5. data/docs/DiagramApi.md +241 -0
  6. data/docs/DiagramSaveOptions.md +10 -0
  7. data/docs/DiscUsage.md +9 -0
  8. data/docs/Error.md +11 -0
  9. data/docs/ErrorDetails.md +9 -0
  10. data/docs/FileVersion.md +14 -0
  11. data/docs/FileVersions.md +8 -0
  12. data/docs/FilesList.md +8 -0
  13. data/docs/FilesUploadResult.md +9 -0
  14. data/docs/HTMLSaveOptions.md +19 -0
  15. data/docs/ImageSaveOptions.md +29 -0
  16. data/docs/ModifyResponse.md +9 -0
  17. data/docs/OAuthApi.md +3 -3
  18. data/docs/ObjectExist.md +9 -0
  19. data/docs/PageSize.md +8 -0
  20. data/docs/PdfDigitalSignatureDetails.md +11 -0
  21. data/docs/PdfEncryptionDetails.md +11 -0
  22. data/docs/PdfSaveOptions.md +25 -0
  23. data/docs/PointF.md +10 -0
  24. data/docs/RectangleF.md +18 -0
  25. data/docs/RenderingSaveOptions.md +13 -0
  26. data/docs/SVGSaveOptions.md +18 -0
  27. data/docs/SWFSaveOptions.md +13 -0
  28. data/docs/SaaSposeResponse.md +0 -2
  29. data/docs/SaveAsResponse.md +10 -0
  30. data/docs/SaveOptionsModel.md +9 -0
  31. data/docs/SaveOptionsRequest.md +10 -0
  32. data/docs/StorageApi.md +799 -0
  33. data/docs/StorageExist.md +8 -0
  34. data/docs/StorageFile.md +12 -0
  35. data/docs/{SharpModel.md → UploadResponse.md} +2 -2
  36. data/docs/XAMLSaveOptions.md +12 -0
  37. data/docs/XPSSaveOptions.md +13 -0
  38. data/lib/AsposeDiagramCloud.rb +74 -0
  39. data/lib/AsposeDiagramCloud/api/diagram_api.rb +300 -0
  40. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/api/o_auth_api.rb +3 -3
  41. data/lib/AsposeDiagramCloud/api/storage_api.rb +905 -0
  42. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/api_client.rb +7 -4
  43. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/api_error.rb +2 -2
  44. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/configuration.rb +4 -18
  45. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/models/access_token_response.rb +2 -2
  46. data/lib/{aspose_diagram_cloud/models/file_format_request.rb → AsposeDiagramCloud/models/create_new_response.rb} +10 -10
  47. data/lib/AsposeDiagramCloud/models/diagram_save_options.rb +244 -0
  48. data/lib/{aspose_diagram_cloud/models/link.rb → AsposeDiagramCloud/models/disc_usage.rb} +29 -35
  49. data/lib/AsposeDiagramCloud/models/error.rb +219 -0
  50. data/lib/{aspose_diagram_cloud/models/saa_spose_response.rb → AsposeDiagramCloud/models/error_details.rb} +22 -20
  51. data/lib/AsposeDiagramCloud/models/file_version.rb +264 -0
  52. data/lib/{aspose_diagram_cloud/models/page_model.rb → AsposeDiagramCloud/models/file_versions.rb} +13 -21
  53. data/lib/AsposeDiagramCloud/models/files_list.rb +191 -0
  54. data/lib/AsposeDiagramCloud/models/files_upload_result.rb +203 -0
  55. data/lib/AsposeDiagramCloud/models/html_save_options.rb +330 -0
  56. data/lib/AsposeDiagramCloud/models/image_save_options.rb +492 -0
  57. data/lib/AsposeDiagramCloud/models/modify_response.rb +202 -0
  58. data/lib/{aspose_diagram_cloud/models/diagram_response.rb → AsposeDiagramCloud/models/object_exist.rb} +27 -29
  59. data/lib/AsposeDiagramCloud/models/page_size.rb +221 -0
  60. data/lib/AsposeDiagramCloud/models/pdf_digital_signature_details.rb +248 -0
  61. data/lib/AsposeDiagramCloud/models/pdf_encryption_details.rb +260 -0
  62. data/lib/AsposeDiagramCloud/models/pdf_save_options.rb +408 -0
  63. data/lib/{aspose_diagram_cloud/models/save_result.rb → AsposeDiagramCloud/models/point_f.rb} +37 -24
  64. data/lib/AsposeDiagramCloud/models/rectangle_f.rb +333 -0
  65. data/lib/AsposeDiagramCloud/models/rendering_save_options.rb +276 -0
  66. data/lib/{aspose_diagram_cloud/models/sharp_model.rb → AsposeDiagramCloud/models/saa_spose_response.rb} +5 -14
  67. data/lib/{aspose_diagram_cloud/models/save_response.rb → AsposeDiagramCloud/models/save_as_response.rb} +24 -27
  68. data/lib/AsposeDiagramCloud/models/save_options_model.rb +235 -0
  69. data/lib/{aspose_diagram_cloud/models/diagram_model.rb → AsposeDiagramCloud/models/save_options_request.rb} +19 -12
  70. data/lib/AsposeDiagramCloud/models/storage_exist.rb +194 -0
  71. data/lib/AsposeDiagramCloud/models/storage_file.rb +239 -0
  72. data/lib/AsposeDiagramCloud/models/svg_save_options.rb +321 -0
  73. data/lib/AsposeDiagramCloud/models/swf_save_options.rb +271 -0
  74. data/lib/AsposeDiagramCloud/models/upload_response.rb +188 -0
  75. data/lib/AsposeDiagramCloud/models/xaml_save_options.rb +262 -0
  76. data/lib/AsposeDiagramCloud/models/xps_save_options.rb +271 -0
  77. data/lib/{aspose_diagram_cloud → AsposeDiagramCloud}/version.rb +3 -3
  78. data/spec/api/test_convert_spec.rb +308 -0
  79. data/spec/api_client_spec.rb +2 -2
  80. data/spec/configuration_spec.rb +5 -5
  81. data/spec/spec_helper.rb +10 -6
  82. data/testData/FileUpload.vdx +437 -0
  83. metadata +80 -55
  84. data/docs/DiagramFileApi.md +0 -228
  85. data/docs/DiagramModel.md +0 -9
  86. data/docs/DiagramResponse.md +0 -10
  87. data/docs/Link.md +0 -11
  88. data/docs/PageModel.md +0 -9
  89. data/docs/SaveResponse.md +0 -10
  90. data/docs/SaveResult.md +0 -10
  91. data/lib/aspose_diagram_cloud.rb +0 -51
  92. data/lib/aspose_diagram_cloud/api/diagram_file_api.rb +0 -304
  93. data/spec/api/diagram_file_api_spec.rb +0 -118
  94. data/spec/api/o_auth_api_spec.rb +0 -56
  95. data/spec/models/access_token_response_spec.rb +0 -84
  96. data/spec/models/diagram_model_spec.rb +0 -48
  97. data/spec/models/diagram_response_spec.rb +0 -54
  98. data/spec/models/file_format_request_spec.rb +0 -42
  99. data/spec/models/link_spec.rb +0 -60
  100. data/spec/models/page_model_spec.rb +0 -48
  101. data/spec/models/saa_spose_response_spec.rb +0 -48
  102. data/spec/models/save_response_spec.rb +0 -54
  103. data/spec/models/save_result_spec.rb +0 -54
  104. data/spec/models/sharp_model_spec.rb +0 -42
@@ -0,0 +1,408 @@
1
+ =begin
2
+ #Aspose.Diagram Cloud API Reference
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: 3.0
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module AsposeDiagramCloud
16
+
17
+ class PdfSaveOptions
18
+ attr_accessor :save_format
19
+
20
+ attr_accessor :default_font
21
+
22
+ attr_accessor :area
23
+
24
+ attr_accessor :export_guide_shapes
25
+
26
+ attr_accessor :page_size
27
+
28
+ attr_accessor :is_export_comments
29
+
30
+ attr_accessor :horizontal_resolution
31
+
32
+ attr_accessor :vertical_resolution
33
+
34
+ attr_accessor :page_count
35
+
36
+ attr_accessor :jpeg_quality
37
+
38
+ attr_accessor :export_hidden_page
39
+
40
+ attr_accessor :page_index
41
+
42
+ attr_accessor :save_foreground_pages_only
43
+
44
+ attr_accessor :compliance
45
+
46
+ attr_accessor :encryption_details
47
+
48
+ attr_accessor :text_compression
49
+
50
+ attr_accessor :split_multi_pages
51
+
52
+ attr_accessor :digital_signature_details
53
+
54
+ class EnumAttributeValidator
55
+ attr_reader :datatype
56
+ attr_reader :allowable_values
57
+
58
+ def initialize(datatype, allowable_values)
59
+ @allowable_values = allowable_values.map do |value|
60
+ case datatype.to_s
61
+ when /Integer/i
62
+ value.to_i
63
+ when /Float/i
64
+ value.to_f
65
+ else
66
+ value
67
+ end
68
+ end
69
+ end
70
+
71
+ def valid?(value)
72
+ !value || allowable_values.include?(value)
73
+ end
74
+ end
75
+
76
+ # Attribute mapping from ruby-style variable name to JSON key.
77
+ def self.attribute_map
78
+ {
79
+ :'save_format' => :'SaveFormat',
80
+ :'default_font' => :'DefaultFont',
81
+ :'area' => :'Area',
82
+ :'export_guide_shapes' => :'ExportGuideShapes',
83
+ :'page_size' => :'PageSize',
84
+ :'is_export_comments' => :'IsExportComments',
85
+ :'horizontal_resolution' => :'HorizontalResolution',
86
+ :'vertical_resolution' => :'VerticalResolution',
87
+ :'page_count' => :'PageCount',
88
+ :'jpeg_quality' => :'JpegQuality',
89
+ :'export_hidden_page' => :'ExportHiddenPage',
90
+ :'page_index' => :'PageIndex',
91
+ :'save_foreground_pages_only' => :'SaveForegroundPagesOnly',
92
+ :'compliance' => :'Compliance',
93
+ :'encryption_details' => :'EncryptionDetails',
94
+ :'text_compression' => :'TextCompression',
95
+ :'split_multi_pages' => :'SplitMultiPages',
96
+ :'digital_signature_details' => :'DigitalSignatureDetails'
97
+ }
98
+ end
99
+
100
+ # Attribute type mapping.
101
+ def self.swagger_types
102
+ {
103
+ :'save_format' => :'String',
104
+ :'default_font' => :'String',
105
+ :'area' => :'RectangleF',
106
+ :'export_guide_shapes' => :'BOOLEAN',
107
+ :'page_size' => :'PageSize',
108
+ :'is_export_comments' => :'BOOLEAN',
109
+ :'horizontal_resolution' => :'Integer',
110
+ :'vertical_resolution' => :'Integer',
111
+ :'page_count' => :'Integer',
112
+ :'jpeg_quality' => :'Integer',
113
+ :'export_hidden_page' => :'BOOLEAN',
114
+ :'page_index' => :'Integer',
115
+ :'save_foreground_pages_only' => :'BOOLEAN',
116
+ :'compliance' => :'String',
117
+ :'encryption_details' => :'PdfEncryptionDetails',
118
+ :'text_compression' => :'String',
119
+ :'split_multi_pages' => :'BOOLEAN',
120
+ :'digital_signature_details' => :'PdfDigitalSignatureDetails'
121
+ }
122
+ end
123
+
124
+ # Initializes the object
125
+ # @param [Hash] attributes Model attributes in the form of hash
126
+ def initialize(attributes = {})
127
+ return unless attributes.is_a?(Hash)
128
+
129
+ # convert string to symbol for hash key
130
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
131
+
132
+ if attributes.has_key?(:'SaveFormat')
133
+ self.save_format = attributes[:'SaveFormat']
134
+ end
135
+
136
+ if attributes.has_key?(:'DefaultFont')
137
+ self.default_font = attributes[:'DefaultFont']
138
+ end
139
+
140
+ if attributes.has_key?(:'Area')
141
+ self.area = attributes[:'Area']
142
+ end
143
+
144
+ if attributes.has_key?(:'ExportGuideShapes')
145
+ self.export_guide_shapes = attributes[:'ExportGuideShapes']
146
+ end
147
+
148
+ if attributes.has_key?(:'PageSize')
149
+ self.page_size = attributes[:'PageSize']
150
+ end
151
+
152
+ if attributes.has_key?(:'IsExportComments')
153
+ self.is_export_comments = attributes[:'IsExportComments']
154
+ end
155
+
156
+ if attributes.has_key?(:'HorizontalResolution')
157
+ self.horizontal_resolution = attributes[:'HorizontalResolution']
158
+ end
159
+
160
+ if attributes.has_key?(:'VerticalResolution')
161
+ self.vertical_resolution = attributes[:'VerticalResolution']
162
+ end
163
+
164
+ if attributes.has_key?(:'PageCount')
165
+ self.page_count = attributes[:'PageCount']
166
+ end
167
+
168
+ if attributes.has_key?(:'JpegQuality')
169
+ self.jpeg_quality = attributes[:'JpegQuality']
170
+ end
171
+
172
+ if attributes.has_key?(:'ExportHiddenPage')
173
+ self.export_hidden_page = attributes[:'ExportHiddenPage']
174
+ end
175
+
176
+ if attributes.has_key?(:'PageIndex')
177
+ self.page_index = attributes[:'PageIndex']
178
+ end
179
+
180
+ if attributes.has_key?(:'SaveForegroundPagesOnly')
181
+ self.save_foreground_pages_only = attributes[:'SaveForegroundPagesOnly']
182
+ end
183
+
184
+ if attributes.has_key?(:'Compliance')
185
+ self.compliance = attributes[:'Compliance']
186
+ end
187
+
188
+ if attributes.has_key?(:'EncryptionDetails')
189
+ self.encryption_details = attributes[:'EncryptionDetails']
190
+ end
191
+
192
+ if attributes.has_key?(:'TextCompression')
193
+ self.text_compression = attributes[:'TextCompression']
194
+ end
195
+
196
+ if attributes.has_key?(:'SplitMultiPages')
197
+ self.split_multi_pages = attributes[:'SplitMultiPages']
198
+ end
199
+
200
+ if attributes.has_key?(:'DigitalSignatureDetails')
201
+ self.digital_signature_details = attributes[:'DigitalSignatureDetails']
202
+ end
203
+
204
+ end
205
+
206
+ # Show invalid properties with the reasons. Usually used together with valid?
207
+ # @return Array for valid properies with the reasons
208
+ def list_invalid_properties
209
+ invalid_properties = Array.new
210
+ if @save_format.nil?
211
+ invalid_properties.push("invalid value for 'save_format', save_format cannot be nil.")
212
+ end
213
+
214
+ if @area.nil?
215
+ invalid_properties.push("invalid value for 'area', area cannot be nil.")
216
+ end
217
+
218
+ return invalid_properties
219
+ end
220
+
221
+ # Check to see if the all the properties in the model are valid
222
+ # @return true if the model is valid
223
+ def valid?
224
+ return false if @save_format.nil?
225
+ save_format_validator = EnumAttributeValidator.new('String', ["VDX", "VSX", "VTX", "TIFF", "PNG", "BMP", "EMF", "JPEG", "PDF", "XPS", "GIF", "HTML", "SVG", "SWF", "XAML", "VSDX", "VSTX", "VSSX", "VSDM", "VSSM", "VSTM"])
226
+ return false unless save_format_validator.valid?(@save_format)
227
+ return false if @area.nil?
228
+ compliance_validator = EnumAttributeValidator.new('String', ["Pdf15", "PdfA1a", "PdfA1b"])
229
+ return false unless compliance_validator.valid?(@compliance)
230
+ text_compression_validator = EnumAttributeValidator.new('String', ["None", "Flate"])
231
+ return false unless text_compression_validator.valid?(@text_compression)
232
+ return true
233
+ end
234
+
235
+ # Custom attribute writer method checking allowed values (enum).
236
+ # @param [Object] save_format Object to be assigned
237
+ def save_format=(save_format)
238
+ validator = EnumAttributeValidator.new('String', ["VDX", "VSX", "VTX", "TIFF", "PNG", "BMP", "EMF", "JPEG", "PDF", "XPS", "GIF", "HTML", "SVG", "SWF", "XAML", "VSDX", "VSTX", "VSSX", "VSDM", "VSSM", "VSTM"])
239
+ unless validator.valid?(save_format)
240
+ fail ArgumentError, "invalid value for 'save_format', must be one of #{validator.allowable_values}."
241
+ end
242
+ @save_format = save_format
243
+ end
244
+
245
+ # Custom attribute writer method checking allowed values (enum).
246
+ # @param [Object] compliance Object to be assigned
247
+ def compliance=(compliance)
248
+ validator = EnumAttributeValidator.new('String', ["Pdf15", "PdfA1a", "PdfA1b"])
249
+ unless validator.valid?(compliance)
250
+ fail ArgumentError, "invalid value for 'compliance', must be one of #{validator.allowable_values}."
251
+ end
252
+ @compliance = compliance
253
+ end
254
+
255
+ # Custom attribute writer method checking allowed values (enum).
256
+ # @param [Object] text_compression Object to be assigned
257
+ def text_compression=(text_compression)
258
+ validator = EnumAttributeValidator.new('String', ["None", "Flate"])
259
+ unless validator.valid?(text_compression)
260
+ fail ArgumentError, "invalid value for 'text_compression', must be one of #{validator.allowable_values}."
261
+ end
262
+ @text_compression = text_compression
263
+ end
264
+
265
+ # Checks equality by comparing each attribute.
266
+ # @param [Object] Object to be compared
267
+ def ==(o)
268
+ return true if self.equal?(o)
269
+ self.class == o.class &&
270
+ save_format == o.save_format &&
271
+ default_font == o.default_font &&
272
+ area == o.area &&
273
+ export_guide_shapes == o.export_guide_shapes &&
274
+ page_size == o.page_size &&
275
+ is_export_comments == o.is_export_comments &&
276
+ horizontal_resolution == o.horizontal_resolution &&
277
+ vertical_resolution == o.vertical_resolution &&
278
+ page_count == o.page_count &&
279
+ jpeg_quality == o.jpeg_quality &&
280
+ export_hidden_page == o.export_hidden_page &&
281
+ page_index == o.page_index &&
282
+ save_foreground_pages_only == o.save_foreground_pages_only &&
283
+ compliance == o.compliance &&
284
+ encryption_details == o.encryption_details &&
285
+ text_compression == o.text_compression &&
286
+ split_multi_pages == o.split_multi_pages &&
287
+ digital_signature_details == o.digital_signature_details
288
+ end
289
+
290
+ # @see the `==` method
291
+ # @param [Object] Object to be compared
292
+ def eql?(o)
293
+ self == o
294
+ end
295
+
296
+ # Calculates hash code according to all attributes.
297
+ # @return [Fixnum] Hash code
298
+ def hash
299
+ [save_format, default_font, area, export_guide_shapes, page_size, is_export_comments, horizontal_resolution, vertical_resolution, page_count, jpeg_quality, export_hidden_page, page_index, save_foreground_pages_only, compliance, encryption_details, text_compression, split_multi_pages, digital_signature_details].hash
300
+ end
301
+
302
+ # Builds the object from hash
303
+ # @param [Hash] attributes Model attributes in the form of hash
304
+ # @return [Object] Returns the model itself
305
+ def build_from_hash(attributes)
306
+ return nil unless attributes.is_a?(Hash)
307
+ self.class.swagger_types.each_pair do |key, type|
308
+ if type =~ /\AArray<(.*)>/i
309
+ # check to ensure the input is an array given that the the attribute
310
+ # is documented as an array but the input is not
311
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
312
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
313
+ end
314
+ elsif !attributes[self.class.attribute_map[key]].nil?
315
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
316
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
317
+ end
318
+
319
+ self
320
+ end
321
+
322
+ # Deserializes the data based on type
323
+ # @param string type Data type
324
+ # @param string value Value to be deserialized
325
+ # @return [Object] Deserialized data
326
+ def _deserialize(type, value)
327
+ case type.to_sym
328
+ when :DateTime
329
+ DateTime.parse(value)
330
+ when :Date
331
+ Date.parse(value)
332
+ when :String
333
+ value.to_s
334
+ when :Integer
335
+ value.to_i
336
+ when :Float
337
+ value.to_f
338
+ when :BOOLEAN
339
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
340
+ true
341
+ else
342
+ false
343
+ end
344
+ when :Object
345
+ # generic object (usually a Hash), return directly
346
+ value
347
+ when /\AArray<(?<inner_type>.+)>\z/
348
+ inner_type = Regexp.last_match[:inner_type]
349
+ value.map { |v| _deserialize(inner_type, v) }
350
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
351
+ k_type = Regexp.last_match[:k_type]
352
+ v_type = Regexp.last_match[:v_type]
353
+ {}.tap do |hash|
354
+ value.each do |k, v|
355
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
356
+ end
357
+ end
358
+ else # model
359
+ temp_model = AsposeDiagramCloud.const_get(type).new
360
+ temp_model.build_from_hash(value)
361
+ end
362
+ end
363
+
364
+ # Returns the string representation of the object
365
+ # @return [String] String presentation of the object
366
+ def to_s
367
+ to_hash.to_s
368
+ end
369
+
370
+ # to_body is an alias to to_hash (backward compatibility)
371
+ # @return [Hash] Returns the object in the form of hash
372
+ def to_body
373
+ to_hash
374
+ end
375
+
376
+ # Returns the object in the form of hash
377
+ # @return [Hash] Returns the object in the form of hash
378
+ def to_hash
379
+ hash = {}
380
+ self.class.attribute_map.each_pair do |attr, param|
381
+ value = self.send(attr)
382
+ next if value.nil?
383
+ hash[param] = _to_hash(value)
384
+ end
385
+ hash
386
+ end
387
+
388
+ # Outputs non-array value in the form of hash
389
+ # For object, use to_hash. Otherwise, just return the value
390
+ # @param [Object] value Any valid value
391
+ # @return [Hash] Returns the value in the form of hash
392
+ def _to_hash(value)
393
+ if value.is_a?(Array)
394
+ value.compact.map{ |v| _to_hash(v) }
395
+ elsif value.is_a?(Hash)
396
+ {}.tap do |hash|
397
+ value.each { |k, v| hash[k] = _to_hash(v) }
398
+ end
399
+ elsif value.respond_to? :to_hash
400
+ value.to_hash
401
+ else
402
+ value
403
+ end
404
+ end
405
+
406
+ end
407
+
408
+ end
@@ -1,9 +1,9 @@
1
1
  =begin
2
- #Web API Swagger specification
2
+ #Aspose.Diagram Cloud API Reference
3
3
 
4
4
  #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
5
 
6
- OpenAPI spec version: 1.0
6
+ OpenAPI spec version: 3.0
7
7
 
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
9
  Swagger Codegen version: 2.3.0-SNAPSHOT
@@ -14,29 +14,29 @@ require 'date'
14
14
 
15
15
  module AsposeDiagramCloud
16
16
 
17
- class SaveResult
18
- attr_accessor :source_document
17
+ class PointF
18
+ attr_accessor :is_empty
19
19
 
20
- attr_accessor :dest_document
20
+ attr_accessor :x
21
21
 
22
- attr_accessor :additional_items
22
+ attr_accessor :y
23
23
 
24
24
 
25
25
  # Attribute mapping from ruby-style variable name to JSON key.
26
26
  def self.attribute_map
27
27
  {
28
- :'source_document' => :'SourceDocument',
29
- :'dest_document' => :'DestDocument',
30
- :'additional_items' => :'AdditionalItems'
28
+ :'is_empty' => :'IsEmpty',
29
+ :'x' => :'X',
30
+ :'y' => :'Y'
31
31
  }
32
32
  end
33
33
 
34
34
  # Attribute type mapping.
35
35
  def self.swagger_types
36
36
  {
37
- :'source_document' => :'Link',
38
- :'dest_document' => :'Link',
39
- :'additional_items' => :'Array<Link>'
37
+ :'is_empty' => :'BOOLEAN',
38
+ :'x' => :'Float',
39
+ :'y' => :'Float'
40
40
  }
41
41
  end
42
42
 
@@ -48,18 +48,16 @@ module AsposeDiagramCloud
48
48
  # convert string to symbol for hash key
49
49
  attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
50
50
 
51
- if attributes.has_key?(:'SourceDocument')
52
- self.source_document = attributes[:'SourceDocument']
51
+ if attributes.has_key?(:'IsEmpty')
52
+ self.is_empty = attributes[:'IsEmpty']
53
53
  end
54
54
 
55
- if attributes.has_key?(:'DestDocument')
56
- self.dest_document = attributes[:'DestDocument']
55
+ if attributes.has_key?(:'X')
56
+ self.x = attributes[:'X']
57
57
  end
58
58
 
59
- if attributes.has_key?(:'AdditionalItems')
60
- if (value = attributes[:'AdditionalItems']).is_a?(Array)
61
- self.additional_items = value
62
- end
59
+ if attributes.has_key?(:'Y')
60
+ self.y = attributes[:'Y']
63
61
  end
64
62
 
65
63
  end
@@ -68,12 +66,27 @@ module AsposeDiagramCloud
68
66
  # @return Array for valid properies with the reasons
69
67
  def list_invalid_properties
70
68
  invalid_properties = Array.new
69
+ if @is_empty.nil?
70
+ invalid_properties.push("invalid value for 'is_empty', is_empty cannot be nil.")
71
+ end
72
+
73
+ if @x.nil?
74
+ invalid_properties.push("invalid value for 'x', x cannot be nil.")
75
+ end
76
+
77
+ if @y.nil?
78
+ invalid_properties.push("invalid value for 'y', y cannot be nil.")
79
+ end
80
+
71
81
  return invalid_properties
72
82
  end
73
83
 
74
84
  # Check to see if the all the properties in the model are valid
75
85
  # @return true if the model is valid
76
86
  def valid?
87
+ return false if @is_empty.nil?
88
+ return false if @x.nil?
89
+ return false if @y.nil?
77
90
  return true
78
91
  end
79
92
 
@@ -82,9 +95,9 @@ module AsposeDiagramCloud
82
95
  def ==(o)
83
96
  return true if self.equal?(o)
84
97
  self.class == o.class &&
85
- source_document == o.source_document &&
86
- dest_document == o.dest_document &&
87
- additional_items == o.additional_items
98
+ is_empty == o.is_empty &&
99
+ x == o.x &&
100
+ y == o.y
88
101
  end
89
102
 
90
103
  # @see the `==` method
@@ -96,7 +109,7 @@ module AsposeDiagramCloud
96
109
  # Calculates hash code according to all attributes.
97
110
  # @return [Fixnum] Hash code
98
111
  def hash
99
- [source_document, dest_document, additional_items].hash
112
+ [is_empty, x, y].hash
100
113
  end
101
114
 
102
115
  # Builds the object from hash