Click or drag to resize
MimeKit

IMailFolderSortAsync(IListUniqueId, SearchQuery, IListOrderBy, CancellationToken) Method

Asynchronously sort messages matching the specified query.

Namespace: MailKit
Assembly: MailKit (in MailKit.dll) Version: 4.3.0
Syntax
C#
Task<IList<UniqueId>> SortAsync(
	IList<UniqueId> uids,
	SearchQuery query,
	IList<OrderBy> orderBy,
	CancellationToken cancellationToken = default
)

Parameters

uids  IListUniqueId
The subset of UIDs
query  SearchQuery
The search query.
orderBy  IListOrderBy
The sort order.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskIListUniqueId
An array of matching UIDs in the specified sort order.
Remarks
The returned array of unique identifiers will be sorted in the preferred order and can be used with GetMessage(UniqueId, CancellationToken, ITransferProgress).
See Also