aspose_email_cloud 19.11.0 → 19.12.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (154) hide show
  1. checksums.yaml +4 -4
  2. data/lib/aspose-email-cloud.rb +43 -1
  3. data/lib/aspose-email-cloud/api/email_api.rb +221 -100
  4. data/lib/aspose-email-cloud/api_client.rb +4 -3
  5. data/lib/aspose-email-cloud/configuration.rb +4 -0
  6. data/lib/aspose-email-cloud/models/account_base_request.rb +123 -113
  7. data/lib/aspose-email-cloud/models/add_attachment_request.rb +86 -82
  8. data/lib/aspose-email-cloud/models/ai_bcr_base64_image.rb +228 -0
  9. data/lib/aspose-email-cloud/models/ai_bcr_base64_rq.rb +225 -0
  10. data/lib/aspose-email-cloud/models/ai_bcr_image.rb +215 -0
  11. data/lib/aspose-email-cloud/models/ai_bcr_image_storage_file.rb +228 -0
  12. data/lib/aspose-email-cloud/models/ai_bcr_ocr_data.rb +253 -0
  13. data/lib/aspose-email-cloud/models/ai_bcr_ocr_data_part.rb +297 -0
  14. data/lib/aspose-email-cloud/models/ai_bcr_options.rb +223 -0
  15. data/lib/aspose-email-cloud/models/ai_bcr_parse_storage_rq.rb +248 -0
  16. data/lib/aspose-email-cloud/models/ai_bcr_rq.rb +210 -0
  17. data/lib/aspose-email-cloud/models/ai_bcr_storage_image_rq.rb +230 -0
  18. data/lib/aspose-email-cloud/models/ai_name_component.rb +264 -0
  19. data/lib/aspose-email-cloud/models/ai_name_cultural_context.rb +267 -0
  20. data/lib/aspose-email-cloud/models/ai_name_extracted.rb +230 -0
  21. data/lib/aspose-email-cloud/models/ai_name_extracted_component.rb +228 -0
  22. data/lib/aspose-email-cloud/models/ai_name_formatted.rb +223 -0
  23. data/lib/aspose-email-cloud/models/ai_name_gender_hypothesis.rb +233 -0
  24. data/lib/aspose-email-cloud/models/ai_name_match_result.rb +230 -0
  25. data/lib/aspose-email-cloud/models/ai_name_mismatch.rb +246 -0
  26. data/lib/aspose-email-cloud/models/ai_name_parsed_match_rq.rb +263 -0
  27. data/lib/aspose-email-cloud/models/ai_name_parsed_rq.rb +243 -0
  28. data/lib/aspose-email-cloud/models/ai_name_weighted.rb +228 -0
  29. data/lib/aspose-email-cloud/models/ai_name_weighted_variants.rb +225 -0
  30. data/lib/aspose-email-cloud/models/append_email_account_base_request.rb +178 -163
  31. data/lib/aspose-email-cloud/models/append_email_base_request.rb +196 -179
  32. data/lib/aspose-email-cloud/models/append_email_mime_base_request.rb +215 -198
  33. data/lib/aspose-email-cloud/models/base_object.rb +9 -5
  34. data/lib/aspose-email-cloud/models/create_email_request.rb +91 -87
  35. data/lib/aspose-email-cloud/models/create_folder_base_request.rb +173 -160
  36. data/lib/aspose-email-cloud/models/delete_folder_base_request.rb +178 -165
  37. data/lib/aspose-email-cloud/models/delete_message_base_request.rb +178 -165
  38. data/lib/aspose-email-cloud/models/disc_usage.rb +96 -92
  39. data/lib/aspose-email-cloud/models/email_account_request.rb +257 -205
  40. data/lib/aspose-email-cloud/models/email_document.rb +93 -89
  41. data/lib/aspose-email-cloud/models/email_document_response.rb +73 -71
  42. data/lib/aspose-email-cloud/models/email_properties.rb +93 -88
  43. data/lib/aspose-email-cloud/models/email_property.rb +128 -119
  44. data/lib/aspose-email-cloud/models/email_property_response.rb +73 -71
  45. data/lib/aspose-email-cloud/models/error.rb +112 -104
  46. data/lib/aspose-email-cloud/models/error_details.rb +91 -87
  47. data/lib/aspose-email-cloud/models/file_version.rb +166 -152
  48. data/lib/aspose-email-cloud/models/file_versions.rb +75 -73
  49. data/lib/aspose-email-cloud/models/files_list.rb +75 -73
  50. data/lib/aspose-email-cloud/models/files_upload_result.rb +90 -86
  51. data/lib/aspose-email-cloud/models/hierarchical_object.rb +13 -7
  52. data/lib/aspose-email-cloud/models/hierarchical_object_request.rb +91 -87
  53. data/lib/aspose-email-cloud/models/hierarchical_object_response.rb +86 -82
  54. data/lib/aspose-email-cloud/models/indexed_hierarchical_object.rb +17 -9
  55. data/lib/aspose-email-cloud/models/indexed_primitive_object.rb +17 -9
  56. data/lib/aspose-email-cloud/models/link.rb +112 -104
  57. data/lib/aspose-email-cloud/models/list_response_of_ai_bcr_ocr_data.rb +211 -0
  58. data/lib/aspose-email-cloud/models/list_response_of_ai_name_component.rb +211 -0
  59. data/lib/aspose-email-cloud/models/list_response_of_ai_name_extracted.rb +211 -0
  60. data/lib/aspose-email-cloud/models/list_response_of_ai_name_gender_hypothesis.rb +211 -0
  61. data/lib/aspose-email-cloud/models/list_response_of_hierarchical_object.rb +211 -0
  62. data/lib/aspose-email-cloud/models/list_response_of_hierarchical_object_response.rb +74 -71
  63. data/lib/aspose-email-cloud/models/list_response_of_mail_server_folder.rb +74 -71
  64. data/lib/aspose-email-cloud/models/list_response_of_storage_file_location.rb +211 -0
  65. data/lib/aspose-email-cloud/models/list_response_of_string.rb +74 -71
  66. data/lib/aspose-email-cloud/models/mail_server_folder.rb +86 -82
  67. data/lib/aspose-email-cloud/models/mime_response.rb +73 -71
  68. data/lib/aspose-email-cloud/models/object_exist.rb +96 -92
  69. data/lib/aspose-email-cloud/models/primitive_object.rb +13 -7
  70. data/lib/aspose-email-cloud/models/requests/add_calendar_attachment_request_data.rb +4 -4
  71. data/lib/aspose-email-cloud/models/requests/add_contact_attachment_request_data.rb +6 -11
  72. data/lib/aspose-email-cloud/models/requests/add_email_attachment_request_data.rb +4 -4
  73. data/lib/aspose-email-cloud/models/requests/add_mapi_attachment_request_data.rb +4 -4
  74. data/lib/aspose-email-cloud/models/requests/ai_bcr_ocr_request_data.rb +75 -0
  75. data/lib/aspose-email-cloud/models/requests/ai_bcr_ocr_storage_request_data.rb +75 -0
  76. data/lib/aspose-email-cloud/models/requests/ai_bcr_parse_request_data.rb +75 -0
  77. data/lib/aspose-email-cloud/models/requests/ai_bcr_parse_storage_request_data.rb +75 -0
  78. data/lib/aspose-email-cloud/models/requests/ai_name_complete_request_data.rb +91 -0
  79. data/lib/aspose-email-cloud/models/requests/ai_name_expand_parsed_request_data.rb +75 -0
  80. data/lib/aspose-email-cloud/models/requests/ai_name_expand_request_data.rb +91 -0
  81. data/lib/aspose-email-cloud/models/requests/ai_name_format_parsed_request_data.rb +75 -0
  82. data/lib/aspose-email-cloud/models/requests/ai_name_format_request_data.rb +94 -0
  83. data/lib/aspose-email-cloud/models/requests/ai_name_genderize_parsed_request_data.rb +75 -0
  84. data/lib/aspose-email-cloud/models/requests/ai_name_genderize_request_data.rb +91 -0
  85. data/lib/aspose-email-cloud/models/requests/ai_name_match_parsed_request_data.rb +75 -0
  86. data/lib/aspose-email-cloud/models/requests/ai_name_match_request_data.rb +99 -0
  87. data/lib/aspose-email-cloud/models/requests/ai_name_parse_email_address_request_data.rb +91 -0
  88. data/lib/aspose-email-cloud/models/requests/ai_name_parse_request_data.rb +91 -0
  89. data/lib/aspose-email-cloud/models/requests/append_email_message_request_data.rb +2 -2
  90. data/lib/aspose-email-cloud/models/requests/append_mime_message_request_data.rb +2 -2
  91. data/lib/aspose-email-cloud/models/requests/copy_file_request_data.rb +5 -5
  92. data/lib/aspose-email-cloud/models/requests/copy_folder_request_data.rb +4 -4
  93. data/lib/aspose-email-cloud/models/requests/create_calendar_request_data.rb +3 -3
  94. data/lib/aspose-email-cloud/models/requests/create_contact_request_data.rb +5 -10
  95. data/lib/aspose-email-cloud/models/requests/create_email_folder_request_data.rb +2 -2
  96. data/lib/aspose-email-cloud/models/requests/create_email_request_data.rb +3 -3
  97. data/lib/aspose-email-cloud/models/requests/create_folder_request_data.rb +2 -2
  98. data/lib/aspose-email-cloud/models/requests/create_mapi_request_data.rb +3 -3
  99. data/lib/aspose-email-cloud/models/requests/delete_calendar_property_request_data.rb +5 -5
  100. data/lib/aspose-email-cloud/models/requests/delete_contact_property_request_data.rb +7 -12
  101. data/lib/aspose-email-cloud/models/requests/delete_email_folder_request_data.rb +2 -2
  102. data/lib/aspose-email-cloud/models/requests/delete_email_message_request_data.rb +2 -2
  103. data/lib/aspose-email-cloud/models/requests/delete_file_request_data.rb +3 -3
  104. data/lib/aspose-email-cloud/models/requests/delete_folder_request_data.rb +3 -3
  105. data/lib/aspose-email-cloud/models/requests/delete_mapi_attachment_request_data.rb +4 -4
  106. data/lib/aspose-email-cloud/models/requests/delete_mapi_properties_request_data.rb +3 -3
  107. data/lib/aspose-email-cloud/models/requests/download_file_request_data.rb +3 -3
  108. data/lib/aspose-email-cloud/models/requests/fetch_email_message_request_data.rb +7 -7
  109. data/lib/aspose-email-cloud/models/requests/get_calendar_attachment_request_data.rb +5 -5
  110. data/lib/aspose-email-cloud/models/requests/get_calendar_list_request_data.rb +5 -5
  111. data/lib/aspose-email-cloud/models/requests/get_calendar_request_data.rb +4 -4
  112. data/lib/aspose-email-cloud/models/requests/get_contact_attachment_request_data.rb +7 -12
  113. data/lib/aspose-email-cloud/models/requests/get_contact_list_request_data.rb +7 -12
  114. data/lib/aspose-email-cloud/models/requests/get_contact_properties_request_data.rb +6 -11
  115. data/lib/aspose-email-cloud/models/requests/get_disc_usage_request_data.rb +1 -1
  116. data/lib/aspose-email-cloud/models/requests/get_email_attachment_request_data.rb +5 -5
  117. data/lib/aspose-email-cloud/models/requests/get_email_property_request_data.rb +5 -5
  118. data/lib/aspose-email-cloud/models/requests/get_email_request_data.rb +4 -4
  119. data/lib/aspose-email-cloud/models/requests/get_file_versions_request_data.rb +2 -2
  120. data/lib/aspose-email-cloud/models/requests/get_files_list_request_data.rb +2 -2
  121. data/lib/aspose-email-cloud/models/requests/get_mapi_attachment_request_data.rb +5 -5
  122. data/lib/aspose-email-cloud/models/requests/get_mapi_attachments_request_data.rb +4 -4
  123. data/lib/aspose-email-cloud/models/requests/get_mapi_list_request_data.rb +5 -5
  124. data/lib/aspose-email-cloud/models/requests/get_mapi_properties_request_data.rb +4 -4
  125. data/lib/aspose-email-cloud/models/requests/list_email_folders_request_data.rb +7 -7
  126. data/lib/aspose-email-cloud/models/requests/list_email_messages_request_data.rb +10 -10
  127. data/lib/aspose-email-cloud/models/requests/move_file_request_data.rb +5 -5
  128. data/lib/aspose-email-cloud/models/requests/move_folder_request_data.rb +4 -4
  129. data/lib/aspose-email-cloud/models/requests/object_exists_request_data.rb +3 -3
  130. data/lib/aspose-email-cloud/models/requests/save_mail_account_request_data.rb +2 -2
  131. data/lib/aspose-email-cloud/models/requests/save_mail_o_auth_account_request_data.rb +2 -2
  132. data/lib/aspose-email-cloud/models/requests/send_email_mime_request_data.rb +2 -2
  133. data/lib/aspose-email-cloud/models/requests/send_email_request_data.rb +2 -2
  134. data/lib/aspose-email-cloud/models/requests/set_email_property_request_data.rb +5 -5
  135. data/lib/aspose-email-cloud/models/requests/set_email_read_flag_request_data.rb +2 -2
  136. data/lib/aspose-email-cloud/models/requests/storage_exists_request_data.rb +1 -1
  137. data/lib/aspose-email-cloud/models/requests/update_calendar_properties_request_data.rb +3 -3
  138. data/lib/aspose-email-cloud/models/requests/update_contact_properties_request_data.rb +5 -10
  139. data/lib/aspose-email-cloud/models/requests/update_mapi_properties_request_data.rb +3 -3
  140. data/lib/aspose-email-cloud/models/requests/upload_file_request_data.rb +3 -3
  141. data/lib/aspose-email-cloud/models/save_email_account_request.rb +294 -240
  142. data/lib/aspose-email-cloud/models/save_o_auth_email_account_request.rb +368 -310
  143. data/lib/aspose-email-cloud/models/send_email_base_request.rb +141 -130
  144. data/lib/aspose-email-cloud/models/send_email_mime_base_request.rb +160 -149
  145. data/lib/aspose-email-cloud/models/set_email_property_request.rb +91 -87
  146. data/lib/aspose-email-cloud/models/set_message_read_flag_account_base_request.rb +178 -165
  147. data/lib/aspose-email-cloud/models/storage_exist.rb +78 -76
  148. data/lib/aspose-email-cloud/models/storage_file.rb +135 -125
  149. data/lib/aspose-email-cloud/models/storage_file_location.rb +123 -117
  150. data/lib/aspose-email-cloud/models/storage_folder_location.rb +86 -82
  151. data/lib/aspose-email-cloud/models/value_response.rb +73 -71
  152. data/lib/aspose-email-cloud/version.rb +1 -1
  153. metadata +45 -3
  154. data/lib/aspose-email-cloud/models/contact_format.rb +0 -45
