Table of Contents

Method ReadAsync

Namespace
MailFathom.Application.Folders
Assembly
MailFathom.Application.dll

ReadAsync(MailFolderSelection, CancellationToken)

Reads the folders of every served account that take part in one thing.

Task<IReadOnlyList<MailFolderIdentity>> ReadAsync(MailFolderSelection selection, CancellationToken cancellationToken)

Parameters

selection MailFolderSelection

What the folders take part in.

cancellationToken CancellationToken

Cancels the read.

Returns

Task<IReadOnlyList<MailFolderIdentity>>

The folders, ordered by account and alias; empty when no served account has one.

Exceptions

ArgumentOutOfRangeException

Thrown when selection is not a defined member.

ReadAsync(MailFolderSelection, IReadOnlyCollection<MailAccountId>, CancellationToken)

Reads the folders of the named accounts that take part in one thing.

Task<IReadOnlyList<MailFolderIdentity>> ReadAsync(MailFolderSelection selection, IReadOnlyCollection<MailAccountId> accounts, CancellationToken cancellationToken)

Parameters

selection MailFolderSelection

What the folders take part in.

accounts IReadOnlyCollection<MailAccountId>

The accounts asked about; one this deployment does not serve contributes nothing.

cancellationToken CancellationToken

Cancels the read.

Returns

Task<IReadOnlyList<MailFolderIdentity>>

The folders, ordered by account and alias.

Remarks

The shape a read acting for one user takes, which narrows by the accounts that user is assigned and has no use for anybody else's folders.

Exceptions

ArgumentNullException

Thrown when accounts is null.

ArgumentOutOfRangeException

Thrown when selection is not a defined member.