Click or drag to resize
MimeKit

MailStoreEnableQuickResyncAsync Method

Asynchronously enable the quick resynchronization feature.

Namespace:  MailKit
Assembly:  MailKit (in MailKit.dll) Version: 2.10.0
Syntax
C#
public abstract Task EnableQuickResyncAsync(
	CancellationToken cancellationToken = null
)

Parameters

cancellationToken (Optional)
Type: System.ThreadingCancellationToken
The cancellation token.

Return Value

Type: Task
An asynchronous task context.

Implements

IMailStoreEnableQuickResyncAsync(CancellationToken)
Exceptions
ExceptionCondition
ObjectDisposedException The MailStore has been disposed.
ServiceNotConnectedException The MailStore is not connected.
ServiceNotAuthenticatedException The MailStore is not authenticated.
InvalidOperationException Quick resynchronization needs to be enabled before selecting a folder.
NotSupportedException The mail store does not support quick resynchronization.
OperationCanceledException The operation was canceled via the cancellation token.
IOException An I/O error occurred.
ProtocolException A protocol error occurred.
CommandException The command failed.
Remarks

Enables quick resynchronization when a folder is opened using the Open(FolderAccess, UInt32, UInt64, IListUniqueId, CancellationToken) method.

If this feature is enabled, the MessageExpunged event is replaced with the MessagesVanished event.

This method needs to be called immediately after calling one of the Authenticate methods, before opening any folders.

See Also