Click or drag to resize
MimeKit

CryptographyContextExportAsync Method

Asynchronously exports the keys for the specified mailboxes.

Namespace: MimeKit.Cryptography
Assembly: MimeKit (in MimeKit.dll) Version: 4.7.1
Syntax
C#
public abstract Task<MimePart> ExportAsync(
	IEnumerable<MailboxAddress> mailboxes,
	CancellationToken cancellationToken = default
)

Parameters

mailboxes  IEnumerableMailboxAddress
The mailboxes.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskMimePart
A new MimePart instance containing the exported keys.

Implements

ICryptographyContextExportAsync(IEnumerableMailboxAddress, CancellationToken)
Exceptions
ExceptionCondition
ArgumentNullExceptionmailboxes is null.
ArgumentExceptionmailboxes was empty.
NotSupportedException Exporting keys is not supported by this cryptography context.
OperationCanceledException The operation was cancelled via the cancellation token.
Remarks
Asynchronously exports the keys for the specified mailboxes.
See Also