Table of Contents

Method Create

Namespace
MailFathom.Application.Spam
Assembly
MailFathom.Application.dll

Create(bool, bool, IEnumerable<MailFolderAlias>, double?)

Builds the settings an operator's answers describe.

public static SpamClassificationSettings Create(bool isEnabled, bool usesScanner, IEnumerable<MailFolderAlias> scannedFolderAliases, double? scannerThreshold = null)

Parameters

isEnabled bool

Whether classification runs.

usesScanner bool

Whether a configured scanner is consulted.

scannedFolderAliases IEnumerable<MailFolderAlias>

The folder aliases to classify, already resolved to the inbox where the operator named none.

scannerThreshold double?

The threshold to judge a scanner's score by, or null to keep the scanner's own.

Returns

SpamClassificationSettings

The settings, with the alias list deduplicated and ordered.

Remarks

How long a message may wait on a verdict is not among these, because it is not one user's to decide: it bounds how long the index may be held back by a scanner that has stopped answering, which is a cost the process bears. MaximumClassificationWait is where the deployment states it.

Exceptions

ArgumentNullException

Thrown when scannedFolderAliases is null.

ArgumentOutOfRangeException

Thrown when scannerThreshold is not a finite number.