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
@@ -36,8 +36,8 @@ module AsposeEmailCloud
36
36
  # @param [String] path File path e.g. '/file.ext'
37
37
  # @param [String] storage_name Storage name
38
38
  def initialize(path, storage_name = nil)
39
- @path = path
40
- @storage_name = storage_name
39
+ @path = path if path
40
+ @storage_name = storage_name if storage_name
41
41
  end
42
42
 
43
43
  def to_http_info(api_client)
@@ -36,8 +36,8 @@ module AsposeEmailCloud
36
36
  # @param [String] path Folder path e.g. '/folder'
37
37
  # @param [String] storage_name Storage name
38
38
  def initialize(path, storage_name = nil)
39
- @path = path
40
- @storage_name = storage_name
39
+ @path = path if path
40
+ @storage_name = storage_name if storage_name
41
41
  end
42
42
 
43
43
  def to_http_info(api_client)
@@ -32,16 +32,16 @@ module AsposeEmailCloud
32
32
  # Request model for get_mapi_attachment operation.
33
33
  class GetMapiAttachmentRequestData < EmailRequest
34
34
 
35
- # Get document attachment as file stream
35
+ # Get document attachment as file stream
36
36
  # @param [String] name Document file name
37
37
  # @param [String] attachment Attachment name or index
38
38
  # @param [String] folder Path to folder in storage
39
39
  # @param [String] storage Storage name
40
40
  def initialize(name, attachment, folder = nil, storage = nil)
41
- @name = name
42
- @attachment = attachment
43
- @folder = folder
44
- @storage = storage
41
+ @name = name if name
42
+ @attachment = attachment if attachment
43
+ @folder = folder if folder
44
+ @storage = storage if storage
45
45
  end
46
46
 
47
47
  def to_http_info(api_client)
@@ -32,14 +32,14 @@ module AsposeEmailCloud
32
32
  # Request model for get_mapi_attachments operation.
33
33
  class GetMapiAttachmentsRequestData < EmailRequest
34
34
 
35
- # Get document attachment list
35
+ # Get document attachment list
36
36
  # @param [String] name Document file name
37
37
  # @param [String] folder Path to folder in storage
38
38
  # @param [String] storage Storage name
39
39
  def initialize(name, folder = nil, storage = nil)
40
- @name = name
41
- @folder = folder
42
- @storage = storage
40
+ @name = name if name
41
+ @folder = folder if folder
42
+ @storage = storage if storage
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -32,16 +32,16 @@ module AsposeEmailCloud
32
32
  # Request model for get_mapi_list operation.
33
33
  class GetMapiListRequestData < EmailRequest
34
34
 
35
- # Get document list from storage folder
35
+ # Get document list from storage folder
36
36
  # @param [String] folder Path to folder in storage
37
37
  # @param [String] storage Storage name
38
38
  # @param [Integer] items_per_page Count of items on page
39
39
  # @param [Integer] page_number Page number
40
40
  def initialize(folder = nil, storage = nil, items_per_page = nil, page_number = nil)
41
- @folder = folder
42
- @storage = storage
43
- @items_per_page = items_per_page
44
- @page_number = page_number
41
+ @folder = folder if folder
42
+ @storage = storage if storage
43
+ @items_per_page = items_per_page if items_per_page
44
+ @page_number = page_number if page_number
45
45
  end
46
46
 
47
47
  def to_http_info(api_client)
@@ -32,14 +32,14 @@ module AsposeEmailCloud
32
32
  # Request model for get_mapi_properties operation.
33
33
  class GetMapiPropertiesRequestData < EmailRequest
34
34
 
35
- # Get document properties
35
+ # Get document properties
36
36
  # @param [String] name Document file name
37
37
  # @param [String] folder Path to folder in storage
38
38
  # @param [String] storage Storage name
39
39
  def initialize(name, folder = nil, storage = nil)
40
- @name = name
41
- @folder = folder
42
- @storage = storage
40
+ @name = name if name
41
+ @folder = folder if folder
42
+ @storage = storage if storage
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -32,18 +32,18 @@ module AsposeEmailCloud
32
32
  # Request model for list_email_folders operation.
33
33
  class ListEmailFoldersRequestData < EmailRequest
34
34
 
35
- # Get folders list in email account
35
+ # Get folders list in email account
36
36
  # @param [String] first_account Email account
37
- # @param [String] second_account Additional email account (should be specified for POP/IMAP accounts and should be SMTP account)
37
+ # @param [String] second_account Additional email account (should be specified for POP/IMAP accounts and should be SMTP account)
38
38
  # @param [String] storage Storage name where account file(s) located
39
39
  # @param [String] storage_folder Folder in storage where account file(s) located
40
40
  # @param [String] parent_folder Folder in which subfolders should be listed
41
41
  def initialize(first_account, second_account = nil, storage = nil, storage_folder = nil, parent_folder = nil)
42
- @first_account = first_account
43
- @second_account = second_account
44
- @storage = storage
45
- @storage_folder = storage_folder
46
- @parent_folder = parent_folder
42
+ @first_account = first_account if first_account
43
+ @second_account = second_account if second_account
44
+ @storage = storage if storage
45
+ @storage_folder = storage_folder if storage_folder
46
+ @parent_folder = parent_folder if parent_folder
47
47
  end
