Table of Contents

Method ReadAsync

Namespace
MailFathom.Application.Discovery.Runs
Assembly
MailFathom.Application.dll

ReadAsync(MailboxScope, IReadOnlyList<EmailKnowledgePassage>, CancellationToken)

Reads one coverage entry per account the run's scope reached.

public Task<IReadOnlyList<AccountCoverage>> ReadAsync(MailboxScope scope, IReadOnlyList<EmailKnowledgePassage> passages, CancellationToken cancellationToken)

Parameters

scope MailboxScope

The scope the run retrieved within.

passages IReadOnlyList<EmailKnowledgePassage>

What the run found, which is where the dates come from.

cancellationToken CancellationToken

Propagates caller cancellation.

Returns

Task<IReadOnlyList<AccountCoverage>>

One entry per account, ordered by the account's identifier.

Remarks

Bounded by MaxAccountsCovered rather than by the scope, so a deployment serving more mailboxes than a plan may report produces a plan rather than a refusal. The surplus accounts go unreported and the ordering is what decides which, which is why it is the account identifier rather than anything about the mail: a run reports the same accounts every time it is asked. A deployment past that bound is serving something other than one person's correspondence, which is not what a Discover run is bounded for.

Exceptions

ArgumentNullException

Thrown when scope or passages is null.

OperationCanceledException

Thrown when the caller cancels.