Class OwnTasks
- Namespace
- MailFathom.Application.Tasks
- Assembly
- MailFathom.Application.dll
Reads and writes the signed-in person's own task list.
public sealed class OwnTasks
- Inheritance
-
OwnTasks
- Inherited Members
Remarks
Whose tasks these are comes from the principal rather than from the request, exactly as it does for the user record, the client preferences, and the notification centre: there is no argument here for another user's identifier, so a reading of somebody else's list is something a caller cannot express rather than something a surface has to refuse. A task named by identifier is addressed with the user beside it, so one another person holds answers as one that does not exist.
The two origins are read apart rather than filtered, because they are two things to somebody looking at a screen: what they have committed to, and what mail suggested and nobody has agreed to yet. A cursor is issued against the origin it was read under and refused in the other, which is what stops a walk of the proposals continuing into the commitments halfway down a screen.
The reads are admitted under TasksRead and the writes under TasksWrite, neither of which is a grant over mail: a task is this deployment's own record of what a person owes, nothing here reaches a mail server, nothing moves in a mailbox, and a person whose mail accounts an administrator maintains keeps their own list under a grant that says nothing about those accounts.
Constructors
- OwnTasks(AccessAuthorization, IPersonalTaskStore, TimeProvider)
Initializes the use case.
Fields
- DefaultPageSize
The page size a request that names none is served.
- MaximumPageSize
The greatest page size one request is served, whatever it asked for.
Methods
- AcceptAsync(PersonalTaskId, CancellationToken)
Turns one of the signed-in person's proposals into a task they owe.
- EraseAsync(PersonalTaskId, CancellationToken)
Erases one of the signed-in person's tasks.
- FindAsync(PersonalTaskId, CancellationToken)
Reads one of the signed-in person's tasks.
- ReadPageAsync(PersonalTaskOrigin, int?, string?, CancellationToken)
Reads one page of the signed-in person's tasks of one origin, soonest due first.
- RecordAsync(string, DateOnly?, TaskAnnouncement, StoredEmailId?, CancellationToken)
Records a task the signed-in person has just committed to.
- ReviseAsync(PersonalTaskId, string, DateOnly?, TaskAnnouncement, CancellationToken)
Writes what the signed-in person edited about one of their tasks.
- SetCompletionAsync(PersonalTaskId, bool, CancellationToken)
Puts one of the signed-in person's tasks into a stated completion state.