48
48
 
49
49
  def to_http_info(api_client)
@@ -32,23 +32,23 @@ module AsposeEmailCloud
32
32
  # Request model for list_email_messages operation.
33
33
  class ListEmailMessagesRequestData < EmailRequest
34
34
 
35
- # Get messages from folder, filtered by query
36
- # The query string should have the following view. The example of a simple expression: &#39;&lt;Field name&gt;&#39; &lt;Comparison operator&gt; &#39;&lt;Field value&gt;&#39;, where &amp;lt;Field Name&amp;gt; - the name of a message field through which filtering is made, &amp;lt;Comparison operator&amp;gt; - comparison operators, as their name implies, allow to compare message field and specified value, &amp;lt;Field value&amp;gt; - value to be compared with a message field. The number of simple expressions can make a compound one, ex.: (&lt;Simple expression 1&gt; &amp; &lt;Simple expression 2&gt;) | &lt;Simple expression 3&gt;, where \&quot;&amp;amp;\&quot; - logical-AND operator, \&quot;|\&quot; - logical-OR operator At present the following values are allowed as a field name (&lt;Field name&gt;): \&quot;To\&quot; - represents a TO field of message, \&quot;Text\&quot; - represents string in the header or body of the message, \&quot;Bcc\&quot; - represents a BCC field of message, \&quot;Body\&quot; - represents a string in the body of message, \&quot;Cc\&quot; - represents a CC field of message, \&quot;From\&quot; - represents a From field of message, \&quot;Subject\&quot; - represents a string in the subject of message, \&quot;InternalDate\&quot; - represents an internal date of message, \&quot;SentDate\&quot; - represents a sent date of message Additionally, the following field names are allowed for IMAP-protocol: \&quot;Answered\&quot; - represents an /Answered flag of message \&quot;Seen\&quot; - represents a /Seen flag of message \&quot;Flagged\&quot; - represents a /Flagged flag of message \&quot;Draft\&quot; - represents a /Draft flag of message \&quot;Deleted\&quot; - represents a Deleted/ flag of message \&quot;Recent\&quot; - represents a Deleted/ flag of message \&quot;MessageSize\&quot; - represents a size (in bytes) of message Additionally, the following field names are allowed for Exchange: \&quot;IsRead\&quot; - Indicates whether the message has been read \&quot;HasAttachment\&quot; - Indicates whether or not the message has attachments \&quot;IsSubmitted\&quot; - Indicates whether the message has been submitted to the Outbox \&quot;ContentClass\&quot; - represents a content class of item Additionally, the following field names are allowed for pst/ost files: \&quot;MessageClass\&quot; - Represents a message class \&quot;ContainerClass\&quot; - Represents a folder container class \&quot;Importance\&quot; - Represents a message importance \&quot;MessageSize\&quot; - represents a size (in bytes) of message \&quot;FolderName\&quot; - represents a folder name \&quot;ContentsCount\&quot; - represents a total number of items in the folder \&quot;UnreadContentsCount\&quot; - represents the number of unread items in the folder. \&quot;Subfolders\&quot; - Indicates whether or not the folder has subfolders \&quot;Read\&quot; - the message is marked as having been read \&quot;HasAttachment\&quot; - the message has at least one attachment \&quot;Unsent\&quot; - the message is still being composed \&quot;Unmodified\&quot; - the message has not been modified since it was first saved (if unsent) or it was delivered (if sent) \&quot;FromMe\&quot; - the user receiving the message was also the user who sent the message \&quot;Resend\&quot; - the message includes a request for a resend operation with a non-delivery report \&quot;NotifyRead\&quot; - the user who sent the message has requested notification when a recipient first reads it \&quot;NotifyUnread\&quot; - the user who sent the message has requested notification when a recipient deletes it before reading or the Message object expires \&quot;EverRead\&quot; - the message has been read at least once The field value (&lt;Field value&gt;) can take the following values: For text fields - any string, For date type fields - the string of \&quot;d-MMM-yyy\&quot; format, ex. \&quot;10-Feb-2009\&quot;, For flags (fields of boolean type) - either \&quot;True\&quot;, or \&quot;False\&quot;
35
+ # Get messages from folder, filtered by query
36
+ # The query string should have the following view. The example of a simple expression: &#39;&lt;Field name&gt;&#39; &lt;Comparison operator&gt; &#39;&lt;Field value&gt;&#39;, where &amp;lt;Field Name&amp;gt; - the name of a message field through which filtering is made, &amp;lt;Comparison operator&amp;gt; - comparison operators, as their name implies, allow to compare message field and specified value, &amp;lt;Field value&amp;gt; - value to be compared with a message field. The number of simple expressions can make a compound one, ex.: (&lt;Simple expression 1&gt; &amp; &lt;Simple expression 2&gt;) | &lt;Simple expression 3&gt;, where \&quot;&amp;amp;\&quot; - logical-AND operator, \&quot;|\&quot; - logical-OR operator At present the following values are allowed as a field name (&lt;Field name&gt;): \&quot;To\&quot; - represents a TO field of message, \&quot;Text\&quot; - represents string in the header or body of the message, \&quot;Bcc\&quot; - represents a BCC field of message, \&quot;Body\&quot; - represents a string in the body of message, \&quot;Cc\&quot; - represents a CC field of message, \&quot;From\&quot; - represents a From field of message, \&quot;Subject\&quot; - represents a string in the subject of message, \&quot;InternalDate\&quot; - represents an internal date of message, \&quot;SentDate\&quot; - represents a sent date of message Additionally, the following field names are allowed for IMAP-protocol: \&quot;Answered\&quot; - represents an /Answered flag of message \&quot;Seen\&quot; - represents a /Seen flag of message \&quot;Flagged\&quot; - represents a /Flagged flag of message \&quot;Draft\&quot; - represents a /Draft flag of message \&quot;Deleted\&quot; - represents a Deleted/ flag of message \&quot;Recent\&quot; - represents a Deleted/ flag of message \&quot;MessageSize\&quot; - represents a size (in bytes) of message Additionally, the following field names are allowed for Exchange: \&quot;IsRead\&quot; - Indicates whether the message has been read \&quot;HasAttachment\&quot; - Indicates whether or not the message has attachments \&quot;IsSubmitted\&quot; - Indicates whether the message has been submitted to the Outbox \&quot;ContentClass\&quot; - represents a content class of item Additionally, the following field names are allowed for pst/ost files: \&quot;MessageClass\&quot; - Represents a message class \&quot;ContainerClass\&quot; - Represents a folder container class \&quot;Importance\&quot; - Represents a message importance \&quot;MessageSize\&quot; - represents a size (in bytes) of message \&quot;FolderName\&quot; - represents a folder name \&quot;ContentsCount\&quot; - represents a total number of items in the folder \&quot;UnreadContentsCount\&quot; - represents the number of unread items in the folder. \&quot;Subfolders\&quot; - Indicates whether or not the folder has subfolders \&quot;Read\&quot; - the message is marked as having been read \&quot;HasAttachment\&quot; - the message has at least one attachment \&quot;Unsent\&quot; - the message is still being composed \&quot;Unmodified\&quot; - the message has not been modified since it was first saved (if unsent) or it was delivered (if sent) \&quot;FromMe\&quot; - the user receiving the message was also the user who sent the message \&quot;Resend\&quot; - the message includes a request for a resend operation with a non-delivery report \&quot;NotifyRead\&quot; - the user who sent the message has requested notification when a recipient first reads it \&quot;NotifyUnread\&quot; - the user who sent the message has requested notification when a recipient deletes it before reading or the Message object expires \&quot;EverRead\&quot; - the message has been read at least once The field value (&lt;Field value&gt;) can take the following values: For text fields - any string, For date type fields - the string of \&quot;d-MMM-yyy\&quot; format, ex. \&quot;10-Feb-2009\&quot;, For flags (fields of boolean type) - either \&quot;True\&quot;, or \&quot;False\&quot;
37
37
  # @param [String] folder A folder in email account
