Table of Contents

Method ReadUsersAsync

Namespace
MailFathom.Application.Access
Assembly
MailFathom.Application.dll

ReadUsersAsync(int, CancellationToken)

Reads the users this deployment holds, at most as many as asked for.

Task<IReadOnlyList<UserRecord>> ReadUsersAsync(int limit, CancellationToken cancellationToken)

Parameters

limit int

The greatest number of users to read.

cancellationToken CancellationToken

Cancels the read.

Returns

Task<IReadOnlyList<UserRecord>>

The users, in a stable order, and no more than limit of them.

Remarks

The bound is the caller's, and it exists so that a caller asking whether anybody is recorded at all reads as few rows as that question needs rather than every user. The order is stable so that a caller asking for one user twice is answered about the same user both times.

Exceptions

ArgumentOutOfRangeException

Thrown when limit is not positive.