UNPKG

aws-cdk-lib

Version:

Version 2 of the AWS Cloud Development Kit library

1 lines 222 kB
"use strict";var _a,_b,_c,_d;Object.defineProperty(exports,"__esModule",{value:!0}),exports.CfnResourcePolicy=exports.CfnBotVersion=exports.CfnBotAlias=exports.CfnBot=void 0;const jsiiDeprecationWarnings=require("../../.warnings.jsii.js"),JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti"),cdk=require("../../core"),cfn_parse=require("../../core/lib/helpers-internal");function CfnBotPropsValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("autoBuildBotLocales",cdk.validateBoolean)(properties.autoBuildBotLocales)),errors.collect(cdk.propertyValidator("botFileS3Location",CfnBot_S3LocationPropertyValidator)(properties.botFileS3Location)),errors.collect(cdk.propertyValidator("botLocales",cdk.listValidator(CfnBot_BotLocalePropertyValidator))(properties.botLocales)),errors.collect(cdk.propertyValidator("botTags",cdk.listValidator(cdk.validateCfnTag))(properties.botTags)),errors.collect(cdk.propertyValidator("dataPrivacy",cdk.requiredValidator)(properties.dataPrivacy)),errors.collect(cdk.propertyValidator("dataPrivacy",cdk.validateObject)(properties.dataPrivacy)),errors.collect(cdk.propertyValidator("description",cdk.validateString)(properties.description)),errors.collect(cdk.propertyValidator("idleSessionTtlInSeconds",cdk.requiredValidator)(properties.idleSessionTtlInSeconds)),errors.collect(cdk.propertyValidator("idleSessionTtlInSeconds",cdk.validateNumber)(properties.idleSessionTtlInSeconds)),errors.collect(cdk.propertyValidator("name",cdk.requiredValidator)(properties.name)),errors.collect(cdk.propertyValidator("name",cdk.validateString)(properties.name)),errors.collect(cdk.propertyValidator("roleArn",cdk.requiredValidator)(properties.roleArn)),errors.collect(cdk.propertyValidator("roleArn",cdk.validateString)(properties.roleArn)),errors.collect(cdk.propertyValidator("testBotAliasSettings",CfnBot_TestBotAliasSettingsPropertyValidator)(properties.testBotAliasSettings)),errors.collect(cdk.propertyValidator("testBotAliasTags",cdk.listValidator(cdk.validateCfnTag))(properties.testBotAliasTags)),errors.wrap('supplied properties not correct for "CfnBotProps"')}function cfnBotPropsToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBotPropsValidator(properties).assertSuccess(),{DataPrivacy:cdk.objectToCloudFormation(properties.dataPrivacy),IdleSessionTTLInSeconds:cdk.numberToCloudFormation(properties.idleSessionTtlInSeconds),Name:cdk.stringToCloudFormation(properties.name),RoleArn:cdk.stringToCloudFormation(properties.roleArn),AutoBuildBotLocales:cdk.booleanToCloudFormation(properties.autoBuildBotLocales),BotFileS3Location:cfnBotS3LocationPropertyToCloudFormation(properties.botFileS3Location),BotLocales:cdk.listMapper(cfnBotBotLocalePropertyToCloudFormation)(properties.botLocales),BotTags:cdk.listMapper(cdk.cfnTagToCloudFormation)(properties.botTags),Description:cdk.stringToCloudFormation(properties.description),TestBotAliasSettings:cfnBotTestBotAliasSettingsPropertyToCloudFormation(properties.testBotAliasSettings),TestBotAliasTags:cdk.listMapper(cdk.cfnTagToCloudFormation)(properties.testBotAliasTags)}):properties}function CfnBotPropsFromCloudFormation(properties){if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("dataPrivacy","DataPrivacy",cfn_parse.FromCloudFormation.getAny(properties.DataPrivacy)),ret.addPropertyResult("idleSessionTtlInSeconds","IdleSessionTTLInSeconds",cfn_parse.FromCloudFormation.getNumber(properties.IdleSessionTTLInSeconds)),ret.addPropertyResult("name","Name",cfn_parse.FromCloudFormation.getString(properties.Name)),ret.addPropertyResult("roleArn","RoleArn",cfn_parse.FromCloudFormation.getString(properties.RoleArn)),ret.addPropertyResult("autoBuildBotLocales","AutoBuildBotLocales",properties.AutoBuildBotLocales!=null?cfn_parse.FromCloudFormation.getBoolean(properties.AutoBuildBotLocales):void 0),ret.addPropertyResult("botFileS3Location","BotFileS3Location",properties.BotFileS3Location!=null?CfnBotS3LocationPropertyFromCloudFormation(properties.BotFileS3Location):void 0),ret.addPropertyResult("botLocales","BotLocales",properties.BotLocales!=null?cfn_parse.FromCloudFormation.getArray(CfnBotBotLocalePropertyFromCloudFormation)(properties.BotLocales):void 0),ret.addPropertyResult("botTags","BotTags",properties.BotTags!=null?cfn_parse.FromCloudFormation.getArray(cfn_parse.FromCloudFormation.getCfnTag)(properties.BotTags):void 0),ret.addPropertyResult("description","Description",properties.Description!=null?cfn_parse.FromCloudFormation.getString(properties.Description):void 0),ret.addPropertyResult("testBotAliasSettings","TestBotAliasSettings",properties.TestBotAliasSettings!=null?CfnBotTestBotAliasSettingsPropertyFromCloudFormation(properties.TestBotAliasSettings):void 0),ret.addPropertyResult("testBotAliasTags","TestBotAliasTags",properties.TestBotAliasTags!=null?cfn_parse.FromCloudFormation.getArray(cfn_parse.FromCloudFormation.getCfnTag)(properties.TestBotAliasTags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnBot extends cdk.CfnResource{constructor(scope,id,props){super(scope,id,{type:CfnBot.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings.aws_cdk_lib_aws_lex_CfnBotProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnBot),error}cdk.requireProperty(props,"dataPrivacy",this),cdk.requireProperty(props,"idleSessionTtlInSeconds",this),cdk.requireProperty(props,"name",this),cdk.requireProperty(props,"roleArn",this),this.attrArn=cdk.Token.asString(this.getAtt("Arn",cdk.ResolutionTypeHint.STRING)),this.attrId=cdk.Token.asString(this.getAtt("Id",cdk.ResolutionTypeHint.STRING)),this.dataPrivacy=props.dataPrivacy,this.idleSessionTtlInSeconds=props.idleSessionTtlInSeconds,this.name=props.name,this.roleArn=props.roleArn,this.autoBuildBotLocales=props.autoBuildBotLocales,this.botFileS3Location=props.botFileS3Location,this.botLocales=props.botLocales,this.botTags=props.botTags,this.description=props.description,this.testBotAliasSettings=props.testBotAliasSettings,this.testBotAliasTags=props.testBotAliasTags}static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnBotPropsFromCloudFormation(resourceProperties),ret=new CfnBot(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}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",CfnBot.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}get cfnProperties(){return{dataPrivacy:this.dataPrivacy,idleSessionTtlInSeconds:this.idleSessionTtlInSeconds,name:this.name,roleArn:this.roleArn,autoBuildBotLocales:this.autoBuildBotLocales,botFileS3Location:this.botFileS3Location,botLocales:this.botLocales,botTags:this.botTags,description:this.description,testBotAliasSettings:this.testBotAliasSettings,testBotAliasTags:this.testBotAliasTags}}renderProperties(props){return cfnBotPropsToCloudFormation(props)}}exports.CfnBot=CfnBot,_a=JSII_RTTI_SYMBOL_1,CfnBot[_a]={fqn:"aws-cdk-lib.aws_lex.CfnBot",version:"2.70.0"},CfnBot.CFN_RESOURCE_TYPE_NAME="AWS::Lex::Bot";function CfnBot_AdvancedRecognitionSettingPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("audioRecognitionStrategy",cdk.validateString)(properties.audioRecognitionStrategy)),errors.wrap('supplied properties not correct for "AdvancedRecognitionSettingProperty"')}function cfnBotAdvancedRecognitionSettingPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AdvancedRecognitionSettingPropertyValidator(properties).assertSuccess(),{AudioRecognitionStrategy:cdk.stringToCloudFormation(properties.audioRecognitionStrategy)}):properties}function CfnBotAdvancedRecognitionSettingPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("audioRecognitionStrategy","AudioRecognitionStrategy",properties.AudioRecognitionStrategy!=null?cfn_parse.FromCloudFormation.getString(properties.AudioRecognitionStrategy):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_AllowedInputTypesPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("allowAudioInput",cdk.requiredValidator)(properties.allowAudioInput)),errors.collect(cdk.propertyValidator("allowAudioInput",cdk.validateBoolean)(properties.allowAudioInput)),errors.collect(cdk.propertyValidator("allowDtmfInput",cdk.requiredValidator)(properties.allowDtmfInput)),errors.collect(cdk.propertyValidator("allowDtmfInput",cdk.validateBoolean)(properties.allowDtmfInput)),errors.wrap('supplied properties not correct for "AllowedInputTypesProperty"')}function cfnBotAllowedInputTypesPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AllowedInputTypesPropertyValidator(properties).assertSuccess(),{AllowAudioInput:cdk.booleanToCloudFormation(properties.allowAudioInput),AllowDTMFInput:cdk.booleanToCloudFormation(properties.allowDtmfInput)}):properties}function CfnBotAllowedInputTypesPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("allowAudioInput","AllowAudioInput",cfn_parse.FromCloudFormation.getBoolean(properties.AllowAudioInput)),ret.addPropertyResult("allowDtmfInput","AllowDTMFInput",cfn_parse.FromCloudFormation.getBoolean(properties.AllowDTMFInput)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_AudioAndDTMFInputSpecificationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("audioSpecification",CfnBot_AudioSpecificationPropertyValidator)(properties.audioSpecification)),errors.collect(cdk.propertyValidator("dtmfSpecification",CfnBot_DTMFSpecificationPropertyValidator)(properties.dtmfSpecification)),errors.collect(cdk.propertyValidator("startTimeoutMs",cdk.requiredValidator)(properties.startTimeoutMs)),errors.collect(cdk.propertyValidator("startTimeoutMs",cdk.validateNumber)(properties.startTimeoutMs)),errors.wrap('supplied properties not correct for "AudioAndDTMFInputSpecificationProperty"')}function cfnBotAudioAndDTMFInputSpecificationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AudioAndDTMFInputSpecificationPropertyValidator(properties).assertSuccess(),{AudioSpecification:cfnBotAudioSpecificationPropertyToCloudFormation(properties.audioSpecification),DTMFSpecification:cfnBotDTMFSpecificationPropertyToCloudFormation(properties.dtmfSpecification),StartTimeoutMs:cdk.numberToCloudFormation(properties.startTimeoutMs)}):properties}function CfnBotAudioAndDTMFInputSpecificationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("audioSpecification","AudioSpecification",properties.AudioSpecification!=null?CfnBotAudioSpecificationPropertyFromCloudFormation(properties.AudioSpecification):void 0),ret.addPropertyResult("dtmfSpecification","DTMFSpecification",properties.DTMFSpecification!=null?CfnBotDTMFSpecificationPropertyFromCloudFormation(properties.DTMFSpecification):void 0),ret.addPropertyResult("startTimeoutMs","StartTimeoutMs",cfn_parse.FromCloudFormation.getNumber(properties.StartTimeoutMs)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_AudioLogDestinationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("s3Bucket",cdk.requiredValidator)(properties.s3Bucket)),errors.collect(cdk.propertyValidator("s3Bucket",CfnBot_S3BucketLogDestinationPropertyValidator)(properties.s3Bucket)),errors.wrap('supplied properties not correct for "AudioLogDestinationProperty"')}function cfnBotAudioLogDestinationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AudioLogDestinationPropertyValidator(properties).assertSuccess(),{S3Bucket:cfnBotS3BucketLogDestinationPropertyToCloudFormation(properties.s3Bucket)}):properties}function CfnBotAudioLogDestinationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("s3Bucket","S3Bucket",CfnBotS3BucketLogDestinationPropertyFromCloudFormation(properties.S3Bucket)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_AudioLogSettingPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("destination",cdk.requiredValidator)(properties.destination)),errors.collect(cdk.propertyValidator("destination",CfnBot_AudioLogDestinationPropertyValidator)(properties.destination)),errors.collect(cdk.propertyValidator("enabled",cdk.requiredValidator)(properties.enabled)),errors.collect(cdk.propertyValidator("enabled",cdk.validateBoolean)(properties.enabled)),errors.wrap('supplied properties not correct for "AudioLogSettingProperty"')}function cfnBotAudioLogSettingPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AudioLogSettingPropertyValidator(properties).assertSuccess(),{Destination:cfnBotAudioLogDestinationPropertyToCloudFormation(properties.destination),Enabled:cdk.booleanToCloudFormation(properties.enabled)}):properties}function CfnBotAudioLogSettingPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("destination","Destination",CfnBotAudioLogDestinationPropertyFromCloudFormation(properties.Destination)),ret.addPropertyResult("enabled","Enabled",cfn_parse.FromCloudFormation.getBoolean(properties.Enabled)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_AudioSpecificationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("endTimeoutMs",cdk.requiredValidator)(properties.endTimeoutMs)),errors.collect(cdk.propertyValidator("endTimeoutMs",cdk.validateNumber)(properties.endTimeoutMs)),errors.collect(cdk.propertyValidator("maxLengthMs",cdk.requiredValidator)(properties.maxLengthMs)),errors.collect(cdk.propertyValidator("maxLengthMs",cdk.validateNumber)(properties.maxLengthMs)),errors.wrap('supplied properties not correct for "AudioSpecificationProperty"')}function cfnBotAudioSpecificationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_AudioSpecificationPropertyValidator(properties).assertSuccess(),{EndTimeoutMs:cdk.numberToCloudFormation(properties.endTimeoutMs),MaxLengthMs:cdk.numberToCloudFormation(properties.maxLengthMs)}):properties}function CfnBotAudioSpecificationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("endTimeoutMs","EndTimeoutMs",cfn_parse.FromCloudFormation.getNumber(properties.EndTimeoutMs)),ret.addPropertyResult("maxLengthMs","MaxLengthMs",cfn_parse.FromCloudFormation.getNumber(properties.MaxLengthMs)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_BotAliasLocaleSettingsPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("codeHookSpecification",CfnBot_CodeHookSpecificationPropertyValidator)(properties.codeHookSpecification)),errors.collect(cdk.propertyValidator("enabled",cdk.requiredValidator)(properties.enabled)),errors.collect(cdk.propertyValidator("enabled",cdk.validateBoolean)(properties.enabled)),errors.wrap('supplied properties not correct for "BotAliasLocaleSettingsProperty"')}function cfnBotBotAliasLocaleSettingsPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_BotAliasLocaleSettingsPropertyValidator(properties).assertSuccess(),{CodeHookSpecification:cfnBotCodeHookSpecificationPropertyToCloudFormation(properties.codeHookSpecification),Enabled:cdk.booleanToCloudFormation(properties.enabled)}):properties}function CfnBotBotAliasLocaleSettingsPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("codeHookSpecification","CodeHookSpecification",properties.CodeHookSpecification!=null?CfnBotCodeHookSpecificationPropertyFromCloudFormation(properties.CodeHookSpecification):void 0),ret.addPropertyResult("enabled","Enabled",cfn_parse.FromCloudFormation.getBoolean(properties.Enabled)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_BotAliasLocaleSettingsItemPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("botAliasLocaleSetting",cdk.requiredValidator)(properties.botAliasLocaleSetting)),errors.collect(cdk.propertyValidator("botAliasLocaleSetting",CfnBot_BotAliasLocaleSettingsPropertyValidator)(properties.botAliasLocaleSetting)),errors.collect(cdk.propertyValidator("localeId",cdk.requiredValidator)(properties.localeId)),errors.collect(cdk.propertyValidator("localeId",cdk.validateString)(properties.localeId)),errors.wrap('supplied properties not correct for "BotAliasLocaleSettingsItemProperty"')}function cfnBotBotAliasLocaleSettingsItemPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_BotAliasLocaleSettingsItemPropertyValidator(properties).assertSuccess(),{BotAliasLocaleSetting:cfnBotBotAliasLocaleSettingsPropertyToCloudFormation(properties.botAliasLocaleSetting),LocaleId:cdk.stringToCloudFormation(properties.localeId)}):properties}function CfnBotBotAliasLocaleSettingsItemPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("botAliasLocaleSetting","BotAliasLocaleSetting",CfnBotBotAliasLocaleSettingsPropertyFromCloudFormation(properties.BotAliasLocaleSetting)),ret.addPropertyResult("localeId","LocaleId",cfn_parse.FromCloudFormation.getString(properties.LocaleId)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_BotLocalePropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("customVocabulary",CfnBot_CustomVocabularyPropertyValidator)(properties.customVocabulary)),errors.collect(cdk.propertyValidator("description",cdk.validateString)(properties.description)),errors.collect(cdk.propertyValidator("intents",cdk.listValidator(CfnBot_IntentPropertyValidator))(properties.intents)),errors.collect(cdk.propertyValidator("localeId",cdk.requiredValidator)(properties.localeId)),errors.collect(cdk.propertyValidator("localeId",cdk.validateString)(properties.localeId)),errors.collect(cdk.propertyValidator("nluConfidenceThreshold",cdk.requiredValidator)(properties.nluConfidenceThreshold)),errors.collect(cdk.propertyValidator("nluConfidenceThreshold",cdk.validateNumber)(properties.nluConfidenceThreshold)),errors.collect(cdk.propertyValidator("slotTypes",cdk.listValidator(CfnBot_SlotTypePropertyValidator))(properties.slotTypes)),errors.collect(cdk.propertyValidator("voiceSettings",CfnBot_VoiceSettingsPropertyValidator)(properties.voiceSettings)),errors.wrap('supplied properties not correct for "BotLocaleProperty"')}function cfnBotBotLocalePropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_BotLocalePropertyValidator(properties).assertSuccess(),{CustomVocabulary:cfnBotCustomVocabularyPropertyToCloudFormation(properties.customVocabulary),Description:cdk.stringToCloudFormation(properties.description),Intents:cdk.listMapper(cfnBotIntentPropertyToCloudFormation)(properties.intents),LocaleId:cdk.stringToCloudFormation(properties.localeId),NluConfidenceThreshold:cdk.numberToCloudFormation(properties.nluConfidenceThreshold),SlotTypes:cdk.listMapper(cfnBotSlotTypePropertyToCloudFormation)(properties.slotTypes),VoiceSettings:cfnBotVoiceSettingsPropertyToCloudFormation(properties.voiceSettings)}):properties}function CfnBotBotLocalePropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("customVocabulary","CustomVocabulary",properties.CustomVocabulary!=null?CfnBotCustomVocabularyPropertyFromCloudFormation(properties.CustomVocabulary):void 0),ret.addPropertyResult("description","Description",properties.Description!=null?cfn_parse.FromCloudFormation.getString(properties.Description):void 0),ret.addPropertyResult("intents","Intents",properties.Intents!=null?cfn_parse.FromCloudFormation.getArray(CfnBotIntentPropertyFromCloudFormation)(properties.Intents):void 0),ret.addPropertyResult("localeId","LocaleId",cfn_parse.FromCloudFormation.getString(properties.LocaleId)),ret.addPropertyResult("nluConfidenceThreshold","NluConfidenceThreshold",cfn_parse.FromCloudFormation.getNumber(properties.NluConfidenceThreshold)),ret.addPropertyResult("slotTypes","SlotTypes",properties.SlotTypes!=null?cfn_parse.FromCloudFormation.getArray(CfnBotSlotTypePropertyFromCloudFormation)(properties.SlotTypes):void 0),ret.addPropertyResult("voiceSettings","VoiceSettings",properties.VoiceSettings!=null?CfnBotVoiceSettingsPropertyFromCloudFormation(properties.VoiceSettings):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_ButtonPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("text",cdk.requiredValidator)(properties.text)),errors.collect(cdk.propertyValidator("text",cdk.validateString)(properties.text)),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 "ButtonProperty"')}function cfnBotButtonPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_ButtonPropertyValidator(properties).assertSuccess(),{Text:cdk.stringToCloudFormation(properties.text),Value:cdk.stringToCloudFormation(properties.value)}):properties}function CfnBotButtonPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("text","Text",cfn_parse.FromCloudFormation.getString(properties.Text)),ret.addPropertyResult("value","Value",cfn_parse.FromCloudFormation.getString(properties.Value)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_CloudWatchLogGroupLogDestinationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("cloudWatchLogGroupArn",cdk.requiredValidator)(properties.cloudWatchLogGroupArn)),errors.collect(cdk.propertyValidator("cloudWatchLogGroupArn",cdk.validateString)(properties.cloudWatchLogGroupArn)),errors.collect(cdk.propertyValidator("logPrefix",cdk.requiredValidator)(properties.logPrefix)),errors.collect(cdk.propertyValidator("logPrefix",cdk.validateString)(properties.logPrefix)),errors.wrap('supplied properties not correct for "CloudWatchLogGroupLogDestinationProperty"')}function cfnBotCloudWatchLogGroupLogDestinationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_CloudWatchLogGroupLogDestinationPropertyValidator(properties).assertSuccess(),{CloudWatchLogGroupArn:cdk.stringToCloudFormation(properties.cloudWatchLogGroupArn),LogPrefix:cdk.stringToCloudFormation(properties.logPrefix)}):properties}function CfnBotCloudWatchLogGroupLogDestinationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("cloudWatchLogGroupArn","CloudWatchLogGroupArn",cfn_parse.FromCloudFormation.getString(properties.CloudWatchLogGroupArn)),ret.addPropertyResult("logPrefix","LogPrefix",cfn_parse.FromCloudFormation.getString(properties.LogPrefix)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_CodeHookSpecificationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("lambdaCodeHook",cdk.requiredValidator)(properties.lambdaCodeHook)),errors.collect(cdk.propertyValidator("lambdaCodeHook",CfnBot_LambdaCodeHookPropertyValidator)(properties.lambdaCodeHook)),errors.wrap('supplied properties not correct for "CodeHookSpecificationProperty"')}function cfnBotCodeHookSpecificationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_CodeHookSpecificationPropertyValidator(properties).assertSuccess(),{LambdaCodeHook:cfnBotLambdaCodeHookPropertyToCloudFormation(properties.lambdaCodeHook)}):properties}function CfnBotCodeHookSpecificationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("lambdaCodeHook","LambdaCodeHook",CfnBotLambdaCodeHookPropertyFromCloudFormation(properties.LambdaCodeHook)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_ConditionPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("expressionString",cdk.requiredValidator)(properties.expressionString)),errors.collect(cdk.propertyValidator("expressionString",cdk.validateString)(properties.expressionString)),errors.wrap('supplied properties not correct for "ConditionProperty"')}function cfnBotConditionPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_ConditionPropertyValidator(properties).assertSuccess(),{ExpressionString:cdk.stringToCloudFormation(properties.expressionString)}):properties}function CfnBotConditionPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("expressionString","ExpressionString",cfn_parse.FromCloudFormation.getString(properties.ExpressionString)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_ConditionalBranchPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("condition",cdk.requiredValidator)(properties.condition)),errors.collect(cdk.propertyValidator("condition",CfnBot_ConditionPropertyValidator)(properties.condition)),errors.collect(cdk.propertyValidator("name",cdk.requiredValidator)(properties.name)),errors.collect(cdk.propertyValidator("name",cdk.validateString)(properties.name)),errors.collect(cdk.propertyValidator("nextStep",cdk.requiredValidator)(properties.nextStep)),errors.collect(cdk.propertyValidator("nextStep",CfnBot_DialogStatePropertyValidator)(properties.nextStep)),errors.collect(cdk.propertyValidator("response",CfnBot_ResponseSpecificationPropertyValidator)(properties.response)),errors.wrap('supplied properties not correct for "ConditionalBranchProperty"')}function cfnBotConditionalBranchPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_ConditionalBranchPropertyValidator(properties).assertSuccess(),{Condition:cfnBotConditionPropertyToCloudFormation(properties.condition),Name:cdk.stringToCloudFormation(properties.name),NextStep:cfnBotDialogStatePropertyToCloudFormation(properties.nextStep),Response:cfnBotResponseSpecificationPropertyToCloudFormation(properties.response)}):properties}function CfnBotConditionalBranchPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("condition","Condition",CfnBotConditionPropertyFromCloudFormation(properties.Condition)),ret.addPropertyResult("name","Name",cfn_parse.FromCloudFormation.getString(properties.Name)),ret.addPropertyResult("nextStep","NextStep",CfnBotDialogStatePropertyFromCloudFormation(properties.NextStep)),ret.addPropertyResult("response","Response",properties.Response!=null?CfnBotResponseSpecificationPropertyFromCloudFormation(properties.Response):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_ConditionalSpecificationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("conditionalBranches",cdk.requiredValidator)(properties.conditionalBranches)),errors.collect(cdk.propertyValidator("conditionalBranches",cdk.listValidator(CfnBot_ConditionalBranchPropertyValidator))(properties.conditionalBranches)),errors.collect(cdk.propertyValidator("defaultBranch",cdk.requiredValidator)(properties.defaultBranch)),errors.collect(cdk.propertyValidator("defaultBranch",CfnBot_DefaultConditionalBranchPropertyValidator)(properties.defaultBranch)),errors.collect(cdk.propertyValidator("isActive",cdk.requiredValidator)(properties.isActive)),errors.collect(cdk.propertyValidator("isActive",cdk.validateBoolean)(properties.isActive)),errors.wrap('supplied properties not correct for "ConditionalSpecificationProperty"')}function cfnBotConditionalSpecificationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_ConditionalSpecificationPropertyValidator(properties).assertSuccess(),{ConditionalBranches:cdk.listMapper(cfnBotConditionalBranchPropertyToCloudFormation)(properties.conditionalBranches),DefaultBranch:cfnBotDefaultConditionalBranchPropertyToCloudFormation(properties.defaultBranch),IsActive:cdk.booleanToCloudFormation(properties.isActive)}):properties}function CfnBotConditionalSpecificationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("conditionalBranches","ConditionalBranches",cfn_parse.FromCloudFormation.getArray(CfnBotConditionalBranchPropertyFromCloudFormation)(properties.ConditionalBranches)),ret.addPropertyResult("defaultBranch","DefaultBranch",CfnBotDefaultConditionalBranchPropertyFromCloudFormation(properties.DefaultBranch)),ret.addPropertyResult("isActive","IsActive",cfn_parse.FromCloudFormation.getBoolean(properties.IsActive)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_ConversationLogSettingsPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("audioLogSettings",cdk.listValidator(CfnBot_AudioLogSettingPropertyValidator))(properties.audioLogSettings)),errors.collect(cdk.propertyValidator("textLogSettings",cdk.listValidator(CfnBot_TextLogSettingPropertyValidator))(properties.textLogSettings)),errors.wrap('supplied properties not correct for "ConversationLogSettingsProperty"')}function cfnBotConversationLogSettingsPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_ConversationLogSettingsPropertyValidator(properties).assertSuccess(),{AudioLogSettings:cdk.listMapper(cfnBotAudioLogSettingPropertyToCloudFormation)(properties.audioLogSettings),TextLogSettings:cdk.listMapper(cfnBotTextLogSettingPropertyToCloudFormation)(properties.textLogSettings)}):properties}function CfnBotConversationLogSettingsPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("audioLogSettings","AudioLogSettings",properties.AudioLogSettings!=null?cfn_parse.FromCloudFormation.getArray(CfnBotAudioLogSettingPropertyFromCloudFormation)(properties.AudioLogSettings):void 0),ret.addPropertyResult("textLogSettings","TextLogSettings",properties.TextLogSettings!=null?cfn_parse.FromCloudFormation.getArray(CfnBotTextLogSettingPropertyFromCloudFormation)(properties.TextLogSettings):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_CustomPayloadPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),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 "CustomPayloadProperty"')}function cfnBotCustomPayloadPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_CustomPayloadPropertyValidator(properties).assertSuccess(),{Value:cdk.stringToCloudFormation(properties.value)}):properties}function CfnBotCustomPayloadPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("value","Value",cfn_parse.FromCloudFormation.getString(properties.Value)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_CustomVocabularyPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("customVocabularyItems",cdk.requiredValidator)(properties.customVocabularyItems)),errors.collect(cdk.propertyValidator("customVocabularyItems",cdk.listValidator(CfnBot_CustomVocabularyItemPropertyValidator))(properties.customVocabularyItems)),errors.wrap('supplied properties not correct for "CustomVocabularyProperty"')}function cfnBotCustomVocabularyPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_CustomVocabularyPropertyValidator(properties).assertSuccess(),{CustomVocabularyItems:cdk.listMapper(cfnBotCustomVocabularyItemPropertyToCloudFormation)(properties.customVocabularyItems)}):properties}function CfnBotCustomVocabularyPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("customVocabularyItems","CustomVocabularyItems",cfn_parse.FromCloudFormation.getArray(CfnBotCustomVocabularyItemPropertyFromCloudFormation)(properties.CustomVocabularyItems)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_CustomVocabularyItemPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("displayAs",cdk.validateString)(properties.displayAs)),errors.collect(cdk.propertyValidator("phrase",cdk.requiredValidator)(properties.phrase)),errors.collect(cdk.propertyValidator("phrase",cdk.validateString)(properties.phrase)),errors.collect(cdk.propertyValidator("weight",cdk.validateNumber)(properties.weight)),errors.wrap('supplied properties not correct for "CustomVocabularyItemProperty"')}function cfnBotCustomVocabularyItemPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_CustomVocabularyItemPropertyValidator(properties).assertSuccess(),{DisplayAs:cdk.stringToCloudFormation(properties.displayAs),Phrase:cdk.stringToCloudFormation(properties.phrase),Weight:cdk.numberToCloudFormation(properties.weight)}):properties}function CfnBotCustomVocabularyItemPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("displayAs","DisplayAs",properties.DisplayAs!=null?cfn_parse.FromCloudFormation.getString(properties.DisplayAs):void 0),ret.addPropertyResult("phrase","Phrase",cfn_parse.FromCloudFormation.getString(properties.Phrase)),ret.addPropertyResult("weight","Weight",properties.Weight!=null?cfn_parse.FromCloudFormation.getNumber(properties.Weight):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_DTMFSpecificationPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("deletionCharacter",cdk.requiredValidator)(properties.deletionCharacter)),errors.collect(cdk.propertyValidator("deletionCharacter",cdk.validateString)(properties.deletionCharacter)),errors.collect(cdk.propertyValidator("endCharacter",cdk.requiredValidator)(properties.endCharacter)),errors.collect(cdk.propertyValidator("endCharacter",cdk.validateString)(properties.endCharacter)),errors.collect(cdk.propertyValidator("endTimeoutMs",cdk.requiredValidator)(properties.endTimeoutMs)),errors.collect(cdk.propertyValidator("endTimeoutMs",cdk.validateNumber)(properties.endTimeoutMs)),errors.collect(cdk.propertyValidator("maxLength",cdk.requiredValidator)(properties.maxLength)),errors.collect(cdk.propertyValidator("maxLength",cdk.validateNumber)(properties.maxLength)),errors.wrap('supplied properties not correct for "DTMFSpecificationProperty"')}function cfnBotDTMFSpecificationPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_DTMFSpecificationPropertyValidator(properties).assertSuccess(),{DeletionCharacter:cdk.stringToCloudFormation(properties.deletionCharacter),EndCharacter:cdk.stringToCloudFormation(properties.endCharacter),EndTimeoutMs:cdk.numberToCloudFormation(properties.endTimeoutMs),MaxLength:cdk.numberToCloudFormation(properties.maxLength)}):properties}function CfnBotDTMFSpecificationPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("deletionCharacter","DeletionCharacter",cfn_parse.FromCloudFormation.getString(properties.DeletionCharacter)),ret.addPropertyResult("endCharacter","EndCharacter",cfn_parse.FromCloudFormation.getString(properties.EndCharacter)),ret.addPropertyResult("endTimeoutMs","EndTimeoutMs",cfn_parse.FromCloudFormation.getNumber(properties.EndTimeoutMs)),ret.addPropertyResult("maxLength","MaxLength",cfn_parse.FromCloudFormation.getNumber(properties.MaxLength)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_DataPrivacyPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("childDirected",cdk.requiredValidator)(properties.childDirected)),errors.collect(cdk.propertyValidator("childDirected",cdk.validateBoolean)(properties.childDirected)),errors.wrap('supplied properties not correct for "DataPrivacyProperty"')}function cfnBotDataPrivacyPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_DataPrivacyPropertyValidator(properties).assertSuccess(),{ChildDirected:cdk.booleanToCloudFormation(properties.childDirected)}):properties}function CfnBotDataPrivacyPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("childDirected","ChildDirected",cfn_parse.FromCloudFormation.getBoolean(properties.ChildDirected)),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_DefaultConditionalBranchPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("nextStep",CfnBot_DialogStatePropertyValidator)(properties.nextStep)),errors.collect(cdk.propertyValidator("response",CfnBot_ResponseSpecificationPropertyValidator)(properties.response)),errors.wrap('supplied properties not correct for "DefaultConditionalBranchProperty"')}function cfnBotDefaultConditionalBranchPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_DefaultConditionalBranchPropertyValidator(properties).assertSuccess(),{NextStep:cfnBotDialogStatePropertyToCloudFormation(properties.nextStep),Response:cfnBotResponseSpecificationPropertyToCloudFormation(properties.response)}):properties}function CfnBotDefaultConditionalBranchPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof properties!="object")return new cfn_parse.FromCloudFormationResult(properties);const ret=new cfn_parse.FromCloudFormationPropertyObject;return ret.addPropertyResult("nextStep","NextStep",properties.NextStep!=null?CfnBotDialogStatePropertyFromCloudFormation(properties.NextStep):void 0),ret.addPropertyResult("response","Response",properties.Response!=null?CfnBotResponseSpecificationPropertyFromCloudFormation(properties.Response):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBot_DialogActionPropertyValidator(properties){if(!cdk.canInspect(properties))return cdk.VALIDATION_SUCCESS;const errors=new cdk.ValidationResults;return typeof properties!="object"&&errors.collect(new cdk.ValidationResult("Expected an object, but received: "+JSON.stringify(properties))),errors.collect(cdk.propertyValidator("slotToElicit",cdk.validateString)(properties.slotToElicit)),errors.collect(cdk.propertyValidator("suppressNextMessage",cdk.validateBoolean)(properties.suppressNextMessage)),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 "DialogActionProperty"')}function cfnBotDialogActionPropertyToCloudFormation(properties){return cdk.canInspect(properties)?(CfnBot_DialogActionPropertyValidator(properties).assertSuccess(),{SlotToElicit:cdk.stringToCloudFormation(properties.slotToElicit),SuppressNextMessage:cdk.booleanToCloudFormation(properties.suppressNextMessage),Type:cdk.stringToCloudFormation(properties.type)}):properties}function CfnBotDialogActionPropertyFromCloudFormation(properties){if(cdk.isResolvableObject(properties))return new cfn_parse.FromCloudFormationResult(properties);if(properties=properties??{},typeof