38
38
  # @param [String] query_string A MailQuery search string
39
39
  # @param [String] first_account Email account
40
- # @param [String] second_account Additional email account (should be specified for POP/IMAP accounts and should be SMTP account)
40
+ # @param [String] second_account Additional email account (should be specified for POP/IMAP accounts and should be SMTP account)
41
41
  # @param [String] storage Storage name where account file(s) located
42
42
  # @param [String] storage_folder Folder in storage where account file(s) located
43
43
  # @param [BOOLEAN] recursive Specifies that should message be searched in subfolders recursively
44
44
  def initialize(folder, query_string, first_account, second_account = nil, storage = nil, storage_folder = nil, recursive = nil)
45
- @folder = folder
46
- @query_string = query_string
47
- @first_account = first_account
48
- @second_account = second_account
49
- @storage = storage
50
- @storage_folder = storage_folder
51
- @recursive = recursive
45
+ @folder = folder if folder
46
+ @query_string = query_string if query_string
47
+ @first_account = first_account if first_account
48
+ @second_account = second_account if second_account
49
+ @storage = storage if storage
50
+ @storage_folder = storage_folder if storage_folder
51
+ @recursive = recursive if recursive
52
52
  end
53
53
 
54
54
  def to_http_info(api_client)
@@ -39,11 +39,11 @@ module AsposeEmailCloud
39
39
  # @param [String] dest_storage_name Destination storage name
40
40
  # @param [String] version_id File version ID to move
41
41
  def initialize(src_path, dest_path, src_storage_name = nil, dest_storage_name = nil, version_id = nil)
42
- @src_path = src_path
43
- @dest_path = dest_path
44
- @src_storage_name = src_storage_name
45
- @dest_storage_name = dest_storage_name
46
- @version_id = version_id
42
+ @src_path = src_path if src_path
43
+ @dest_path = dest_path if dest_path
44
+ @src_storage_name = src_storage_name if src_storage_name
45
+ @dest_storage_name = dest_storage_name if dest_storage_name
46
+ @version_id = version_id if version_id
47
47
  end
48
48
 
49
49
  def to_http_info(api_client)
@@ -38,10 +38,10 @@ module AsposeEmailCloud
38
38
  # @param [String] src_storage_name Source storage name
