Click or drag to resize
MimeKit

MailFolderOnMessageSummaryFetched Method

Raise the message summary fetched event.

Namespace: MailKit
Assembly: MailKit (in MailKit.dll) Version: 4.3.0
Syntax
C#
protected virtual void OnMessageSummaryFetched(
	IMessageSummary message
)

Parameters

message  IMessageSummary
The message summary.
Remarks

Raises the message summary fetched event.

When multiple message summaries are being fetched from a remote folder, it is possible that the connection will drop or some other exception will occur, causing the Fetch method to fail and lose all of the data that has been downloaded up to that point, requiring the client to request the same set of message summaries all over again after it reconnects. This is obviously inefficient. To alleviate this potential problem, this event will be emitted as soon as the IMailFolder successfully parses each untagged FETCH response from the server, allowing the client to commit this data immediately to its local cache.

Note  Note
Depending on the IMAP server, it is possible that OnMessageSummaryFetched(IMessageSummary) will be invoked for the same message multiple times if the IMAP server happens to split the requested fields into multiple untagged FETCH responses. Use the Fields property to determine which fIMessageSummary properties have been populated.
See Also