@@ -96,9 +96,10 @@ module AsposeEmailCloud
96
96
  # @option opts [Hash] :query_params Query parameters
97
97
  # @option opts [Hash] :form_params Query parameters
98
98
  # @option opts [Object] :body HTTP body (JSON/XML)
99
+ # @option opts [String] :host Should not be used
99
100
  # @return [Faraday::Response] A Faraday Response
100
101
  def build_request(http_method, path, opts = {})
101
- url = build_request_url(path)
102
+ url = build_request_url(path, opts[:host])
102
103
  http_method = http_method.to_sym.downcase
103
104
 
104
105
  header_params = @default_headers.merge(opts[:header_params] || {})
@@ -274,10 +275,10 @@ module AsposeEmailCloud
274
275
  filename.gsub(%r{.*[/\\]}, '')
275
276
  end
276
277
 
277
- def build_request_url(path)
278
+ def build_request_url(path, host = nil)
278
279
  # Add leading and trailing slashes to path
279
280
  path = "/#{path}".gsub(%r{/+}, '/')
280
- URI.encode(@config.base_url + path)
281
+ URI.encode((host || @config.base_url) + path)
281
282
  end
282
283
 
283
284
  # Builds the HTTP request body
@@ -38,6 +38,9 @@ module AsposeEmailCloud
38
38
  # Defines url host