39
39
  # @param [String] dest_storage_name Destination storage name
40
40
  def initialize(src_path, dest_path, src_storage_name = nil, dest_storage_name = nil)
41
- @src_path = src_path
42
- @dest_path = dest_path
43
- @src_storage_name = src_storage_name
44
- @dest_storage_name = dest_storage_name
41
+ @src_path = src_path if src_path
42
+ @dest_path = dest_path if dest_path
43
+ @src_storage_name = src_storage_name if src_storage_name
44
+ @dest_storage_name = dest_storage_name if dest_storage_name
45
45
  end
46
46
 
47
47
  def to_http_info(api_client)
@@ -37,9 +37,9 @@ module AsposeEmailCloud
37
37
  # @param [String] storage_name Storage name
38
38
  # @param [String] version_id File version ID
39
39
  def initialize(path, storage_name = nil, version_id = nil)
40
- @path = path
41
- @storage_name = storage_name
42
- @version_id = version_id
40
+ @path = path if path
41
+ @storage_name = storage_name if storage_name
42
+ @version_id = version_id if version_id
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -32,10 +32,10 @@ module AsposeEmailCloud
32
32
  # Request model for save_mail_account operation.
33
33
  class SaveMailAccountRequestData < EmailRequest
34
34
 
35
- # Create email account file (*.account) with login/password authentication
35
+ # Create email account file (*.account) with login/password authentication
36
36
  # @param [SaveEmailAccountRequest] request Email account information
37
37
  def initialize(request)
38
- @request = request
38
+ @request = request if request
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -32,10 +32,10 @@ module AsposeEmailCloud
32
32
  # Request model for save_mail_o_auth_account operation.
33
33
  class SaveMailOAuthAccountRequestData < EmailRequest
34
34
 
35
- # Create email account file (*.account) with OAuth
35
+ # Create email account file (*.account) with OAuth
36
36
  # @param [SaveOAuthEmailAccountRequest] request Email account information
37
37
  def initialize(request)
38
- @request = request
38
+ @request = request if request
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -32,10 +32,10 @@ module AsposeEmailCloud
32
32
  # Request model for send_email_mime operation.
33
33
  class SendEmailMimeRequestData < EmailRequest
34
34
 
35
- # Send an email specified by MIME in request
35
+ # Send an email specified by MIME in request
36
36
  # @param [SendEmailMimeBaseRequest] request Send email request
37
37
  def initialize(request)
38
- @request = request
38
+ @request = request if request
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -32,10 +32,10 @@ module AsposeEmailCloud
32
32
  # Request model for send_email operation.
33
33
  class SendEmailRequestData < EmailRequest
34
34
 
35
- # Send an email from *.eml file located on storage
35
+ # Send an email from *.eml file located on storage
36
36
  # @param [SendEmailBaseRequest] request Send email request
37
37
  def initialize(request)
38
- @request = request
38
+ @request = request if request
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -32,14 +32,14 @@ module AsposeEmailCloud
32
32
  # Request model for set_email_property operation.
33
33
  class SetEmailPropertyRequestData < EmailRequest
34
34
 
35
- # Set email document property value
35
+ # Set email document property value
36
36
  # @param [String] property_name A property name that should be changed
37
37
  # @param [String] file_name Email document file name
38
- # @param [SetEmailPropertyRequest] request A property that should be changed and optional Storage info to specify where the file located
38
+ # @param [SetEmailPropertyRequest] request A property that should be changed and optional Storage info to specify where the file located
39
39
  def initialize(property_name, file_name, request)
40
- @property_name = property_name
41
- @file_name = file_name
42
- @request = request
40
+ @property_name = property_name if property_name
41
+ @file_name = file_name if file_name
42
+ @request = request if request
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -32,10 +32,10 @@ module AsposeEmailCloud
32
32
  # Request model for set_email_read_flag operation.
33
33
  class SetEmailReadFlagRequestData < EmailRequest
34
34
 
35
- # Sets \&quot;Message is read\&quot; flag
35
+ # Sets \&quot;Message is read\&quot; flag
36
36
  # @param [SetMessageReadFlagAccountBaseRequest] request Message is read request
37
37
  def initialize(request)
38
- @request = request
38
+ @request = request if request
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -35,7 +35,7 @@ module AsposeEmailCloud
35
35
  # Check if storage exists
36
36
  # @param [String] storage_name Storage name
37
37
  def initialize(storage_name)
38
- @storage_name = storage_name
38
+ @storage_name = storage_name if storage_name
39
39
  end
40
40
 
41
41
  def to_http_info(api_client)
@@ -32,12 +32,12 @@ module AsposeEmailCloud
32
32
  # Request model for update_calendar_properties operation.
33
33
  class UpdateCalendarPropertiesRequestData < EmailRequest
34
34
 
35
- # Update calendar file properties
35
+ # Update calendar file properties
36
36
  # @param [String] name iCalendar file name in storage
37
37
  # @param [HierarchicalObjectRequest] request Calendar properties update request
38
38
  def initialize(name, request)
39
- @name = name
40
- @request = request
39
+ @name = name if name
40
+ @request = request if request
41
41
  end
42
42
 
