Method Create
- Namespace
- MailFathom.Domain.Mutations
- Assembly
- MailFathom.Domain.dll
Create(StoredEmailId, EmailOccurrenceId, MailboxMutation, MailboxMutationRequester, RemoteFolderPath?, bool?)
Restores the request a durable record was written for.
public static MailboxMutationRequest Create(StoredEmailId storedEmailId, EmailOccurrenceId occurrence, MailboxMutation mutation, MailboxMutationRequester requester, RemoteFolderPath? destinationPath, bool? desiredSeenState)
Parameters
storedEmailIdStoredEmailIdThe local email the change is about.
occurrenceEmailOccurrenceIdThe occurrence the change was asked for.
mutationMailboxMutationThe change that was asked for.
requesterMailboxMutationRequesterThe authored act that asked.
destinationPathRemoteFolderPath?The stored destination folder, where the mutation takes one.
desiredSeenStatebool?The stored flag direction, where the mutation takes one.
Returns
- MailboxMutationRequest
The request those values name.
Remarks
This is the one route that accepts the parameters loose, because a stored row hands them back that way. It validates the shape the factories above guarantee, so a row edited by hand into a combination no mutation has is rejected on the way in rather than acted on.
Exceptions
- ArgumentNullException
Thrown when
occurrenceorrequesteris null.- ArgumentException
Thrown when
mutationis unspecified, or when the parameters present are not the ones it takes.