Method Delete
- Namespace
- MailFathom.Domain.Mutations
- Assembly
- MailFathom.Domain.dll
Delete(StoredEmailId, EmailOccurrenceId, MailboxMutationRequester, AuthoredDeleteEmailDisposition)
Asks for one email to be removed from the folder it is in.
public static MailboxMutationRequest Delete(StoredEmailId storedEmailId, EmailOccurrenceId occurrence, MailboxMutationRequester requester, AuthoredDeleteEmailDisposition localDisposition)
Parameters
storedEmailIdStoredEmailIdThe local email being removed.
occurrenceEmailOccurrenceIdWhere the email is now.
requesterMailboxMutationRequesterThe authored act asking.
localDispositionAuthoredDeleteEmailDispositionWhat becomes of the local copy once the server no longer holds the message.
Returns
- MailboxMutationRequest
The request to write down.
Remarks
The disposition is a parameter rather than something read where the delete completes, because completion happens in a later synchronization run that would read whatever the configuration says by then. Taking it here is what makes the answer the one that was true when the owner asked.
Exceptions
- ArgumentNullException
Thrown when
occurrenceorrequesteris null.- ArgumentOutOfRangeException
Thrown when
localDispositionnames no declared disposition.