43
43
  def to_http_info(api_client)
@@ -32,14 +32,14 @@ module AsposeEmailCloud
32
32
  # Request model for update_contact_properties operation.
33
33
  class UpdateContactPropertiesRequestData < EmailRequest
34
34
 
35
- # Update contact document properties
36
- # @param [String] format Contact document format
35
+ # Update contact document properties
36
+ # @param [String] format Contact document format Enum, available values: VCard, WebDav, Msg
37
37
  # @param [String] name Contact document file name
38
38
  # @param [HierarchicalObjectRequest] request Properties that should be updated/added
39
39
  def initialize(format, name, request)
40
- @format = format
41
- @name = name
42
- @request = request
40
+ @format = format if format
41
+ @name = name if name
42
+ @request = request if request
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -48,11 +48,6 @@ module AsposeEmailCloud
48
48
  raise ArgumentError, "Missing the required parameter 'format' when calling EmailApi.update_contact_properties"
49
49
  end
50
50
 
51
- # verify enum value
52
- if api_client.config.client_side_validation && !['VCard', 'WebDav', 'Msg'].include?(@format)
53
- raise ArgumentError, "invalid value for 'format', must be one of VCard, WebDav, Msg"
54
- end
55
-
56
51
  # verify the required parameter 'name' is set
57
52
  if api_client.config.client_side_validation && @name.nil?
58
53
  raise ArgumentError, "Missing the required parameter 'name' when calling EmailApi.update_contact_properties"
@@ -32,12 +32,12 @@ module AsposeEmailCloud
32
32
  # Request model for update_mapi_properties operation.
33
33
  class UpdateMapiPropertiesRequestData < EmailRequest
34
34
 
35
- # Update document properties
35
+ # Update document properties
36
36
  # @param [String] name Document file name
37
37
  # @param [HierarchicalObjectRequest] request Properties that should be updated/added
38
38
  def initialize(name, request)
39
- @name = name
40
- @request = request
39
+ @name = name if name
40
+ @request = request if request
41
41
  end
42
42
 
43
43
  def to_http_info(api_client)
@@ -37,9 +37,9 @@ module AsposeEmailCloud
37
37
  # @param [File] file File to upload
38
38
  # @param [String] storage_name Storage name
39
39
  def initialize(path, file, storage_name = nil)
40
- @path = path
41
- @file = file
42
- @storage_name = storage_name
40
+ @path = path if path
41
+ @file = file if file
42
+ @storage_name = storage_name if storage_name
43
43
  end
44
44
 
45
45
  def to_http_info(api_client)
@@ -27,245 +27,299 @@
27
27
  require 'date'
28
28
 
29
29
  module AsposeEmailCloud
