aws-cdk-lib
Version:
Version 2 of the AWS Cloud Development Kit library
1 lines • 75.2 kB
JavaScript
"use strict";var _a,_b,_c,_d,_e,_f,_g,_h,_j,_k,_l;Object.defineProperty(exports,"__esModule",{value:!0}),exports.CfnXssMatchSet=exports.CfnWebACLAssociation=exports.CfnWebACL=exports.CfnSqlInjectionMatchSet=exports.CfnSizeConstraintSet=exports.CfnRule=exports.CfnRegexPatternSet=exports.CfnRateBasedRule=exports.CfnIPSet=exports.CfnGeoMatchSet=exports.CfnByteMatchSet=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var cdk=()=>{var tmp=require("../../core");return cdk=()=>tmp,tmp},cfn_parse=()=>{var tmp=require("../../core/lib/helpers-internal");return cfn_parse=()=>tmp,tmp},cdk_errors=()=>{var tmp=require("../../core/lib/errors");return cdk_errors=()=>tmp,tmp};class CfnByteMatchSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnByteMatchSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnByteMatchSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnByteMatchSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnByteMatchSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnByteMatchSet),error}cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.byteMatchTuples=props.byteMatchTuples,this.name=props.name}get cfnProperties(){return{byteMatchTuples:this.byteMatchTuples,name:this.name}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnByteMatchSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnByteMatchSetPropsToCloudFormation(props)}}exports.CfnByteMatchSet=CfnByteMatchSet,_a=JSII_RTTI_SYMBOL_1,CfnByteMatchSet[_a]={fqn:"aws-cdk-lib.aws_wafregional.CfnByteMatchSet",version:"2.202.0"},CfnByteMatchSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::ByteMatchSet";function CfnByteMatchSetFieldToMatchPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("data",cdk().validateString)(properties.data)),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.wrap('supplied properties not correct for "FieldToMatchProperty"')}function convertCfnByteMatchSetFieldToMatchPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnByteMatchSetFieldToMatchPropertyValidator(properties).assertSuccess(),{Data:cdk().stringToCloudFormation(properties.data),Type:cdk().stringToCloudFormation(properties.type)}):properties}function CfnByteMatchSetFieldToMatchPropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("data","Data",properties.Data!=null?cfn_parse().FromCloudFormation.getString(properties.Data):void 0),ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnByteMatchSetByteMatchTuplePropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("fieldToMatch",cdk().requiredValidator)(properties.fieldToMatch)),errors.collect(cdk().propertyValidator("fieldToMatch",CfnByteMatchSetFieldToMatchPropertyValidator)(properties.fieldToMatch)),errors.collect(cdk().propertyValidator("positionalConstraint",cdk().requiredValidator)(properties.positionalConstraint)),errors.collect(cdk().propertyValidator("positionalConstraint",cdk().validateString)(properties.positionalConstraint)),errors.collect(cdk().propertyValidator("targetString",cdk().validateString)(properties.targetString)),errors.collect(cdk().propertyValidator("targetStringBase64",cdk().validateString)(properties.targetStringBase64)),errors.collect(cdk().propertyValidator("textTransformation",cdk().requiredValidator)(properties.textTransformation)),errors.collect(cdk().propertyValidator("textTransformation",cdk().validateString)(properties.textTransformation)),errors.wrap('supplied properties not correct for "ByteMatchTupleProperty"')}function convertCfnByteMatchSetByteMatchTuplePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnByteMatchSetByteMatchTuplePropertyValidator(properties).assertSuccess(),{FieldToMatch:convertCfnByteMatchSetFieldToMatchPropertyToCloudFormation(properties.fieldToMatch),PositionalConstraint:cdk().stringToCloudFormation(properties.positionalConstraint),TargetString:cdk().stringToCloudFormation(properties.targetString),TargetStringBase64:cdk().stringToCloudFormation(properties.targetStringBase64),TextTransformation:cdk().stringToCloudFormation(properties.textTransformation)}):properties}function CfnByteMatchSetByteMatchTuplePropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("fieldToMatch","FieldToMatch",properties.FieldToMatch!=null?CfnByteMatchSetFieldToMatchPropertyFromCloudFormation(properties.FieldToMatch):void 0),ret.addPropertyResult("positionalConstraint","PositionalConstraint",properties.PositionalConstraint!=null?cfn_parse().FromCloudFormation.getString(properties.PositionalConstraint):void 0),ret.addPropertyResult("targetString","TargetString",properties.TargetString!=null?cfn_parse().FromCloudFormation.getString(properties.TargetString):void 0),ret.addPropertyResult("targetStringBase64","TargetStringBase64",properties.TargetStringBase64!=null?cfn_parse().FromCloudFormation.getString(properties.TargetStringBase64):void 0),ret.addPropertyResult("textTransformation","TextTransformation",properties.TextTransformation!=null?cfn_parse().FromCloudFormation.getString(properties.TextTransformation):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnByteMatchSetPropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("byteMatchTuples",cdk().listValidator(CfnByteMatchSetByteMatchTuplePropertyValidator))(properties.byteMatchTuples)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.wrap('supplied properties not correct for "CfnByteMatchSetProps"')}function convertCfnByteMatchSetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnByteMatchSetPropsValidator(properties).assertSuccess(),{ByteMatchTuples:cdk().listMapper(convertCfnByteMatchSetByteMatchTuplePropertyToCloudFormation)(properties.byteMatchTuples),Name:cdk().stringToCloudFormation(properties.name)}):properties}function CfnByteMatchSetPropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("byteMatchTuples","ByteMatchTuples",properties.ByteMatchTuples!=null?cfn_parse().FromCloudFormation.getArray(CfnByteMatchSetByteMatchTuplePropertyFromCloudFormation)(properties.ByteMatchTuples):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnGeoMatchSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnGeoMatchSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnGeoMatchSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnGeoMatchSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnGeoMatchSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnGeoMatchSet),error}cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.geoMatchConstraints=props.geoMatchConstraints,this.name=props.name}get cfnProperties(){return{geoMatchConstraints:this.geoMatchConstraints,name:this.name}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnGeoMatchSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnGeoMatchSetPropsToCloudFormation(props)}}exports.CfnGeoMatchSet=CfnGeoMatchSet,_b=JSII_RTTI_SYMBOL_1,CfnGeoMatchSet[_b]={fqn:"aws-cdk-lib.aws_wafregional.CfnGeoMatchSet",version:"2.202.0"},CfnGeoMatchSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::GeoMatchSet";function CfnGeoMatchSetGeoMatchConstraintPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.collect(cdk().propertyValidator("value",cdk().requiredValidator)(properties.value)),errors.collect(cdk().propertyValidator("value",cdk().validateString)(properties.value)),errors.wrap('supplied properties not correct for "GeoMatchConstraintProperty"')}function convertCfnGeoMatchSetGeoMatchConstraintPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnGeoMatchSetGeoMatchConstraintPropertyValidator(properties).assertSuccess(),{Type:cdk().stringToCloudFormation(properties.type),Value:cdk().stringToCloudFormation(properties.value)}):properties}function CfnGeoMatchSetGeoMatchConstraintPropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addPropertyResult("value","Value",properties.Value!=null?cfn_parse().FromCloudFormation.getString(properties.Value):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnGeoMatchSetPropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("geoMatchConstraints",cdk().listValidator(CfnGeoMatchSetGeoMatchConstraintPropertyValidator))(properties.geoMatchConstraints)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.wrap('supplied properties not correct for "CfnGeoMatchSetProps"')}function convertCfnGeoMatchSetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnGeoMatchSetPropsValidator(properties).assertSuccess(),{GeoMatchConstraints:cdk().listMapper(convertCfnGeoMatchSetGeoMatchConstraintPropertyToCloudFormation)(properties.geoMatchConstraints),Name:cdk().stringToCloudFormation(properties.name)}):properties}function CfnGeoMatchSetPropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("geoMatchConstraints","GeoMatchConstraints",properties.GeoMatchConstraints!=null?cfn_parse().FromCloudFormation.getArray(CfnGeoMatchSetGeoMatchConstraintPropertyFromCloudFormation)(properties.GeoMatchConstraints):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnIPSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnIPSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnIPSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnIPSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnIPSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnIPSet),error}cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.ipSetDescriptors=props.ipSetDescriptors,this.name=props.name}get cfnProperties(){return{ipSetDescriptors:this.ipSetDescriptors,name:this.name}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnIPSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnIPSetPropsToCloudFormation(props)}}exports.CfnIPSet=CfnIPSet,_c=JSII_RTTI_SYMBOL_1,CfnIPSet[_c]={fqn:"aws-cdk-lib.aws_wafregional.CfnIPSet",version:"2.202.0"},CfnIPSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::IPSet";function CfnIPSetIPSetDescriptorPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.collect(cdk().propertyValidator("value",cdk().requiredValidator)(properties.value)),errors.collect(cdk().propertyValidator("value",cdk().validateString)(properties.value)),errors.wrap('supplied properties not correct for "IPSetDescriptorProperty"')}function convertCfnIPSetIPSetDescriptorPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnIPSetIPSetDescriptorPropertyValidator(properties).assertSuccess(),{Type:cdk().stringToCloudFormation(properties.type),Value:cdk().stringToCloudFormation(properties.value)}):properties}function CfnIPSetIPSetDescriptorPropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addPropertyResult("value","Value",properties.Value!=null?cfn_parse().FromCloudFormation.getString(properties.Value):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnIPSetPropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("ipSetDescriptors",cdk().listValidator(CfnIPSetIPSetDescriptorPropertyValidator))(properties.ipSetDescriptors)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.wrap('supplied properties not correct for "CfnIPSetProps"')}function convertCfnIPSetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnIPSetPropsValidator(properties).assertSuccess(),{IPSetDescriptors:cdk().listMapper(convertCfnIPSetIPSetDescriptorPropertyToCloudFormation)(properties.ipSetDescriptors),Name:cdk().stringToCloudFormation(properties.name)}):properties}function CfnIPSetPropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("ipSetDescriptors","IPSetDescriptors",properties.IPSetDescriptors!=null?cfn_parse().FromCloudFormation.getArray(CfnIPSetIPSetDescriptorPropertyFromCloudFormation)(properties.IPSetDescriptors):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnRateBasedRule extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnRateBasedRulePropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnRateBasedRule(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnRateBasedRule.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnRateBasedRuleProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnRateBasedRule),error}cdk().requireProperty(props,"metricName",this),cdk().requireProperty(props,"name",this),cdk().requireProperty(props,"rateKey",this),cdk().requireProperty(props,"rateLimit",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.matchPredicates=props.matchPredicates,this.metricName=props.metricName,this.name=props.name,this.rateKey=props.rateKey,this.rateLimit=props.rateLimit}get cfnProperties(){return{matchPredicates:this.matchPredicates,metricName:this.metricName,name:this.name,rateKey:this.rateKey,rateLimit:this.rateLimit}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnRateBasedRule.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnRateBasedRulePropsToCloudFormation(props)}}exports.CfnRateBasedRule=CfnRateBasedRule,_d=JSII_RTTI_SYMBOL_1,CfnRateBasedRule[_d]={fqn:"aws-cdk-lib.aws_wafregional.CfnRateBasedRule",version:"2.202.0"},CfnRateBasedRule.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::RateBasedRule";function CfnRateBasedRulePredicatePropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("dataId",cdk().requiredValidator)(properties.dataId)),errors.collect(cdk().propertyValidator("dataId",cdk().validateString)(properties.dataId)),errors.collect(cdk().propertyValidator("negated",cdk().requiredValidator)(properties.negated)),errors.collect(cdk().propertyValidator("negated",cdk().validateBoolean)(properties.negated)),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.wrap('supplied properties not correct for "PredicateProperty"')}function convertCfnRateBasedRulePredicatePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnRateBasedRulePredicatePropertyValidator(properties).assertSuccess(),{DataId:cdk().stringToCloudFormation(properties.dataId),Negated:cdk().booleanToCloudFormation(properties.negated),Type:cdk().stringToCloudFormation(properties.type)}):properties}function CfnRateBasedRulePredicatePropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("dataId","DataId",properties.DataId!=null?cfn_parse().FromCloudFormation.getString(properties.DataId):void 0),ret.addPropertyResult("negated","Negated",properties.Negated!=null?cfn_parse().FromCloudFormation.getBoolean(properties.Negated):void 0),ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnRateBasedRulePropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("matchPredicates",cdk().listValidator(CfnRateBasedRulePredicatePropertyValidator))(properties.matchPredicates)),errors.collect(cdk().propertyValidator("metricName",cdk().requiredValidator)(properties.metricName)),errors.collect(cdk().propertyValidator("metricName",cdk().validateString)(properties.metricName)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("rateKey",cdk().requiredValidator)(properties.rateKey)),errors.collect(cdk().propertyValidator("rateKey",cdk().validateString)(properties.rateKey)),errors.collect(cdk().propertyValidator("rateLimit",cdk().requiredValidator)(properties.rateLimit)),errors.collect(cdk().propertyValidator("rateLimit",cdk().validateNumber)(properties.rateLimit)),errors.wrap('supplied properties not correct for "CfnRateBasedRuleProps"')}function convertCfnRateBasedRulePropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnRateBasedRulePropsValidator(properties).assertSuccess(),{MatchPredicates:cdk().listMapper(convertCfnRateBasedRulePredicatePropertyToCloudFormation)(properties.matchPredicates),MetricName:cdk().stringToCloudFormation(properties.metricName),Name:cdk().stringToCloudFormation(properties.name),RateKey:cdk().stringToCloudFormation(properties.rateKey),RateLimit:cdk().numberToCloudFormation(properties.rateLimit)}):properties}function CfnRateBasedRulePropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("matchPredicates","MatchPredicates",properties.MatchPredicates!=null?cfn_parse().FromCloudFormation.getArray(CfnRateBasedRulePredicatePropertyFromCloudFormation)(properties.MatchPredicates):void 0),ret.addPropertyResult("metricName","MetricName",properties.MetricName!=null?cfn_parse().FromCloudFormation.getString(properties.MetricName):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("rateKey","RateKey",properties.RateKey!=null?cfn_parse().FromCloudFormation.getString(properties.RateKey):void 0),ret.addPropertyResult("rateLimit","RateLimit",properties.RateLimit!=null?cfn_parse().FromCloudFormation.getNumber(properties.RateLimit):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnRegexPatternSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnRegexPatternSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnRegexPatternSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnRegexPatternSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnRegexPatternSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnRegexPatternSet),error}cdk().requireProperty(props,"name",this),cdk().requireProperty(props,"regexPatternStrings",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.name=props.name,this.regexPatternStrings=props.regexPatternStrings}get cfnProperties(){return{name:this.name,regexPatternStrings:this.regexPatternStrings}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnRegexPatternSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnRegexPatternSetPropsToCloudFormation(props)}}exports.CfnRegexPatternSet=CfnRegexPatternSet,_e=JSII_RTTI_SYMBOL_1,CfnRegexPatternSet[_e]={fqn:"aws-cdk-lib.aws_wafregional.CfnRegexPatternSet",version:"2.202.0"},CfnRegexPatternSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::RegexPatternSet";function CfnRegexPatternSetPropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("regexPatternStrings",cdk().requiredValidator)(properties.regexPatternStrings)),errors.collect(cdk().propertyValidator("regexPatternStrings",cdk().listValidator(cdk().validateString))(properties.regexPatternStrings)),errors.wrap('supplied properties not correct for "CfnRegexPatternSetProps"')}function convertCfnRegexPatternSetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnRegexPatternSetPropsValidator(properties).assertSuccess(),{Name:cdk().stringToCloudFormation(properties.name),RegexPatternStrings:cdk().listMapper(cdk().stringToCloudFormation)(properties.regexPatternStrings)}):properties}function CfnRegexPatternSetPropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("regexPatternStrings","RegexPatternStrings",properties.RegexPatternStrings!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.RegexPatternStrings):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnRule extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnRulePropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnRule(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnRule.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnRuleProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnRule),error}cdk().requireProperty(props,"metricName",this),cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.metricName=props.metricName,this.name=props.name,this.predicates=props.predicates}get cfnProperties(){return{metricName:this.metricName,name:this.name,predicates:this.predicates}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnRule.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnRulePropsToCloudFormation(props)}}exports.CfnRule=CfnRule,_f=JSII_RTTI_SYMBOL_1,CfnRule[_f]={fqn:"aws-cdk-lib.aws_wafregional.CfnRule",version:"2.202.0"},CfnRule.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::Rule";function CfnRulePredicatePropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("dataId",cdk().requiredValidator)(properties.dataId)),errors.collect(cdk().propertyValidator("dataId",cdk().validateString)(properties.dataId)),errors.collect(cdk().propertyValidator("negated",cdk().requiredValidator)(properties.negated)),errors.collect(cdk().propertyValidator("negated",cdk().validateBoolean)(properties.negated)),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.wrap('supplied properties not correct for "PredicateProperty"')}function convertCfnRulePredicatePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnRulePredicatePropertyValidator(properties).assertSuccess(),{DataId:cdk().stringToCloudFormation(properties.dataId),Negated:cdk().booleanToCloudFormation(properties.negated),Type:cdk().stringToCloudFormation(properties.type)}):properties}function CfnRulePredicatePropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("dataId","DataId",properties.DataId!=null?cfn_parse().FromCloudFormation.getString(properties.DataId):void 0),ret.addPropertyResult("negated","Negated",properties.Negated!=null?cfn_parse().FromCloudFormation.getBoolean(properties.Negated):void 0),ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnRulePropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("metricName",cdk().requiredValidator)(properties.metricName)),errors.collect(cdk().propertyValidator("metricName",cdk().validateString)(properties.metricName)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("predicates",cdk().listValidator(CfnRulePredicatePropertyValidator))(properties.predicates)),errors.wrap('supplied properties not correct for "CfnRuleProps"')}function convertCfnRulePropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnRulePropsValidator(properties).assertSuccess(),{MetricName:cdk().stringToCloudFormation(properties.metricName),Name:cdk().stringToCloudFormation(properties.name),Predicates:cdk().listMapper(convertCfnRulePredicatePropertyToCloudFormation)(properties.predicates)}):properties}function CfnRulePropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("metricName","MetricName",properties.MetricName!=null?cfn_parse().FromCloudFormation.getString(properties.MetricName):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("predicates","Predicates",properties.Predicates!=null?cfn_parse().FromCloudFormation.getArray(CfnRulePredicatePropertyFromCloudFormation)(properties.Predicates):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnSizeConstraintSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnSizeConstraintSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnSizeConstraintSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnSizeConstraintSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnSizeConstraintSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnSizeConstraintSet),error}cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.name=props.name,this.sizeConstraints=props.sizeConstraints}get cfnProperties(){return{name:this.name,sizeConstraints:this.sizeConstraints}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnSizeConstraintSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnSizeConstraintSetPropsToCloudFormation(props)}}exports.CfnSizeConstraintSet=CfnSizeConstraintSet,_g=JSII_RTTI_SYMBOL_1,CfnSizeConstraintSet[_g]={fqn:"aws-cdk-lib.aws_wafregional.CfnSizeConstraintSet",version:"2.202.0"},CfnSizeConstraintSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::SizeConstraintSet";function CfnSizeConstraintSetFieldToMatchPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("data",cdk().validateString)(properties.data)),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type",cdk().validateString)(properties.type)),errors.wrap('supplied properties not correct for "FieldToMatchProperty"')}function convertCfnSizeConstraintSetFieldToMatchPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnSizeConstraintSetFieldToMatchPropertyValidator(properties).assertSuccess(),{Data:cdk().stringToCloudFormation(properties.data),Type:cdk().stringToCloudFormation(properties.type)}):properties}function CfnSizeConstraintSetFieldToMatchPropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("data","Data",properties.Data!=null?cfn_parse().FromCloudFormation.getString(properties.Data):void 0),ret.addPropertyResult("type","Type",properties.Type!=null?cfn_parse().FromCloudFormation.getString(properties.Type):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnSizeConstraintSetSizeConstraintPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("comparisonOperator",cdk().requiredValidator)(properties.comparisonOperator)),errors.collect(cdk().propertyValidator("comparisonOperator",cdk().validateString)(properties.comparisonOperator)),errors.collect(cdk().propertyValidator("fieldToMatch",cdk().requiredValidator)(properties.fieldToMatch)),errors.collect(cdk().propertyValidator("fieldToMatch",CfnSizeConstraintSetFieldToMatchPropertyValidator)(properties.fieldToMatch)),errors.collect(cdk().propertyValidator("size",cdk().requiredValidator)(properties.size)),errors.collect(cdk().propertyValidator("size",cdk().validateNumber)(properties.size)),errors.collect(cdk().propertyValidator("textTransformation",cdk().requiredValidator)(properties.textTransformation)),errors.collect(cdk().propertyValidator("textTransformation",cdk().validateString)(properties.textTransformation)),errors.wrap('supplied properties not correct for "SizeConstraintProperty"')}function convertCfnSizeConstraintSetSizeConstraintPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnSizeConstraintSetSizeConstraintPropertyValidator(properties).assertSuccess(),{ComparisonOperator:cdk().stringToCloudFormation(properties.comparisonOperator),FieldToMatch:convertCfnSizeConstraintSetFieldToMatchPropertyToCloudFormation(properties.fieldToMatch),Size:cdk().numberToCloudFormation(properties.size),TextTransformation:cdk().stringToCloudFormation(properties.textTransformation)}):properties}function CfnSizeConstraintSetSizeConstraintPropertyFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("comparisonOperator","ComparisonOperator",properties.ComparisonOperator!=null?cfn_parse().FromCloudFormation.getString(properties.ComparisonOperator):void 0),ret.addPropertyResult("fieldToMatch","FieldToMatch",properties.FieldToMatch!=null?CfnSizeConstraintSetFieldToMatchPropertyFromCloudFormation(properties.FieldToMatch):void 0),ret.addPropertyResult("size","Size",properties.Size!=null?cfn_parse().FromCloudFormation.getNumber(properties.Size):void 0),ret.addPropertyResult("textTransformation","TextTransformation",properties.TextTransformation!=null?cfn_parse().FromCloudFormation.getString(properties.TextTransformation):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnSizeConstraintSetPropsValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("sizeConstraints",cdk().listValidator(CfnSizeConstraintSetSizeConstraintPropertyValidator))(properties.sizeConstraints)),errors.wrap('supplied properties not correct for "CfnSizeConstraintSetProps"')}function convertCfnSizeConstraintSetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnSizeConstraintSetPropsValidator(properties).assertSuccess(),{Name:cdk().stringToCloudFormation(properties.name),SizeConstraints:cdk().listMapper(convertCfnSizeConstraintSetSizeConstraintPropertyToCloudFormation)(properties.sizeConstraints)}):properties}function CfnSizeConstraintSetPropsFromCloudFormation(properties){if(cdk().isResolvableObject(properties))return new(cfn_parse()).FromCloudFormationResult(properties);if(properties=properties??{},!(properties&&typeof properties=="object"&&!Array.isArray(properties)))return new(cfn_parse()).FromCloudFormationResult(properties);const ret=new(cfn_parse()).FromCloudFormationPropertyObject;return ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("sizeConstraints","SizeConstraints",properties.SizeConstraints!=null?cfn_parse().FromCloudFormation.getArray(CfnSizeConstraintSetSizeConstraintPropertyFromCloudFormation)(properties.SizeConstraints):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnSqlInjectionMatchSet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnSqlInjectionMatchSetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnSqlInjectionMatchSet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnSqlInjectionMatchSet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_wafregional_CfnSqlInjectionMatchSetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnSqlInjectionMatchSet),error}cdk().requireProperty(props,"name",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.name=props.name,this.sqlInjectionMatchTuples=props.sqlInjectionMatchTuples}get cfnProperties(){return{name:this.name,sqlInjectionMatchTuples:this.sqlInjectionMatchTuples}}inspect(inspector){try{jsiiDeprecationWarnings().aws_cdk_lib_TreeInspector(inspector)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.inspect),error}inspector.addAttribute("aws:cdk:cloudformation:type",CfnSqlInjectionMatchSet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnSqlInjectionMatchSetPropsToCloudFormation(props)}}exports.CfnSqlInjectionMatchSet=CfnSqlInjectionMatchSet,_h=JSII_RTTI_SYMBOL_1,CfnSqlInjectionMatchSet[_h]={fqn:"aws-cdk-lib.aws_wafregional.CfnSqlInjectionMatchSet",version:"2.202.0"},CfnSqlInjectionMatchSet.CFN_RESOURCE_TYPE_NAME="AWS::WAFRegional::SqlInjectionMatchSet";function CfnSqlInjectionMatchSetFieldToMatchPropertyValidator(properties){if(!cdk().canInspect(properties))return cdk().VALIDATION_SUCCESS;const errors=new(cdk()).ValidationResults;return properties&&typeof properties=="object"&&!Array.isArray(properties)||errors.collect(new(cdk()).ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk().propertyValidator("data",cdk().validateString)(properties.data)),errors.collect(cdk().propertyValidator("type",cdk().requiredValidator)(properties.type)),errors.collect(cdk().propertyValidator("type"