Click or drag to resize
MimeKit

OpenPgpContextExportAsync(PgpPublicKeyRingBundle, CancellationToken) Method

Asynchronously export the specified public keys.

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

Parameters

keys  PgpPublicKeyRingBundle
The public keys to export.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskMimePart
A new MimePart instance containing the exported public keys.
Exceptions
ExceptionCondition
ArgumentNullExceptionkeys is null.
OperationCanceledException The operation was canceled via the cancellation token.
Remarks
Asynchronously exports the specified public keys.
See Also