Click or drag to resize
MimeKit

IMailFolderSortAsync(SearchOptions, SearchQuery, IListOrderBy, CancellationToken) Method

Asynchronously sort messages matching the specified query.

Namespace: MailKit
Assembly: MailKit (in MailKit.dll) Version: 4.7.1
Syntax
C#
Task<SearchResults> SortAsync(
	SearchOptions options,
	SearchQuery query,
	IList<OrderBy> orderBy,
	CancellationToken cancellationToken = default
)

Parameters

options  SearchOptions
The search options.
query  SearchQuery
The search query.
orderBy  IListOrderBy
The sort order.
cancellationToken  CancellationToken  (Optional)
The cancellation token.

Return Value

TaskSearchResults
The search results.
Remarks
Asynchronously searches the folder for messages matching the specified query, returning the search results in the specified sort order.
See Also