Table of Contents

Method Compile

Namespace
MailFathom.Infrastructure.Rules
Assembly
MailFathom.Infrastructure.dll

Compile(string, string?, MailRuleConditionBounds)

Reads one rule's condition under the bounds the rule set was declared with.

public MailRuleConditionCompilation Compile(string ruleName, string? conditionText, MailRuleConditionBounds bounds)

Parameters

ruleName string

The rule the condition belongs to, which every message names.

conditionText string

The condition as the operator wrote it.

bounds MailRuleConditionBounds

The length, depth, and timeout the condition is read and run under.

Returns

MailRuleConditionCompilation

The compiled condition, or every reason it cannot be used.

Exceptions

ArgumentNullException

Thrown when bounds is null.

ArgumentException

Thrown when ruleName is empty or whitespace.