Class CfnRuleProps.Builder
java.lang.Object
software.amazon.awscdk.services.waf.CfnRuleProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnRuleProps>
- Enclosing interface:
- CfnRuleProps
@Stability(Stable)
public static final class CfnRuleProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnRuleProps>
A builder for
CfnRuleProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.metricName(String metricName) Sets the value ofCfnRuleProps.getMetricName()Sets the value ofCfnRuleProps.getName()predicates(List<? extends Object> predicates) Sets the value ofCfnRuleProps.getPredicates()predicates(IResolvable predicates) Sets the value ofCfnRuleProps.getPredicates()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
metricName
Sets the value ofCfnRuleProps.getMetricName()- Parameters:
metricName- The name of the metrics for thisRule. This parameter is required. The name can contain only alphanumeric characters (A-Z, a-z, 0-9), with maximum length 128 and minimum length one. It can't contain whitespace or metric names reserved for AWS WAF , including "All" and "Default_Action." You can't changeMetricNameafter you create theRule.- Returns:
this
-
name
Sets the value ofCfnRuleProps.getName()- Parameters:
name- The friendly name or description for theRule. This parameter is required. You can't change the name of aRuleafter you create it.- Returns:
this
-
predicates
Sets the value ofCfnRuleProps.getPredicates()- Parameters:
predicates- ThePredicatesobject contains onePredicateelement for eachByteMatchSet,IPSet, orSqlInjectionMatchSetobject that you want to include in aRule.- Returns:
this
-
predicates
Sets the value ofCfnRuleProps.getPredicates()- Parameters:
predicates- ThePredicatesobject contains onePredicateelement for eachByteMatchSet,IPSet, orSqlInjectionMatchSetobject that you want to include in aRule.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnRuleProps>- Returns:
- a new instance of
CfnRuleProps - Throws:
NullPointerException- if any required attribute was not provided
-