Show / Hide Table of Contents

Class CfnMailManagerRuleSet.RuleProperty

A rule contains conditions, "unless conditions" and actions.

Inheritance
System.Object
CfnMailManagerRuleSet.RuleProperty
Implements
CfnMailManagerRuleSet.IRuleProperty
Namespace: Amazon.CDK.AWS.SES
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class RuleProperty : Object, CfnMailManagerRuleSet.IRuleProperty
Syntax (vb)
Public Class RuleProperty
    Inherits Object
    Implements CfnMailManagerRuleSet.IRuleProperty
Remarks

For each envelope recipient of an email, if all conditions match and none of the "unless conditions" match, then all of the actions are executed sequentially. If no conditions are provided, the rule always applies and the actions are implicitly executed. If only "unless conditions" are provided, the rule applies if the email does not match the evaluation of the "unless conditions".

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-mailmanagerruleset-rule.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.SES;

var drop;

var ruleProperty = new RuleProperty {
    Actions = new [] { new RuleActionProperty {
        AddHeader = new AddHeaderActionProperty {
            HeaderName = "headerName",
            HeaderValue = "headerValue"
        },
        Archive = new ArchiveActionProperty {
            TargetArchive = "targetArchive",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy"
        },
        DeliverToMailbox = new DeliverToMailboxActionProperty {
            MailboxArn = "mailboxArn",
            RoleArn = "roleArn",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy"
        },
        DeliverToQBusiness = new DeliverToQBusinessActionProperty {
            ApplicationId = "applicationId",
            IndexId = "indexId",
            RoleArn = "roleArn",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy"
        },
        Drop = drop,
        Relay = new RelayActionProperty {
            Relay = "relay",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy",
            MailFrom = "mailFrom"
        },
        ReplaceRecipient = new ReplaceRecipientActionProperty {
            ReplaceWith = new [] { "replaceWith" }
        },
        Send = new SendActionProperty {
            RoleArn = "roleArn",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy"
        },
        WriteToS3 = new S3ActionProperty {
            RoleArn = "roleArn",
            S3Bucket = "s3Bucket",

            // the properties below are optional
            ActionFailurePolicy = "actionFailurePolicy",
            S3Prefix = "s3Prefix",
            S3SseKmsKeyId = "s3SseKmsKeyId"
        }
    } },

    // the properties below are optional
    Conditions = new [] { new RuleConditionProperty {
        BooleanExpression = new RuleBooleanExpressionProperty {
            Evaluate = new RuleBooleanToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute"
            },
            Operator = "operator"
        },
        DmarcExpression = new RuleDmarcExpressionProperty {
            Operator = "operator",
            Values = new [] { "values" }
        },
        IpExpression = new RuleIpExpressionProperty {
            Evaluate = new RuleIpToEvaluateProperty {
                Attribute = "attribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        },
        NumberExpression = new RuleNumberExpressionProperty {
            Evaluate = new RuleNumberToEvaluateProperty {
                Attribute = "attribute"
            },
            Operator = "operator",
            Value = 123
        },
        StringExpression = new RuleStringExpressionProperty {
            Evaluate = new RuleStringToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute",
                MimeHeaderAttribute = "mimeHeaderAttribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        },
        VerdictExpression = new RuleVerdictExpressionProperty {
            Evaluate = new RuleVerdictToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        }
    } },
    Name = "name",
    Unless = new [] { new RuleConditionProperty {
        BooleanExpression = new RuleBooleanExpressionProperty {
            Evaluate = new RuleBooleanToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute"
            },
            Operator = "operator"
        },
        DmarcExpression = new RuleDmarcExpressionProperty {
            Operator = "operator",
            Values = new [] { "values" }
        },
        IpExpression = new RuleIpExpressionProperty {
            Evaluate = new RuleIpToEvaluateProperty {
                Attribute = "attribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        },
        NumberExpression = new RuleNumberExpressionProperty {
            Evaluate = new RuleNumberToEvaluateProperty {
                Attribute = "attribute"
            },
            Operator = "operator",
            Value = 123
        },
        StringExpression = new RuleStringExpressionProperty {
            Evaluate = new RuleStringToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute",
                MimeHeaderAttribute = "mimeHeaderAttribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        },
        VerdictExpression = new RuleVerdictExpressionProperty {
            Evaluate = new RuleVerdictToEvaluateProperty {
                Analysis = new AnalysisProperty {
                    Analyzer = "analyzer",
                    ResultField = "resultField"
                },
                Attribute = "attribute"
            },
            Operator = "operator",
            Values = new [] { "values" }
        }
    } }
};

Synopsis

Constructors

RuleProperty()

Properties

Actions

The list of actions to execute when the conditions match the incoming email, and none of the "unless conditions" match.

Conditions

The conditions of this rule.

Name

The user-friendly name of the rule.

Unless

The "unless conditions" of this rule.

Constructors

RuleProperty()

public RuleProperty()

Properties

Actions

The list of actions to execute when the conditions match the incoming email, and none of the "unless conditions" match.

public object Actions { get; set; }
Property Value

System.Object

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-mailmanagerruleset-rule.html#cfn-ses-mailmanagerruleset-rule-actions

Conditions

The conditions of this rule.

public object Conditions { get; set; }
Property Value

System.Object

Remarks

All conditions must match the email for the actions to be executed. An empty list of conditions means that all emails match, but are still subject to any "unless conditions"

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-mailmanagerruleset-rule.html#cfn-ses-mailmanagerruleset-rule-conditions

Name

The user-friendly name of the rule.

public string Name { get; set; }
Property Value

System.String

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-mailmanagerruleset-rule.html#cfn-ses-mailmanagerruleset-rule-name

Unless

The "unless conditions" of this rule.

public object Unless { get; set; }
Property Value

System.Object

Remarks

None of the conditions can match the email for the actions to be executed. If any of these conditions do match the email, then the actions are not executed.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ses-mailmanagerruleset-rule.html#cfn-ses-mailmanagerruleset-rule-unless

Implements

CfnMailManagerRuleSet.IRuleProperty
Back to top Generated by DocFX