GnuPGContextExportAsync(IEnumerableMailboxAddress, CancellationToken) Method

Asynchronously export the public keys for the specified mailboxes.

Definition

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

Parameters

mailboxes  IEnumerableMailboxAddress
The mailboxes associated with the public keys to export.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskMimePart
A new MimePart instance containing the exported public keys.

Implements

ICryptographyContextExportAsync(IEnumerableMailboxAddress, CancellationToken)

Remarks

Asynchronously exports the public keys for the specified mailboxes.

Exceptions

ArgumentNullException mailboxes is .
ArgumentException mailboxes was empty.
OperationCanceledException The operation was canceled via the cancellation token.

See Also