39
39
  attr_accessor :host
40
40
 
41
+ # Defines auth url
42
+ attr_accessor :auth_url
43
+
41
44
  # Defines url base path
42
45
  attr_accessor :base_path
43
46
 
@@ -157,6 +160,7 @@ module AsposeEmailCloud
157
160
  def initialize(app_key = nil, app_sid = nil, base_url = 'api-qa.aspose.cloud', api_version = 'v3.0', debug = false)
158
161
  @scheme = 'https'
159
162
  self.host = base_url
163
+ self.auth_url = base_url
160
164
  @api_version = api_version
161
165
  self.base_path = @api_version
162
166
  @api_key = { 'api_key': app_key || '',
@@ -27,118 +27,128 @@
27
27
  require 'date'
28
28
 
29
29
  module AsposeEmailCloud
30
- class AccountBaseRequest
31
- attr_accessor :first_account
32
-
33
- attr_accessor :second_account
34
-
35
- attr_accessor :storage_folder
36
-
37
- # Attribute mapping from ruby-style variable name to JSON key.
38
- def self.attribute_map
39
- {
40
- :'first_account' => :'firstAccount',
41
- :'second_account' => :'secondAccount',
42
- :'storage_folder' => :'storageFolder'
43
- }
44
- end
45
-
46
- # Attribute type mapping.
47
- def self.swagger_types
48
- {
49
- :'first_account' => :'String',
50
- :'second_account' => :'String',
51
- :'storage_folder' => :'StorageFolderLocation'
52
- }
53
- end
54
-
55
- # Initializes the object
56
- # @param [Hash] attributes Model attributes in the form of hash
57
- def initialize(attributes = {})
58
- return unless attributes.is_a?(Hash)
59
-
60
- # convert string to symbol for hash key
61
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
62
-
63
- if attributes.has_key?(:'firstAccount')
64
- self.first_account = attributes[:'firstAccount']
65
- end
66
-
67
- if attributes.has_key?(:'secondAccount')
68
- self.second_account = attributes[:'secondAccount']
69
- end
70
-
71
- if attributes.has_key?(:'storageFolder')
72
- self.storage_folder = attributes[:'storageFolder']
73
- end
74
- end
75
-
76
- # Initializes the object
77
- def initialize(first_account=nil, second_account=nil, storage_folder=nil)
78
- self.first_account = first_account
79
- self.second_account = second_account
80
- self.storage_folder = storage_folder
81
- end
82
-
83
- # Show invalid properties with the reasons. Usually used together with valid?
84
- # @return Array for valid properties with the reasons
85
- def list_invalid_properties
86
- invalid_properties = Array.new
87
- if @first_account.nil?
88
- invalid_properties.push('invalid value for "first_account", first_account cannot be nil.')
89
- end
90
-
91
- if @first_account.to_s.length < 1
92
- invalid_properties.push('invalid value for "first_account", the character length must be great than or equal to 1.')
93
- end
94
-
95
- invalid_properties
96
- end
97
-
98
- # Check to see if the all the properties in the model are valid
99
- # @return true if the model is valid
100
- def valid?
101
- return false if @first_account.nil?
102
- return false if @first_account.to_s.length < 1
103
- true
104
- end
105
-
106
- # Custom attribute writer method with validation
107
- # @param [Object] first_account Value to be assigned
108
- def first_account=(first_account)
109
- if first_account.nil?
110
- fail ArgumentError, 'first_account cannot be nil'
111
- end
112
-
113
- if first_account.to_s.length < 1
114
- fail ArgumentError, 'invalid value for "first_account", the character length must be great than or equal to 1.'
115
- end
116
-
117
- @first_account = first_account
118
- end
119
-
120
- # Checks equality by comparing each attribute.
121
- # @param [Object] Object to be compared
122
- def ==(o)
123
- return true if self.equal?(o)
124
- self.class == o.class &&
125
- first_account == o.first_account &&
126
- second_account == o.second_account &&
127
- storage_folder == o.storage_folder
128
- end
129
-
130
- # @see the `==` method
131
- # @param [Object] Object to be compared
132
- def eql?(o)
133
- self == o
134
- end
135
-
136
- # Calculates hash code according to all attributes.
137
- # @return [Fixnum] Hash code
138
- def hash
139
- [first_account, second_account, storage_folder].hash
140
- end
141
-
30
+ # EmailClient accounts request
31
+ class AccountBaseRequest
32
+ # First account storage file name for receiving emails (or universal one)
33
+ # @return [String]
34
+ attr_accessor :first_account
35
+
36
+ # Second account storage file name for sending emails (ignored if first is universal)
37
+ # @return [String]
38
+ attr_accessor :second_account
39
+
40
+ # Storage folder location of account files
41
+ # @return [StorageFolderLocation]
42
+ attr_accessor :storage_folder
43
+
44
+ # Attribute mapping from ruby-style variable name to JSON key.
45
+ def self.attribute_map
46
+ {
47
+ :'first_account' => :'firstAccount',
48
+ :'second_account' => :'secondAccount',
49
+ :'storage_folder' => :'storageFolder'
50
+ }
51
+ end
52
+
53
+ # Attribute type mapping.
54
+ def self.swagger_types
55
+ {
56
+ :'first_account' => :'String',
57
+ :'second_account' => :'String',
58
+ :'storage_folder' => :'StorageFolderLocation'
59
+ }
60
+ end
61
+
62
+ # Initializes the object
63
+ # @param [Hash] attributes Model attributes in the form of hash
64
+ def initialize(attributes = {})
65
+ return unless attributes.is_a?(Hash)
66
+
67
+ # convert string to symbol for hash key
68
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
69
+
70
+ if attributes.has_key?(:'firstAccount')
71
+ self.first_account = attributes[:'firstAccount']
72
+ end
73
+
74
+ if attributes.has_key?(:'secondAccount')
75
+ self.second_account = attributes[:'secondAccount']
76
+ end
77
+
78
+ if attributes.has_key?(:'storageFolder')
79
+ self.storage_folder = attributes[:'storageFolder']
80
+ end
81
+ end
82
+
83
+ # Initializes the object
84
+ # @param [String] first_account First account storage file name for receiving emails (or universal one)
85
+ # @param [String] second_account Second account storage file name for sending emails (ignored if first is universal)
86
+ # @param [StorageFolderLocation] storage_folder Storage folder location of account files
87
+ def initialize(first_account=nil, second_account=nil, storage_folder=nil)
88
+ self.first_account = first_account if first_account
89
+ self.second_account = second_account if second_account
90
+ self.storage_folder = storage_folder if storage_folder
91
+ end
92
+
93
+ # Show invalid properties with the reasons. Usually used together with valid?
94
+ # @return Array for valid properties with the reasons
95
+ def list_invalid_properties
96
+ invalid_properties = Array.new
97
+ if @first_account.nil?
98
+ invalid_properties.push('invalid value for "first_account", first_account cannot be nil.')
99
+ end
100
+
101
+ if @first_account.to_s.length < 1
102
+ invalid_properties.push('invalid value for "first_account", the character length must be great than or equal to 1.')
103
+ end
104
+
105
+ invalid_properties
106
+ end
107
+
108
+ # Check to see if the all the properties in the model are valid
109
+ # @return true if the model is valid
110
+ def valid?
111
+ return false if @first_account.nil?
112
+ return false if @first_account.to_s.length < 1
113
+ true
114
+ end
115
+
116
+ # Custom attribute writer method with validation
117
+ # @param [Object] first_account Value to be assigned
118
+ def first_account=(first_account)
119
+ if first_account.nil?
120
+ fail ArgumentError, 'first_account cannot be nil'
121
+ end
122
+
123
+ if first_account.to_s.length < 1
124
+ fail ArgumentError, 'invalid value for "first_account", the character length must be great than or equal to 1.'
125
+ end
126
+
127
+ @first_account = first_account
128
+ end
129
+
130
+ # Checks equality by comparing each attribute.
131
+ # @param [Object] Object to be compared
132
+ def ==(o)
133
+ return true if self.equal?(o)
134
+ self.class == o.class &&
135
+ first_account == o.first_account &&
136
+ second_account == o.second_account &&
137
+ storage_folder == o.storage_folder
138
+ end
139
+
140
+ # @see the `==` method
141
+ # @param [Object] Object to be compared
142
+ def eql?(o)
143
+ self == o
144
+ end
145
+
146
+ # Calculates hash code according to all attributes.
147
+ # @return [Fixnum] Hash code
148
+ def hash
149
+ [first_account, second_account, storage_folder].hash
150
+ end
151
+
142
152
  # Builds the object from hash
143
153
  # @param [Hash] attributes Model attributes in the form of hash
144
154
  # @return [Object] Returns the model itself
@@ -245,6 +255,6 @@ module AsposeEmailCloud
245
255
  value
246
256
  end
247
257
  end
248
-
258
+
249
259
  end
250
260
  end
@@ -27,87 +27,91 @@
27
27
  require 'date'
28
28
 
29
29
  module AsposeEmailCloud
30
- # Add attachment request
31
- class AddAttachmentRequest
32
- # Storage folder location of document
33
- attr_accessor :document_folder
34
-
35
- # Storage folder location of an attachment
36
- attr_accessor :attachment_folder
37
-
38
- # Attribute mapping from ruby-style variable name to JSON key.
39
- def self.attribute_map
40
- {
41
- :'document_folder' => :'documentFolder',
42
- :'attachment_folder' => :'attachmentFolder'
43
- }
44
- end
45
-
46
- # Attribute type mapping.
47
- def self.swagger_types
48
- {
49
- :'document_folder' => :'StorageFolderLocation',
50
- :'attachment_folder' => :'StorageFolderLocation'
51
- }
52
- end
53
-
54
- # Initializes the object
55
- # @param [Hash] attributes Model attributes in the form of hash
56
- def initialize(attributes = {})
57
- return unless attributes.is_a?(Hash)
58
-
59
- # convert string to symbol for hash key
60
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
61
-
62
- if attributes.has_key?(:'documentFolder')
63
- self.document_folder = attributes[:'documentFolder']
64
- end
65
-
66
- if attributes.has_key?(:'attachmentFolder')
67
- self.attachment_folder = attributes[:'attachmentFolder']
68
- end
69
- end
70
-
71
- # Initializes the object
72
- def initialize(document_folder=nil, attachment_folder=nil)
73
- self.document_folder = document_folder
74
- self.attachment_folder = attachment_folder
75
- end
76
-
77
- # Show invalid properties with the reasons. Usually used together with valid?
78
- # @return Array for valid properties with the reasons
79
- def list_invalid_properties
80
- invalid_properties = Array.new
81
- invalid_properties
82
- end
83
-
84
- # Check to see if the all the properties in the model are valid
85
- # @return true if the model is valid
86
- def valid?
87
- true
88
- end
89
-
90
- # Checks equality by comparing each attribute.
91
- # @param [Object] Object to be compared
92
- def ==(o)
93
- return true if self.equal?(o)
94
- self.class == o.class &&
95
- document_folder == o.document_folder &&
96
- attachment_folder == o.attachment_folder
97
- end
98
-
99
- # @see the `==` method
100
- # @param [Object] Object to be compared
101
- def eql?(o)
102
- self == o
103
- end
104
-
105
- # Calculates hash code according to all attributes.
106
- # @return [Fixnum] Hash code
107
- def hash
108
- [document_folder, attachment_folder].hash
109
- end
110
-
30
+ # Add attachment request
31
+ class AddAttachmentRequest
32
+ # Storage folder location of document
33
+ # @return [StorageFolderLocation]
34
+ attr_accessor :document_folder
35
+
36
+ # Storage folder location of an attachment
37
+ # @return [StorageFolderLocation]
38
+ attr_accessor :attachment_folder
39
+
40
+ # Attribute mapping from ruby-style variable name to JSON key.
41
+ def self.attribute_map
42
+ {
43
+ :'document_folder' => :'documentFolder',
44
+ :'attachment_folder' => :'attachmentFolder'
45
+ }
46
+ end
47
+
48
+ # Attribute type mapping.
49
+ def self.swagger_types
50
+ {
51
+ :'document_folder' => :'StorageFolderLocation',
52
+ :'attachment_folder' => :'StorageFolderLocation'
53
+ }
54
+ end
55
+
56
+ # Initializes the object
57
+ # @param [Hash] attributes Model attributes in the form of hash
58
+ def initialize(attributes = {})
59
+ return unless attributes.is_a?(Hash)
60
+
61
+ # convert string to symbol for hash key
62
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
63
+
64
+ if attributes.has_key?(:'documentFolder')
65
+ self.document_folder = attributes[:'documentFolder']
66
+ end
67
+
68
+ if attributes.has_key?(:'attachmentFolder')
69
+ self.attachment_folder = attributes[:'attachmentFolder']
70
+ end
71
+ end
72
+
73
+ # Initializes the object
74
+ # @param [StorageFolderLocation] document_folder Storage folder location of document
75
+ # @param [StorageFolderLocation] attachment_folder Storage folder location of an attachment
76
+ def initialize(document_folder=nil, attachment_folder=nil)
77
+ self.document_folder = document_folder if document_folder
78
+ self.attachment_folder = attachment_folder if attachment_folder
79
+ end
80
+
81
+ # Show invalid properties with the reasons. Usually used together with valid?
82
+ # @return Array for valid properties with the reasons
83
+ def list_invalid_properties
84
+ invalid_properties = Array.new
85
+ invalid_properties
86
+ end
87
+
88
+ # Check to see if the all the properties in the model are valid
89
+ # @return true if the model is valid
90
+ def valid?
91
+ true
92
+ end
93
+
94
+ # Checks equality by comparing each attribute.
95
+ # @param [Object] Object to be compared
96
+ def ==(o)
97
+ return true if self.equal?(o)
98
+ self.class == o.class &&
99
+ document_folder == o.document_folder &&
100
+ attachment_folder == o.attachment_folder
101
+ end
102
+
103
+ # @see the `==` method
104
+ # @param [Object] Object to be compared
105
+ def eql?(o)
106
+ self == o
107
+ end
108
+
109
+ # Calculates hash code according to all attributes.
110
+ # @return [Fixnum] Hash code
111
+ def hash
112
+ [document_folder, attachment_folder].hash
113
+ end
114
+
111
115
  # Builds the object from hash
112
116
  # @param [Hash] attributes Model attributes in the form of hash
113
117
  # @return [Object] Returns the model itself
@@ -214,6 +218,6 @@ module AsposeEmailCloud
214
218
  value
215
219
  end
216
220
  end
217
-
221
+
218
222
  end
219
223
  end