Defines the signature (the parameters and the return value) of the application-defined method which can be used as a filter which triggers when a rule condition gets satisfied and controls whether to perform the action defined by this rule.
Should return true to tell MailBee to apply the action associated with the rule for which this delegate was called, or false to ignore this rule and continue. Has no effect on rules of ProcessingCondition type.
This delegate defines a pattern for the callback method MailBee executes when it encounters any matches of HTML processing rule conditions with particular HTML elements. You can implement any custom processing in this method, modify the given HTML element, or decide whether the rule should be applied by returning true of false.
Process method, while being running, executes a delegate method every time when any of the rules gets satisfied. This happens when the rule condition matches a particular HTML tag (for instance, you're using a rule which applies to all <A> tags with HREF attributes and Process method encountered such a tag).
Process method then executes the delegate passing a reference to the matching Element. The delegate method should examine the supplied element and return either true to let MailBee apply the rule action to this element or false to ignore it. The return value of the delegate, however, does not affect whether Process method will continue processing of subsequent elements of the document. To make Process method completely stop processing of the current document, call Stop method for the same object you earlier called Process for.
Rules of all types (defined in TagRuleTypes enumeration) cause the delegate be executed. Moreover, ProcessingCondition rule does not perform any actions except calling the delegate itself.
The example is available in AddTagProcessingCondition topic.
Namespace: MailBee.Html
Assembly: MailBee.NET (in MailBee.NET.dll)
MailBee.Html Namespace | Process | RuleSet | Rule | TagRuleTypes