The Imap type exposes the following members.
Methods
| Name | Description | |
|---|---|---|
| Attach(Socket) |
Attaches client to specified socket.
(Inherited from TcpTextClient.) | |
| Attach(Socket, Boolean) |
Attaches client to specified socket.
(Inherited from TcpTextClient.) | |
| AttachSSL |
Attaches client to specified socket.
(Inherited from TcpTextClient.) | |
| Capability |
Sends CAPABILITY command.
| |
| Close()()()() |
Issues quit command (CloseCommand()()()() method), closes the connection, disposes the object.
(Inherited from TcpTextClient.) | |
| Close(Boolean) |
Issues quit command (CloseCommand()()()() method) and closes the connection.
(Inherited from TcpTextClient.) | |
| CloseCommand |
Sends the LOGOUT command.
(Overrides TcpTextClient..::..CloseCommand()()()().) | |
| CloseCurrentFolder |
Issues CLOSE command to the server.
Unless Examine was used to open folder, CLOSE command permanently removes all messages that have the Deleted flag set from the currently selected folder,
and returns to the authenticated state from the selected state (no folder is selected).
| |
| Connect(String) |
Connects to IMAP server on port 143. Use ConnectSSL(String) when SSL connection is needed.
| |
| Connect(IPEndPoint, Boolean) |
Connects to server.
(Inherited from TcpTextClient.) | |
| Connect(String, Int32) |
Connects to server. Use ConnectSSL(String, Int32) when SSL connection is needed.
(Inherited from TcpTextClient.) | |
| Connect(IPAddress, Int32, Boolean) |
Connects to server.
(Inherited from TcpTextClient.) | |
| Connect(String, Int32, Boolean) |
Connects to server.
(Inherited from TcpTextClient.) | |
| ConnectSSL(String) |
Connects to IMAP server using SSL on port 993.
| |
| ConnectSSL(String, Int32) |
Connects to server using SSL.
(Inherited from TcpTextClient.) | |
| Copy(List<(Of <<'(Int64>)>>), FolderInfo) |
Copies the specified messages to the specified destination folder (mailbox).
| |
| Copy(List<(Of <<'(Int64>)>>), String) |
Copies the specified messages to the specified destination folder (mailbox).
| |
| Copy(Int64, FolderInfo) |
Copies the specified message to the specified destination folder (mailbox).
| |
| Copy(Int64, String) |
Copies the specified message to the specified destination folder (mailbox).
| |
| CopyByUID(List<(Of <<'(Int64>)>>), FolderInfo) |
Copies the specified messages to the specified destination folder (mailbox).
| |
| CopyByUID(List<(Of <<'(Int64>)>>), String) |
Copies the specified messages to the specified destination folder (mailbox).
| |
| CopyByUID(Int64, FolderInfo) |
Copies the specified message to the specified destination folder (mailbox).
| |
| CopyByUID(Int64, String) |
Copies the specified message to the specified destination folder (mailbox).
| |
| CreateFolder |
Creates a folder (mailbox) with the given name.
| |
| DeleteFolder |
Permanently removes a folder (mailbox) with the given name.
| |
| DeleteMessage(List<(Of <<'(Int64>)>>)) |
Deletes messages specified by the messageNumbers. Issues EXPUNGE command after.
| |
| DeleteMessage(Int64) |
Deletes message specified by the messageNumber. Issues EXPUNGE command after.
| |
| DeleteMessageByUID(List<(Of <<'(Int64>)>>)) |
Deletes message specified by the uids. Issues EXPUNGE command after.
| |
| DeleteMessageByUID(Int64) |
Deletes message specified by the uid. Issues EXPUNGE command after.
| |
| Dispose |
Releases all resources acquired by this object. Closes connection, without issuing any quit commands.
(Inherited from TcpTextClient.) | |
| Equals | (Inherited from Object.) | |
| Examine(String) |
Selects specified folder (mailbox) as the current read-only folder so that messages inside can be accessed.
Examine command will not reset the Recent flag
| |
| Examine(FolderInfo) |
Selects specified folder (mailbox) as the current read-only folder so that messages inside can be accessed.
Examine command will not reset the Recent flag.
| |
| ExamineInbox |
Selects 'INBOX' as a current read-only folder (mailbox) so that messages inside can be accessed.
Examine command will not reset the Recent flag
| |
| Finalize |
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.) | |
| FlagMessage(List<(Of <<'(Int64>)>>), Flag) |
Flags the messages with specified flag.
| |
| FlagMessage(Int64, Flag) |
Flags the message with specified flag.
| |
| FlagMessageByUID(List<(Of <<'(Int64>)>>), Flag) |
Flags the messages with specified flag.
| |
| FlagMessageByUID(Int64, Flag) |
Flags the message with specified flag.
| |
| GetAll |
Gets UIDS of all messages in the current folder (mailbox). Equivalent to Search(Expression.All())
| |
| GetBodyStructure(List<(Of <<'(Int64>)>>)) |
Gets the structure of the specified message. Does not set the Seen flag.
| |
| GetBodyStructure(Int64) |
Gets the structure of the specified message. Does not set the Seen flag.
| |
| GetBodyStructureByUID(List<(Of <<'(Int64>)>>)) |
Gets the structure of the specified message. Does not set the Seen flag.
| |
| GetBodyStructureByUID(Int64) |
Gets the structure of the specified message.
| |
| GetEnvelope(List<(Of <<'(Int64>)>>)) | ||
| GetEnvelope(Int64) | ||
| GetEnvelopeByUID(List<(Of <<'(Int64>)>>)) | ||
| GetEnvelopeByUID(Int64) | ||
| GetFlags(List<(Of <<'(Int64>)>>)) |
Gets flags for the specified email messages from server. Does not set the Seen.
| |
| GetFlags(Int64) |
Gets flags for the specified email message from server. Does not set the Seen.
| |
| GetFlagsByUID(List<(Of <<'(Int64>)>>)) |
Gets flags for the specified email messages from server. Does not set the Seen.
| |
| GetFlagsByUID(Int64) |
Gets flags for the specified email message from server. Does not set the Seen.
| |
| GetFolders()()()() |
Lists all folders (mailboxes) starting from root.
Folders starting with '#' are usually shared between users. You can use GetNamespaces()()()() to obtain information about shared folders.
| |
| GetFolders(String) |
Lists all folders (mailboxes) under specified folder (mailbox).
| |
| GetFolders(FolderInfo) |
Lists all folders (mailboxes) under specified folder (mailbox).
| |
| GetFoldersOneLevelDown()()()() |
Lists folders (mailboxes) starting from root. Only direct children are returned.
| |
| GetFoldersOneLevelDown(String) |
Lists all folders (mailboxes) under specified folder (mailbox). Only direct children are returned.
| |
| GetFoldersOneLevelDown(FolderInfo) |
Lists all folders (mailboxes) under specified folder (mailbox). Only direct children are returned.
| |
| GetHashCode |
Serves as a hash function for a particular type.
(Inherited from Object.) | |
| GetHeaders(List<(Of <<'(Int64>)>>)) |
Gets all headers of the specified email messages from server. Use MailBuilder to create IMail object.
| |
| GetHeaders(Int64) |
Gets all headers of the specified mail message from server. Use MailBuilder to create IMail object.
| |
| GetHeadersByUID(List<(Of <<'(Int64>)>>)) |
Gets all headers of the specified email messages from server. Use MailBuilder to create IMail object.
| |
| GetHeadersByUID(Int64) |
Gets all headers of the specified mail message from server. Use MailBuilder to create IMail object.
| |
| GetMessage |
Gets specified mail message from server. Use MailBuilder to create IMail object.
This method sets the Seen unless folder is selected with Examine(String), Examine(FolderInfo) or ExamineInbox()()()().
| |
| GetMessageByUID |
Gets specified mail message from server. Use MailBuilder to create IMail object.
This method sets the Seen unless folder is selected with Examine(String), Examine(FolderInfo) or ExamineInbox()()()().
| |
| GetMessageInfo(List<(Of <<'(Int64>)>>)) |
Gets message information for the specified messages. Does not set the Seen flag.
| |
| GetMessageInfo(Int64) |
Gets message information for the specified message. Does not set the Seen flag.
| |
| GetMessageInfoByUID(List<(Of <<'(Int64>)>>)) |
Gets message information for the specified messages. Does not set the Seen flag.
| |
| GetMessageInfoByUID(Int64) |
Gets message information for the specified message. Does not set the Seen flag.
| |
| GetMimePart |
Gets the data for specified part.
| |
| GetMimePartByUID |
Gets the data for specified part.
| |
| GetMimePartText |
Gets the text data for specified part.
| |
| GetMimePartTextByUID |
Gets the text data for specified part.
| |
| GetNamespaces |
Lists all namespaces available for this user.
Not all servers support Namespace. You can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| GetQuota |
Gets quota with specified name.
Not all servers support Quota, you can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| GetQuotaRoot |
Gets quotas for specified folder.
Not all servers support Quota, you can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| GetServerGreeting |
Override this function to get server's greeting.
(Overrides TcpTextClient..::..GetServerGreeting()()()().) | |
| GetSpecificHeaders(List<(Of <<'(Int64>)>>), array<String>[]()[][]) |
Gets specific headers of the specified email messages from server.
| |
| GetSpecificHeaders(Int64, array<String>[]()[][]) |
Gets specific headers of the specified email message from server.
| |
| GetSpecificHeadersByUID(List<(Of <<'(Int64>)>>), array<String>[]()[][]) |
Gets specific headers of the specified email messages from server.
| |
| GetSpecificHeadersByUID(Int64, array<String>[]()[][]) |
Gets specific headers of the specified email message from server.
| |
| GetSubscribedFolders()()()() |
Lists all folders (mailboxes) user is subscribed to.
| |
| GetSubscribedFolders(String) |
Lists all folders (mailboxes) user is subscribed to starting from specified folder.
| |
| GetSubscribedFolders(FolderInfo) |
Lists all folders (mailboxes) user is subscribed to starting from specified folder.
| |
| GetType |
Gets the Type of the current instance.
(Inherited from Object.) | |
| GmailGetLabels(List<(Of <<'(Int64>)>>)) |
Gets Gmail labels for the specified email messages from server. Does not set the Seen.
| |
| GmailGetLabels(Int64) |
Gets Gmail labels for the specified email message from server. Does not set the Seen.
| |
| GmailGetLabelsByUID(List<(Of <<'(Int64>)>>)) |
Gets Gmail labels for the specified email messages from server. Does not set the Seen.
| |
| GmailGetLabelsByUID(Int64) |
Gets Gmail labels for the specified email message from server. Does not set the Seen.
You can label message using method.
| |
| GmailLabelMessage(List<(Of <<'(Int64>)>>), List<(Of <<'(String>)>>)) |
Labels the messages with specified labels.
| |
| GmailLabelMessage(List<(Of <<'(Int64>)>>), String) |
Labels the messages with specified label.
| |
| GmailLabelMessage(Int64, List<(Of <<'(String>)>>)) |
Labels the messages with specified labels.
| |
| GmailLabelMessage(Int64, String) |
Labels the message with specified label.
| |
| GmailLabelMessageByUID(List<(Of <<'(Int64>)>>), List<(Of <<'(String>)>>)) |
Labels the messages with specified labels.
| |
| GmailLabelMessageByUID(List<(Of <<'(Int64>)>>), String) |
Labels the messages with specified label.
| |
| GmailLabelMessageByUID(Int64, List<(Of <<'(String>)>>)) |
Labels the messages with specified labels.
| |
| GmailLabelMessageByUID(Int64, String) |
Labels the message with specified label.
| |
| GmailUnlabelMessage(List<(Of <<'(Int64>)>>), String) |
Removes specified label from messages.
| |
| GmailUnlabelMessage(Int64, String) |
Removes specified label from the message.
| |
| GmailUnlabelMessageByUID(List<(Of <<'(Int64>)>>), String) |
Removes specified label from messages.
| |
| GmailUnlabelMessageByUID(Int64, String) |
Removes specified label from the message.
| |
| Idle()()()() |
Sends IDLE command.
This method hangs until server announces new event in current folder or until StopIdle()()()() command is issued.
Not all servers support Idle. You can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| Idle(TimeSpan) |
Sends IDLE command.
This method hangs until server announces new event in current folder or until StopIdle()()()() command is issued.
Not all servers support Idle. You can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| Login |
Logs user in using LOGIN command.
When LOGIN command is disabled by including the LOGINDISABLED capability this method tries to log-in using UseBestLogin(String, String).
Unless SSL connection is used this method sends the password in clear text.
You can check which methods remote server supports using SupportedAuthenticationMethods()()()() method.
| |
| LoginCRAM |
Logs user in using AUTHENTICATE CRAM-MD5 command. This method does NOT send the password in clear text.
You can check which methods remote server supports using SupportedAuthenticationMethods()()()() method.
| |
| LoginDIGEST |
Logs user in using AUTHENTICATE DIGEST-MD5 command. This method does NOT send the password in clear text.
You can check which methods remote server supports using SupportedAuthenticationMethods()()()() method.
| |
| LoginOAUTH |
Logs user in using AUTHENTICATE XOAUTH command. This method does NOT send the password.
You can use OAuth class to create the key.
You can check which methods remote server supports using SupportedAuthenticationMethods()()()() method.
| |
| LoginPLAIN(String, String) |
Logs user in using AUTHENTICATE PLAIN command. This method sends the password in clear text (BASE64), unless SSL connection is used.
| |
| LoginPLAIN(String, String, String) |
Logs user in using AUTHENTICATE PLAIN command. This method sends the password in clear text (BASE64), unless SSL connection is used.
| |
| MarkMessageSeen(List<(Of <<'(Int64>)>>)) |
Flags message with Seen flag.
| |
| MarkMessageSeen(Int64) |
Flags message with Seen flag.
| |
| MarkMessageSeenByUID(List<(Of <<'(Int64>)>>)) |
Flags message with Seen flag.
| |
| MarkMessageSeenByUID(Int64) |
Flags message with Seen flag.
| |
| MarkMessageUnseen(List<(Of <<'(Int64>)>>)) |
Removes Seen flag from the message.
| |
| MarkMessageUnseen(Int64) |
Removes Seen flag from the message.
| |
| MarkMessageUnseenByUID(List<(Of <<'(Int64>)>>)) |
Removes Seen flag from the message.
| |
| MarkMessageUnseenByUID(Int64) |
Removes Seen flag from the message.
| |
| MemberwiseClone |
Creates a shallow copy of the current Object.
(Inherited from Object.) | |
| Move(List<(Of <<'(Int64>)>>), FolderInfo) |
Moves the specified messages to the specified destination folder (mailbox).
| |
| Move(List<(Of <<'(Int64>)>>), String) |
Moves the specified messages to the specified destination folder (mailbox).
| |
| Move(Int64, FolderInfo) |
Moves the specified message to the specified destination folder (mailbox).
| |
| Move(Int64, String) |
Moves the specified message to the specified destination folder (mailbox).
| |
| MoveByUID(List<(Of <<'(Int64>)>>), FolderInfo) |
Moves the specified messages to the specified destination folder (mailbox).
| |
| MoveByUID(List<(Of <<'(Int64>)>>), String) |
Moves the specified messages to the specified destination folder (mailbox).
| |
| MoveByUID(Int64, FolderInfo) |
Moves the specified message to the specified destination folder (mailbox).
| |
| MoveByUID(Int64, String) |
Moves the specified message to the specified destination folder (mailbox).
| |
| Noop |
Always succeeds. It does nothing.
Can be used as a periodic poll for new messages - updates FolderStatus returned by last Select(String), Select(FolderInfo) command.
Can also be used to reset any inactivity auto-logout timer on the server.
| |
| NumberSearch |
Gets numbers of all messages that match specified criteria.
Use And(array<ICriterion>[]()[][]), Or(ICriterion, ICriterion) and other Expression methods to create a valid query.
You can also pass SimpleImapQuery to this method.
| |
| NumberSearchFlag |
Gets numbers of all messages in the current folder (mailbox) with specified flag.
Equivalent to Search().Where(Expression.HasFlag(flag)).ResultsAs(ResultType.Numbers)
| |
| PeekHeaders |
Gets headers of the specified mail message from server. Use MailBuilder to create IMail object. Does not set the Seen.
| |
| PeekHeadersByUID |
Gets headers of the specified mail message from server. Use MailBuilder to create IMail object. Does not set the Seen.
| |
| PeekMessage |
Gets specified mail message from server. This method in contrast to GetMessage(Int64) does not set the Seen.
Use MailBuilder to create IMail object.
| |
| PeekMessageByUID |
Gets specified mail message from server. This method in contrast to GetMessage(Int64) does not set the Seen.
Use MailBuilder to create IMail object.
| |
| PeekMimePart |
Peeks the data for specified part. Does not set the Seen flag.
| |
| PeekMimePartByUID |
Peeks the data for specified part. Does not set the Seen flag.
| |
| PeekMimePartText |
Peeks the text data for specified part. Does not set the Seen flag.
| |
| PeekMimePartTextByUID |
Peeks the text data for specified part. Does not set the Seen flag.
| |
| PeekSpecificHeaders(List<(Of <<'(Int64>)>>), array<String>[]()[][]) |
Gets specific headers of the specified email messages from server. Does not set the Seen.
| |
| PeekSpecificHeaders(Int64, array<String>[]()[][]) |
Gets specific headers of the specified email message from server. Does not set the Seen.
| |
| PeekSpecificHeadersByUID(List<(Of <<'(Int64>)>>), array<String>[]()[][]) |
Gets specific headers of the specified email messages from server. Does not set the Seen.
| |
| PeekSpecificHeadersByUID(Int64, array<String>[]()[][]) |
Gets specific headers of the specified email message from server. Does not set the Seen.
| |
| ReceiveResponse |
Receives the response ending with specified request tag.
| |
| RenameFolder |
Changes the name of a folder (mailbox).
| |
| Search()()()() |
Creates new search query.
| |
| Search(ICriterion) |
Gets UIDS of all messages that match specified search criteria using server-side searching.
Use And(array<ICriterion>[]()[][]), Or(ICriterion, ICriterion) and other Expression methods to create a valid query.
You can also pass SimpleImapQuery to this method.
| |
| SearchFlag |
Gets UIDS of all messages in the current folder (mailbox) with specified flag.
Equivalent to Search(Expression.HasFlag(flag))
| |
| Select(String) | ||
| Select(FolderInfo) | ||
| SelectInbox | ||
| Send |
Sends the text command to server.
Adds "\r\n" to the command.
(Inherited from TcpTextClient.) | |
| SendCommand(String) |
Sends command and waits for the server response.
| |
| SendCommand(String, Boolean) |
Sends command and waits for the server response.
| |
| SendYahooIDCommand |
Sends Yahoo's specific ID command ('ID ("GUID" "1")').
This command is required to access yahoo.
This command is sent automatically on connection when the host address contains "yahoo" string.
| |
| StartTLS |
Sends 'STARTTLS' command and initializes SSL connection.
Not all servers support StartTLS. You can check which extensions remote server supports using SupportedExtensions()()()() method.
| |
| Status(String) |
The STATUS command requests the status of the indicated mailbox.
It does not change the currently selected mailbox, nor does it affect the state of any messages in the queried mailbox (messages don't lose the Recent) flag.
This command MUST NOT be used as a "check for new messages in the selected mailbox" operation
(You should rather use FolderStatus and Noop()()()() or UIDNext) or SearchFlag(Flag)).
STATUS command is not guaranteed to be fast in its response.
| |
| Status(FolderInfo) |
The STATUS command requests the status of the indicated mailbox.
It does not change the currently selected mailbox, nor does it affect the state of any messages in the queried mailbox (messages don't lose the Recent) flag.
This command MUST NOT be used as a "check for new messages in the selected mailbox" operation
(You should rather use FolderStatus and Noop()()()() or UIDNext) or SearchFlag(Flag)).
STATUS command is not guaranteed to be fast in its response.
| |
| StopIdle |
Stops IDLE command started by Idle()()()() or Idle(TimeSpan) method.
This method is thread-safe.
| |
| SubscribeFolder(String) |
Subscribes user to specified folder.
| |
| SubscribeFolder(FolderInfo) |
Subscribes user to specified folder.
| |
| SupportedAuthenticationMethods |
Lists authentication methods supported by the remote server.
| |
| SupportedExtensions |
Lists extensions supported by the remote server (e.g. SORT, XLIST, UIDPLUS)
| |
| SupportedThreadMethods |
Lists threading methods supported by the remote server.
| |
| SwitchToSSL |
Switches to SSL stream, authenticates as client.
(Inherited from TcpTextClient.) | |
| Thread(ThreadMethod) |
Creates new threading query.
| |
| Thread(ThreadMethod, ICriterion) |
Gets threaded messages, that match specified search criteria, using server-side threading.
| |
| ToString | (Inherited from Object.) | |
| UnflagMessage(List<(Of <<'(Int64>)>>), Flag) |
Removes specified flag from messages.
| |
| UnflagMessage(Int64, Flag) |
Removes specified flag from the message.
| |
| UnflagMessageByUID(List<(Of <<'(Int64>)>>), Flag) |
Removes specified flag from messages.
| |
| UnflagMessageByUID(Int64, Flag) |
Removes specified flag from the message.
| |
| UnsubscribeFolder(String) |
Unsubscribes user from specified folder.
| |
| UnsubscribeFolder(FolderInfo) |
Unsubscribes user from specified folder.
| |
| UploadMessage(String, IMail) |
Uploads message to specified folder (mailbox). Uploaded message has Seen set.
Internal date of the resulting message is set to the current date and time.
| |
| UploadMessage(String, String) |
Uploads message to specified folder (mailbox). Uploaded message has Seen set.
Internal date of the resulting message is set to the current date and time.
| |
| UploadMessage(FolderInfo, IMail) |
Uploads message to specified folder (mailbox). Uploaded message has Seen set.
Internal date of the resulting message is set to the current date and time.
| |
| UploadMessage(FolderInfo, String) |
Uploads message to specified folder (mailbox). Uploaded message has Seen set.
Internal date of the resulting message is set to the current date and time.
| |
| UploadMessage(String, IMail, UploadMessageInfo) |
Uploads message to specified folder (mailbox).
| |
| UploadMessage(String, String, UploadMessageInfo) |
Uploads message to specified folder (mailbox).
| |
| UploadMessage(FolderInfo, IMail, UploadMessageInfo) |
Uploads message to specified folder (mailbox).
| |
| UploadMessage(FolderInfo, String, UploadMessageInfo) |
Uploads message to specified folder (mailbox).
| |
| UseBestLogin |
Logs user in using best available method.
When no AUTH capability is found, this method switches to SSL (StartTLS()()()()) and tries again.
|