30
- # Save email account settings with login/password authentication request
31
- class SaveEmailAccountRequest
32
- # Email account host
33
- attr_accessor :host
34
-
35
- # Email account port
36
- attr_accessor :port
37
-
38
- # Email account login
39
- attr_accessor :login
40
-
41
- # Email account security options
42
- attr_accessor :security_options
43
-
44
- # Email account protocol type
45
- attr_accessor :protocol_type
46
-
47
- # Email account description
48
- attr_accessor :description
49
-
50
- # A storage file location info to store email account
51
- attr_accessor :storage_file
52
-
53
- # Email account password
54
- attr_accessor :password
55
-
56
- # Attribute mapping from ruby-style variable name to JSON key.
57
- def self.attribute_map
58
- {
59
- :'host' => :'host',
60
- :'port' => :'port',
61
- :'login' => :'login',
62
- :'security_options' => :'securityOptions',
63
- :'protocol_type' => :'protocolType',
64
- :'description' => :'description',
65
- :'storage_file' => :'storageFile',
66
- :'password' => :'password'
67
- }
68
- end
69
-
70
- # Attribute type mapping.
71
- def self.swagger_types
72
- {
73
- :'host' => :'String',
74
- :'port' => :'Integer',
75
- :'login' => :'String',
76
- :'security_options' => :'Object',
77
- :'protocol_type' => :'Object',
78
- :'description' => :'String',
79
- :'storage_file' => :'StorageFileLocation',
80
- :'password' => :'String'
81
- }
82
- end
83
-
84
- # Initializes the object
85
- # @param [Hash] attributes Model attributes in the form of hash
86
- def initialize(attributes = {})
87
- return unless attributes.is_a?(Hash)
88
-
89
- # convert string to symbol for hash key
90
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
91
-
92
- if attributes.has_key?(:'host')
93
- self.host = attributes[:'host']
94
- end
95
-
96
- if attributes.has_key?(:'port')
97
- self.port = attributes[:'port']
98
- end
99
-
100
- if attributes.has_key?(:'login')
101
- self.login = attributes[:'login']
102
- end
103
-
104
- if attributes.has_key?(:'securityOptions')
105
- self.security_options = attributes[:'securityOptions']
106
- end
107
-
108
- if attributes.has_key?(:'protocolType')
109
- self.protocol_type = attributes[:'protocolType']
110
- end
111
-
112
- if attributes.has_key?(:'description')
113
- self.description = attributes[:'description']
114
- end
115
-
116
- if attributes.has_key?(:'storageFile')
117
- self.storage_file = attributes[:'storageFile']
118
- end
119
-
120
- if attributes.has_key?(:'password')
121
- self.password = attributes[:'password']
122
- end
123
- end
124
-
125
- # Initializes the object
126
- def initialize(host=nil, port=nil, login=nil, security_options=nil, protocol_type=nil, description=nil, storage_file=nil, password=nil)
127
- self.host = host
128
- self.port = port
129
- self.login = login
130
- self.security_options = security_options
131
- self.protocol_type = protocol_type
132
- self.description = description
133
- self.storage_file = storage_file
134
- self.password = password
135
- end
136
-
137
- # Show invalid properties with the reasons. Usually used together with valid?
138
- # @return Array for valid properties with the reasons
139
- def list_invalid_properties
140
- invalid_properties = Array.new
141
- if @host.nil?
142
- invalid_properties.push('invalid value for "host", host cannot be nil.')
143
- end
144
-
145
- if @host.to_s.length < 1
146
- invalid_properties.push('invalid value for "host", the character length must be great than or equal to 1.')
147
- end
148
-
149
- if @port.nil?
150
- invalid_properties.push('invalid value for "port", port cannot be nil.')
151
- end
152
-
153
- if @login.nil?
154
- invalid_properties.push('invalid value for "login", login cannot be nil.')
155
- end
156
-
157
- if @login.to_s.length < 1
158
- invalid_properties.push('invalid value for "login", the character length must be great than or equal to 1.')
159
- end
160
-
161
- if @security_options.nil?
162
- invalid_properties.push('invalid value for "security_options", security_options cannot be nil.')
163
- end
164
-
165
- if @protocol_type.nil?
166
- invalid_properties.push('invalid value for "protocol_type", protocol_type cannot be nil.')
167
- end
168
-
169
- if @storage_file.nil?
170
- invalid_properties.push('invalid value for "storage_file", storage_file cannot be nil.')
171
- end
172
-
173
- if @password.nil?
174
- invalid_properties.push('invalid value for "password", password cannot be nil.')
175
- end
176
-
177
- if @password.to_s.length < 1
178
- invalid_properties.push('invalid value for "password", the character length must be great than or equal to 1.')
179
- end
180
-
181
- invalid_properties
182
- end
183
-
184
- # Check to see if the all the properties in the model are valid
185
- # @return true if the model is valid
186
- def valid?
187
- return false if @host.nil?
188
- return false if @host.to_s.length < 1
189
- return false if @port.nil?
190
- return false if @login.nil?
191
- return false if @login.to_s.length < 1
192
- return false if @security_options.nil?
193
- return false if @protocol_type.nil?
194
- return false if @storage_file.nil?
195
- return false if @password.nil?
196
- return false if @password.to_s.length < 1
197
- true
198
- end
199
-
200
- # Custom attribute writer method with validation
201
- # @param [Object] host Value to be assigned
202
- def host=(host)
203
- if host.nil?
204
- fail ArgumentError, 'host cannot be nil'
205
- end
206
-
207
- if host.to_s.length < 1
208
- fail ArgumentError, 'invalid value for "host", the character length must be great than or equal to 1.'
209
- end
210
-
211
- @host = host
212
- end
213
-
214
- # Custom attribute writer method with validation
215
- # @param [Object] login Value to be assigned
216
- def login=(login)
217
- if login.nil?
218
- fail ArgumentError, 'login cannot be nil'
219
- end
220
-
221
- if login.to_s.length < 1
222
- fail ArgumentError, 'invalid value for "login", the character length must be great than or equal to 1.'
223
- end
224
-
225
- @login = login
226
- end
227
-
228
- # Custom attribute writer method with validation
229
- # @param [Object] password Value to be assigned
230
- def password=(password)
231
- if password.nil?
232
- fail ArgumentError, 'password cannot be nil'
233
- end
234
-
235
- if password.to_s.length < 1
236
- fail ArgumentError, 'invalid value for "password", the character length must be great than or equal to 1.'
237
- end
238
-
239
- @password = password
240
- end
241
-
242
- # Checks equality by comparing each attribute.
243
- # @param [Object] Object to be compared
244
- def ==(o)
245
- return true if self.equal?(o)
246
- self.class == o.class &&
247
- host == o.host &&
248
- port == o.port &&
249
- login == o.login &&
250
- security_options == o.security_options &&
251
- protocol_type == o.protocol_type &&
252
- description == o.description &&
253
- storage_file == o.storage_file &&
254
- password == o.password
255
- end
256
-
257
- # @see the `==` method
258
- # @param [Object] Object to be compared
259
- def eql?(o)
260
- self == o
261
- end
262
-
263
- # Calculates hash code according to all attributes.
264
- # @return [Fixnum] Hash code
265
- def hash
266
- [host, port, login, security_options, protocol_type, description, storage_file, password].hash
267
- end
268
-
30
+ # Save email account settings with login/password authentication request
31
+ class SaveEmailAccountRequest
32
+ # Email account host
33
+ # @return [String]
34
+ attr_accessor :host
35
+
36
+ # Email account port
37
+ # @return [Integer]
38
+ attr_accessor :port
39
+
40
+ # Email account login
41
+ # @return [String]
42
+ attr_accessor :login
43
+
44
+ # Enum, available values: None, SSLExplicit, SSLImplicit, SSLAuto, Auto
45
+ # @return [String]
46
+ attr_accessor :security_options
47
+
48
+ # Type of connection protocol. Enum, available values: IMAP, POP3, SMTP, EWS, WebDav
49
+ # @return [String]
50
+ attr_accessor :protocol_type
51
+
52
+ # Email account description
53
+ # @return [String]
54
+ attr_accessor :description
55
+
56
+ # A storage file location info to store email account
57
+ # @return [StorageFileLocation]
58
+ attr_accessor :storage_file
59
+
60
+ # Email account password
61
+ # @return [String]
62
+ attr_accessor :password
63
+
64
+ # Attribute mapping from ruby-style variable name to JSON key.
65
+ def self.attribute_map
66
+ {
67
+ :'host' => :'host',
68
+ :'port' => :'port',
69
+ :'login' => :'login',
70
+ :'security_options' => :'securityOptions',
71
+ :'protocol_type' => :'protocolType',
72
+ :'description' => :'description',
73
+ :'storage_file' => :'storageFile',
74
+ :'password' => :'password'
75
+ }
76
+ end
77
+
78
+ # Attribute type mapping.
79
+ def self.swagger_types
80
+ {
81
+ :'host' => :'String',
82
+ :'port' => :'Integer',
83
+ :'login' => :'String',
84
+ :'security_options' => :'String',
85
+ :'protocol_type' => :'String',
86
+ :'description' => :'String',
87
+ :'storage_file' => :'StorageFileLocation',
88
+ :'password' => :'String'
89
+ }
90
+ end
91
+
92
+ # Initializes the object
93
+ # @param [Hash] attributes Model attributes in the form of hash
94
+ def initialize(attributes = {})
95
+ return unless attributes.is_a?(Hash)
96
+
97
+ # convert string to symbol for hash key
98
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
99
+
100
+ if attributes.has_key?(:'host')
101
+ self.host = attributes[:'host']
102
+ end
103
+
104
+ if attributes.has_key?(:'port')
105
+ self.port = attributes[:'port']
106
+ end
107
+
108
+ if attributes.has_key?(:'login')
109
+ self.login = attributes[:'login']
110
+ end
111
+
112
+ if attributes.has_key?(:'securityOptions')
113
+ self.security_options = attributes[:'securityOptions']
114
+ end
115
+
116
+ if attributes.has_key?(:'protocolType')
117
+ self.protocol_type = attributes[:'protocolType']
118
+ end
119
+
120
+ if attributes.has_key?(:'description')
121
+ self.description = attributes[:'description']
122
+ end
123
+
124
+ if attributes.has_key?(:'storageFile')
125
+ self.storage_file = attributes[:'storageFile']
126
+ end
127
+
128
+ if attributes.has_key?(:'password')
129
+ self.password = attributes[:'password']
130
+ end
131
+ end
132
+
133
+ # Initializes the object
134
+ # @param [String] host Email account host
135
+ # @param [Integer] port Email account port
136
+ # @param [String] login Email account login
137
+ # @param [String] security_options Enum, available values: None, SSLExplicit, SSLImplicit, SSLAuto, Auto
138
+ # @param [String] protocol_type Type of connection protocol. Enum, available values: IMAP, POP3, SMTP, EWS, WebDav
139
+ # @param [String] description Email account description
140
+ # @param [StorageFileLocation] storage_file A storage file location info to store email account
141
+ # @param [String] password Email account password
142
+ def initialize(host=nil, port=nil, login=nil, security_options=nil, protocol_type=nil, description=nil, storage_file=nil, password=nil)
143
+ self.host = host if host
144
+ self.port = port if port
145
+ self.login = login if login
146
+ self.security_options = security_options if security_options
147
+ self.protocol_type = protocol_type if protocol_type
148
+ self.description = description if description
149
+ self.storage_file = storage_file if storage_file
150
+ self.password = password if password
151
+ end
152
+
153
+ # Show invalid properties with the reasons. Usually used together with valid?
154
+ # @return Array for valid properties with the reasons
155
+ def list_invalid_properties
156
+ invalid_properties = Array.new
157
+ if @host.nil?
158
+ invalid_properties.push('invalid value for "host", host cannot be nil.')
159
+ end
160
+
161
+ if @host.to_s.length < 1
162
+ invalid_properties.push('invalid value for "host", the character length must be great than or equal to 1.')
163
+ end
164
+
165
+ if @port.nil?
166
+ invalid_properties.push('invalid value for "port", port cannot be nil.')
167
+ end
168
+
169
+ if @login.nil?
170
+ invalid_properties.push('invalid value for "login", login cannot be nil.')
171
+ end
172
+
173
+ if @login.to_s.length < 1
174
+ invalid_properties.push('invalid value for "login", the character length must be great than or equal to 1.')
175
+ end
176
+
177
+ if @security_options.nil?
178
+ invalid_properties.push('invalid value for "security_options", security_options cannot be nil.')
179
+ end
180
+
181
+ if @security_options.to_s.length < 1
182
+ invalid_properties.push('invalid value for "security_options", the character length must be great than or equal to 1.')
183
+ end
184
+
185
+ if @protocol_type.nil?
186
+ invalid_properties.push('invalid value for "protocol_type", protocol_type cannot be nil.')
187
+ end
188
+
189
+ if @protocol_type.to_s.length < 1
190
+ invalid_properties.push('invalid value for "protocol_type", the character length must be great than or equal to 1.')
191
+ end
192
+
193
+ if @storage_file.nil?
194
+ invalid_properties.push('invalid value for "storage_file", storage_file cannot be nil.')
195
+ end
196
+
197
+ if @password.nil?
198
+ invalid_properties.push('invalid value for "password", password cannot be nil.')
199
+ end
200
+
201
+ if @password.to_s.length < 1
202
+ invalid_properties.push('invalid value for "password", the character length must be great than or equal to 1.')
203
+ end
204
+
205
+ invalid_properties
206
+ end
207
+
208
+ # Check to see if the all the properties in the model are valid
209
+ # @return true if the model is valid
210
+ def valid?
211
+ return false if @host.nil?
212
+ return false if @host.to_s.length < 1
213
+ return false if @port.nil?
214
+ return false if @login.nil?
215
+ return false if @login.to_s.length < 1
216
+ return false if @security_options.nil?
217
+ return false if @security_options.to_s.length < 1
218
+ return false if @protocol_type.nil?
219
+ return false if @protocol_type.to_s.length < 1
220
+ return false if @storage_file.nil?
221
+ return false if @password.nil?
222
+ return false if @password.to_s.length < 1
223
+ true
224
+ end
225
+
226
+ # Custom attribute writer method with validation
227
+ # @param [Object] host Value to be assigned
228
+ def host=(host)
229
+ if host.nil?
230
+ fail ArgumentError, 'host cannot be nil'
231
+ end
232
+
233
+ if host.to_s.length < 1
234
+ fail ArgumentError, 'invalid value for "host", the character length must be great than or equal to 1.'
235
+ end
236
+
237
+ @host = host
238
+ end
239
+
240
+ # Custom attribute writer method with validation
241
+ # @param [Object] login Value to be assigned
242
+ def login=(login)
243
+ if login.nil?
244
+ fail ArgumentError, 'login cannot be nil'
245
+ end
246
+
247
+ if login.to_s.length < 1
248
+ fail ArgumentError, 'invalid value for "login", the character length must be great than or equal to 1.'
249
+ end
250
+
251
+ @login = login
252
+ end
253
+
254
+ # Custom attribute writer method with validation
255
+ # @param [Object] security_options Value to be assigned
256
+ def security_options=(security_options)
257
+ if security_options.nil?
258
+ fail ArgumentError, 'security_options cannot be nil'
259
+ end
260
+
261
+ if security_options.to_s.length < 1
262
+ fail ArgumentError, 'invalid value for "security_options", the character length must be great than or equal to 1.'
263
+ end
264
+
265
+ @security_options = security_options
266
+ end
267
+
268
+ # Custom attribute writer method with validation
269
+ # @param [Object] protocol_type Value to be assigned
270
+ def protocol_type=(protocol_type)
271
+ if protocol_type.nil?
272
+ fail ArgumentError, 'protocol_type cannot be nil'
273
+ end
274
+
275
+ if protocol_type.to_s.length < 1
276
+ fail ArgumentError, 'invalid value for "protocol_type", the character length must be great than or equal to 1.'
277
+ end
278
+
279
+ @protocol_type = protocol_type
280
+ end
281
+
282
+ # Custom attribute writer method with validation
283
+ # @param [Object] password Value to be assigned
284
+ def password=(password)
285
+ if password.nil?
286
+ fail ArgumentError, 'password cannot be nil'
287
+ end
288
+
289
+ if password.to_s.length < 1
290
+ fail ArgumentError, 'invalid value for "password", the character length must be great than or equal to 1.'
291
+ end
292
+
293
+ @password = password
294
+ end
295
+
296
+ # Checks equality by comparing each attribute.
297
+ # @param [Object] Object to be compared
298
+ def ==(o)
299
+ return true if self.equal?(o)
300
+ self.class == o.class &&
301
+ host == o.host &&
302
+ port == o.port &&
303
+ login == o.login &&
304
+ security_options == o.security_options &&
305
+ protocol_type == o.protocol_type &&
306
+ description == o.description &&
307
+ storage_file == o.storage_file &&
308
+ password == o.password
309
+ end
310
+
311
+ # @see the `==` method
312
+ # @param [Object] Object to be compared
313
+ def eql?(o)
314
+ self == o
315
+ end
316
+
317
+ # Calculates hash code according to all attributes.
318
+ # @return [Fixnum] Hash code
319
+ def hash
320
+ [host, port, login, security_options, protocol_type, description, storage_file, password].hash
321
+ end
322
+
269
323
  # Builds the object from hash
270
324
  # @param [Hash] attributes Model attributes in the form of hash
271
325
  # @return [Object] Returns the model itself
@@ -372,6 +426,6 @@ module AsposeEmailCloud
372
426
  value
373
427
  end
374
428
  end
375
-
429
+
376
430
  end
377
431
  end