Method DeleteAsync
- Namespace
- MailFathom.Application.Folders.Local
- Assembly
- MailFathom.Application.dll
DeleteAsync(MailAccountId, LocalMailFolderId, CancellationToken)
Deletes a folder: into the trash, or, where it is already there, out of existence with all of its mail.
public Task<LocalMailFolderEditOutcome> DeleteAsync(MailAccountId account, LocalMailFolderId folderId, CancellationToken cancellationToken)
Parameters
accountMailAccountIdThe caller's account.
folderIdLocalMailFolderIdThe folder.
cancellationTokenCancellationTokenPropagates caller cancellation.
Returns
- Task<LocalMailFolderEditOutcome>
The folder moved into the trash, the folder erased, or the refusal.
Remarks
An erasure commits the folders out of every listing at once and leaves their mail to bounded passes afterwards, so it commits in the time a few row updates take however much the folders hold.
Exceptions
- PrincipalNotAuthorizedException
Thrown when the caller does not hold
mailfathom.mail.folders.write.