Table of Contents

Constructor MailRuleActionPermissions

Namespace
MailFathom.Application.Rules.Actions
Assembly
MailFathom.Application.dll

MailRuleActionPermissions(bool, bool, bool, bool, bool, bool)

States which of the permitted mutations a rule may ask for on one account.

public MailRuleActionPermissions(bool PermitsRelocate, bool PermitsCopy, bool PermitsDelete, bool PermitsSetSeen, bool PermitsSetFlagged, bool PermitsWriteKeywords)

Parameters

PermitsRelocate bool

Whether a rule may move mail into another folder.

PermitsCopy bool

Whether a rule may put a second occurrence into another folder.

PermitsDelete bool

Whether a rule may remove mail from the folder it is in.

PermitsSetSeen bool

Whether a rule may set or clear the remote \Seen flag.

PermitsSetFlagged bool

Whether a rule may set or clear the remote \Flagged flag.

PermitsWriteKeywords bool

Whether a rule may add, remove, or replace the keywords of this account's mail.

Remarks

What automation may do to a mailbox is the owner's decision rather than a rule's, so it is declared per account and per action instead of as one switch: an installation can run every rule it has with deletion refused, which is the case this exists for. A rule declaring an action its account does not permit is refused when the configuration is read rather than skipped later, because a rule that silently does nothing is indistinguishable from one that never matched.

Deletion is the one action that is opt-in. The others are reversible from an ordinary mail client — a message filed can be moved back, a copy removed, a flag cleared, a label taken off — and a deletion is the one that is not, so an account saying nothing about it means no.

The three keyword mutations share one switch, which is the one place the per-mutation shape is deliberately not followed. An owner deciding whether automation may label their mail is answering one question about one kind of value, and splitting it in three would offer a combination — may add, may not remove — whose only effect is mail accumulating labels nothing is allowed to take off again.