"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.CfnStorageLensGroup=exports.CfnAccessGrantsLocation=exports.CfnAccessGrantsInstance=exports.CfnAccessGrant=exports.CfnStorageLens=exports.CfnMultiRegionAccessPointPolicy=exports.CfnMultiRegionAccessPoint=exports.CfnBucketPolicy=exports.CfnBucket=exports.CfnAccessPoint=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/lib");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 CfnAccessPoint extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnAccessPoint",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::AccessPoint";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnAccessPointPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnAccessPoint(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}static isCfnAccessPoint(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnAccessPoint.CFN_RESOURCE_TYPE_NAME}static fromAccessPointArn(scope,id,arn){class Import extends cdk().Resource{accessPointRef;constructor(scope2,id2,arn2){super(scope2,id2,{environmentFromArn:arn2});const variables=new(cfn_parse()).TemplateString("arn:${Partition}:s3:${Region}:${Account}:accesspoint/${AccessPointName}").parse(arn2);this.accessPointRef={accessPointName:variables.AccessPointName,accessPointArn:arn2}}}return new Import(scope,id,arn)}static fromAccessPointName(scope,id,accessPointName){class Import extends cdk().Resource{accessPointRef;constructor(scope2,id2,accessPointName2){const arn=new(cfn_parse()).TemplateString("arn:${Partition}:s3:${Region}:${Account}:accesspoint/${AccessPointName}").interpolate({Partition:cdk().Stack.of(scope2).partition,Region:cdk().Stack.of(scope2).region,Account:cdk().Stack.of(scope2).account,AccessPointName:accessPointName2});super(scope2,id2,{environmentFromArn:arn}),this.accessPointRef={accessPointName:accessPointName2,accessPointArn:arn}}}return new Import(scope,id,accessPointName)}static arnForAccessPoint(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IAccessPointRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForAccessPoint),error}return resource.accessPointRef.accessPointArn}_bucket;_bucketAccountId;cdkTagManager;_name;_policy;_publicAccessBlockConfiguration;_tags;_vpcConfiguration;cfnPropertyNames={bucket:"Bucket",bucketAccountId:"BucketAccountId",tags:"Tags",name:"Name",policy:"Policy",publicAccessBlockConfiguration:"PublicAccessBlockConfiguration",vpcConfiguration:"VpcConfiguration"};constructor(scope,id,props){super(scope,id,{type:CfnAccessPoint.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnAccessPointProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnAccessPoint),error}cdk().requireProperty(props,"bucket",this),this._bucket=cdk().getRefProperty(props.bucket?.bucketRef,"bucketName")??cdk().ensureStringOrUndefined(props.bucket,"bucket","s3.IBucketRef | string"),this._bucketAccountId=props.bucketAccountId,this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::AccessPoint",void 0,{tagPropertyName:"tags"}),this._name=props.name,this._policy=props.policy,this._publicAccessBlockConfiguration=props.publicAccessBlockConfiguration,this._tags=props.tags,this._vpcConfiguration=props.vpcConfiguration}get accessPointRef(){return{accessPointName:this.ref,accessPointArn:this.attrArn}}get bucket(){return this._bucket}set bucket(value){cdk().traceProperty(this.node,"Bucket"),this._bucket=value}get bucketAccountId(){return this._bucketAccountId}set bucketAccountId(value){cdk().traceProperty(this.node,"BucketAccountId"),this._bucketAccountId=value}get name(){return this._name}set name(value){cdk().traceProperty(this.node,"Name"),this._name=value}get policy(){return this._policy}set policy(value){cdk().traceProperty(this.node,"Policy"),this._policy=value}get publicAccessBlockConfiguration(){return this._publicAccessBlockConfiguration}set publicAccessBlockConfiguration(value){cdk().traceProperty(this.node,"PublicAccessBlockConfiguration"),this._publicAccessBlockConfiguration=value}get tags(){return this._tags}set tags(value){cdk().traceProperty(this.node,"Tags"),this._tags=value}get vpcConfiguration(){return this._vpcConfiguration}set vpcConfiguration(value){cdk().traceProperty(this.node,"VpcConfiguration"),this._vpcConfiguration=value}get attrAlias(){return cdk().Token.asString(this.getAtt("Alias",cdk().ResolutionTypeHint.STRING))}get attrArn(){return cdk().Token.asString(this.getAtt("Arn",cdk().ResolutionTypeHint.STRING))}get attrName(){return cdk().Token.asString(this.getAtt("Name",cdk().ResolutionTypeHint.STRING))}get attrNetworkOrigin(){return cdk().Token.asString(this.getAtt("NetworkOrigin",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{bucket:this._bucket,bucketAccountId:this._bucketAccountId,tags:this.cdkTagManager.renderTags(this._tags),name:this._name,policy:this._policy,publicAccessBlockConfiguration:this._publicAccessBlockConfiguration,vpcConfiguration:this._vpcConfiguration}}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",CfnAccessPoint.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnAccessPointPropsToCloudFormation(props)}}exports.CfnAccessPoint=CfnAccessPoint;function CfnAccessPointPublicAccessBlockConfigurationPropertyValidator(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("blockPublicAcls",cdk().validateBoolean)(properties.blockPublicAcls)),errors.collect(cdk().propertyValidator("blockPublicPolicy",cdk().validateBoolean)(properties.blockPublicPolicy)),errors.collect(cdk().propertyValidator("ignorePublicAcls",cdk().validateBoolean)(properties.ignorePublicAcls)),errors.collect(cdk().propertyValidator("restrictPublicBuckets",cdk().validateBoolean)(properties.restrictPublicBuckets)),errors.wrap('supplied properties not correct for "PublicAccessBlockConfigurationProperty"')}function convertCfnAccessPointPublicAccessBlockConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessPointPublicAccessBlockConfigurationPropertyValidator(properties).assertSuccess(),{BlockPublicAcls:cdk().booleanToCloudFormation(properties.blockPublicAcls),BlockPublicPolicy:cdk().booleanToCloudFormation(properties.blockPublicPolicy),IgnorePublicAcls:cdk().booleanToCloudFormation(properties.ignorePublicAcls),RestrictPublicBuckets:cdk().booleanToCloudFormation(properties.restrictPublicBuckets)}):properties}function CfnAccessPointPublicAccessBlockConfigurationPropertyFromCloudFormation(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("blockPublicAcls","BlockPublicAcls",properties.BlockPublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicAcls):void 0),ret.addPropertyResult("blockPublicPolicy","BlockPublicPolicy",properties.BlockPublicPolicy!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicPolicy):void 0),ret.addPropertyResult("ignorePublicAcls","IgnorePublicAcls",properties.IgnorePublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IgnorePublicAcls):void 0),ret.addPropertyResult("restrictPublicBuckets","RestrictPublicBuckets",properties.RestrictPublicBuckets!=null?cfn_parse().FromCloudFormation.getBoolean(properties.RestrictPublicBuckets):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnAccessPointVpcConfigurationPropertyValidator(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("vpcId",cdk().validateString)(properties.vpcId)),errors.wrap('supplied properties not correct for "VpcConfigurationProperty"')}function convertCfnAccessPointVpcConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessPointVpcConfigurationPropertyValidator(properties).assertSuccess(),{VpcId:cdk().stringToCloudFormation(properties.vpcId)}):properties}function CfnAccessPointVpcConfigurationPropertyFromCloudFormation(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("vpcId","VpcId",properties.VpcId!=null?cfn_parse().FromCloudFormation.getString(properties.VpcId):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnAccessPointPropsValidator(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("bucket",cdk().requiredValidator)(properties.bucket)),errors.collect(cdk().propertyValidator("bucket",cdk().validateString)(properties.bucket)),errors.collect(cdk().propertyValidator("bucketAccountId",cdk().validateString)(properties.bucketAccountId)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("policy",cdk().validateObject)(properties.policy)),errors.collect(cdk().propertyValidator("publicAccessBlockConfiguration",CfnAccessPointPublicAccessBlockConfigurationPropertyValidator)(properties.publicAccessBlockConfiguration)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.collect(cdk().propertyValidator("vpcConfiguration",CfnAccessPointVpcConfigurationPropertyValidator)(properties.vpcConfiguration)),errors.wrap('supplied properties not correct for "CfnAccessPointProps"')}function convertCfnAccessPointPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessPointPropsValidator(properties).assertSuccess(),{Bucket:cdk().stringToCloudFormation(properties.bucket),BucketAccountId:cdk().stringToCloudFormation(properties.bucketAccountId),Name:cdk().stringToCloudFormation(properties.name),Policy:cdk().objectToCloudFormation(properties.policy),PublicAccessBlockConfiguration:convertCfnAccessPointPublicAccessBlockConfigurationPropertyToCloudFormation(properties.publicAccessBlockConfiguration),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags),VpcConfiguration:convertCfnAccessPointVpcConfigurationPropertyToCloudFormation(properties.vpcConfiguration)}):properties}function CfnAccessPointPropsFromCloudFormation(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("bucket","Bucket",properties.Bucket!=null?cfn_parse().FromCloudFormation.getString(properties.Bucket):void 0),ret.addPropertyResult("bucketAccountId","BucketAccountId",properties.BucketAccountId!=null?cfn_parse().FromCloudFormation.getString(properties.BucketAccountId):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("policy","Policy",properties.Policy!=null?cfn_parse().FromCloudFormation.getAny(properties.Policy):void 0),ret.addPropertyResult("publicAccessBlockConfiguration","PublicAccessBlockConfiguration",properties.PublicAccessBlockConfiguration!=null?CfnAccessPointPublicAccessBlockConfigurationPropertyFromCloudFormation(properties.PublicAccessBlockConfiguration):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addPropertyResult("vpcConfiguration","VpcConfiguration",properties.VpcConfiguration!=null?CfnAccessPointVpcConfigurationPropertyFromCloudFormation(properties.VpcConfiguration):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnBucket extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnBucket",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::Bucket";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnBucketPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnBucket(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}static isCfnBucket(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnBucket.CFN_RESOURCE_TYPE_NAME}static fromBucketArn(scope,id,arn){class Import extends cdk().Resource{bucketRef;constructor(scope2,id2,arn2){super(scope2,id2,{environmentFromArn:arn2});const variables=new(cfn_parse()).TemplateString("arn:${Partition}:s3:::${BucketName}").parse(arn2);this.bucketRef={bucketName:variables.BucketName,bucketArn:arn2}}}return new Import(scope,id,arn)}static fromBucketName(scope,id,bucketName){class Import extends cdk().Resource{bucketRef;constructor(scope2,id2,bucketName2){const arn=new(cfn_parse()).TemplateString("arn:${Partition}:s3:::${BucketName}").interpolate({Partition:cdk().Stack.of(scope2).partition,Region:cdk().Stack.of(scope2).region,Account:cdk().Stack.of(scope2).account,BucketName:bucketName2});super(scope2,id2,{environmentFromArn:arn}),this.bucketRef={bucketName:bucketName2,bucketArn:arn}}}return new Import(scope,id,bucketName)}static arnForBucket(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IBucketRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForBucket),error}return resource.bucketRef.bucketArn}_abacStatus;_accelerateConfiguration;_accessControl;_analyticsConfigurations;_bucketEncryption;_bucketName;_bucketNamePrefix;_bucketNamespace;_corsConfiguration;_intelligentTieringConfigurations;_inventoryConfigurations;_lifecycleConfiguration;_loggingConfiguration;_metadataConfiguration;_metadataTableConfiguration;_metricsConfigurations;_notificationConfiguration;_objectLockConfiguration;_objectLockEnabled;_ownershipControls;_publicAccessBlockConfiguration;_replicationConfiguration;tags;_tagsRaw;_versioningConfiguration;_websiteConfiguration;cfnPropertyNames={abacStatus:"AbacStatus",accelerateConfiguration:"AccelerateConfiguration",accessControl:"AccessControl",analyticsConfigurations:"AnalyticsConfigurations",bucketEncryption:"BucketEncryption",bucketName:"BucketName",bucketNamePrefix:"BucketNamePrefix",bucketNamespace:"BucketNamespace",corsConfiguration:"CorsConfiguration",intelligentTieringConfigurations:"IntelligentTieringConfigurations",inventoryConfigurations:"InventoryConfigurations",lifecycleConfiguration:"LifecycleConfiguration",loggingConfiguration:"LoggingConfiguration",metadataConfiguration:"MetadataConfiguration",metadataTableConfiguration:"MetadataTableConfiguration",metricsConfigurations:"MetricsConfigurations",notificationConfiguration:"NotificationConfiguration",objectLockConfiguration:"ObjectLockConfiguration",objectLockEnabled:"ObjectLockEnabled",ownershipControls:"OwnershipControls",publicAccessBlockConfiguration:"PublicAccessBlockConfiguration",replicationConfiguration:"ReplicationConfiguration",tags:"Tags",versioningConfiguration:"VersioningConfiguration",websiteConfiguration:"WebsiteConfiguration"};constructor(scope,id,props={}){super(scope,id,{type:CfnBucket.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnBucketProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnBucket),error}this._abacStatus=props.abacStatus,this._accelerateConfiguration=props.accelerateConfiguration,this._accessControl=props.accessControl,this._analyticsConfigurations=props.analyticsConfigurations,this._bucketEncryption=props.bucketEncryption,this._bucketName=props.bucketName,this._bucketNamePrefix=props.bucketNamePrefix,this._bucketNamespace=props.bucketNamespace,this._corsConfiguration=props.corsConfiguration,this._intelligentTieringConfigurations=props.intelligentTieringConfigurations,this._inventoryConfigurations=props.inventoryConfigurations,this._lifecycleConfiguration=props.lifecycleConfiguration,this._loggingConfiguration=props.loggingConfiguration,this._metadataConfiguration=props.metadataConfiguration,this._metadataTableConfiguration=props.metadataTableConfiguration,this._metricsConfigurations=props.metricsConfigurations,this._notificationConfiguration=props.notificationConfiguration,this._objectLockConfiguration=props.objectLockConfiguration,this._objectLockEnabled=props.objectLockEnabled,this._ownershipControls=props.ownershipControls,this._publicAccessBlockConfiguration=props.publicAccessBlockConfiguration,this._replicationConfiguration=props.replicationConfiguration,this.tags=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::Bucket",props.tags,{tagPropertyName:"tags"}),this._tagsRaw=props.tags,this._versioningConfiguration=props.versioningConfiguration,this._websiteConfiguration=props.websiteConfiguration,this.node.scope!=null&&cdk().Resource.isResource(this.node.scope)&&this.node.addValidation({validate:()=>this.cfnOptions.deletionPolicy===void 0?["'AWS::S3::Bucket' is a stateful resource type, and you must specify a Removal Policy for it. Call 'resource.applyRemovalPolicy()'."]:[]})}get bucketRef(){return{bucketName:this.ref,bucketArn:this.attrArn}}get abacStatus(){return this._abacStatus}set abacStatus(value){cdk().traceProperty(this.node,"AbacStatus"),this._abacStatus=value}get accelerateConfiguration(){return this._accelerateConfiguration}set accelerateConfiguration(value){cdk().traceProperty(this.node,"AccelerateConfiguration"),this._accelerateConfiguration=value}get accessControl(){return this._accessControl}set accessControl(value){cdk().traceProperty(this.node,"AccessControl"),this._accessControl=value}get analyticsConfigurations(){return this._analyticsConfigurations}set analyticsConfigurations(value){cdk().traceProperty(this.node,"AnalyticsConfigurations"),this._analyticsConfigurations=value}get bucketEncryption(){return this._bucketEncryption}set bucketEncryption(value){cdk().traceProperty(this.node,"BucketEncryption"),this._bucketEncryption=value}get bucketName(){return this._bucketName}set bucketName(value){cdk().traceProperty(this.node,"BucketName"),this._bucketName=value}get bucketNamePrefix(){return this._bucketNamePrefix}set bucketNamePrefix(value){cdk().traceProperty(this.node,"BucketNamePrefix"),this._bucketNamePrefix=value}get bucketNamespace(){return this._bucketNamespace}set bucketNamespace(value){cdk().traceProperty(this.node,"BucketNamespace"),this._bucketNamespace=value}get corsConfiguration(){return this._corsConfiguration}set corsConfiguration(value){cdk().traceProperty(this.node,"CorsConfiguration"),this._corsConfiguration=value}get intelligentTieringConfigurations(){return this._intelligentTieringConfigurations}set intelligentTieringConfigurations(value){cdk().traceProperty(this.node,"IntelligentTieringConfigurations"),this._intelligentTieringConfigurations=value}get inventoryConfigurations(){return this._inventoryConfigurations}set inventoryConfigurations(value){cdk().traceProperty(this.node,"InventoryConfigurations"),this._inventoryConfigurations=value}get lifecycleConfiguration(){return this._lifecycleConfiguration}set lifecycleConfiguration(value){cdk().traceProperty(this.node,"LifecycleConfiguration"),this._lifecycleConfiguration=value}get loggingConfiguration(){return this._loggingConfiguration}set loggingConfiguration(value){cdk().traceProperty(this.node,"LoggingConfiguration"),this._loggingConfiguration=value}get metadataConfiguration(){return this._metadataConfiguration}set metadataConfiguration(value){cdk().traceProperty(this.node,"MetadataConfiguration"),this._metadataConfiguration=value}get metadataTableConfiguration(){return this._metadataTableConfiguration}set metadataTableConfiguration(value){cdk().traceProperty(this.node,"MetadataTableConfiguration"),this._metadataTableConfiguration=value}get metricsConfigurations(){return this._metricsConfigurations}set metricsConfigurations(value){cdk().traceProperty(this.node,"MetricsConfigurations"),this._metricsConfigurations=value}get notificationConfiguration(){return this._notificationConfiguration}set notificationConfiguration(value){cdk().traceProperty(this.node,"NotificationConfiguration"),this._notificationConfiguration=value}get objectLockConfiguration(){return this._objectLockConfiguration}set objectLockConfiguration(value){cdk().traceProperty(this.node,"ObjectLockConfiguration"),this._objectLockConfiguration=value}get objectLockEnabled(){return this._objectLockEnabled}set objectLockEnabled(value){cdk().traceProperty(this.node,"ObjectLockEnabled"),this._objectLockEnabled=value}get ownershipControls(){return this._ownershipControls}set ownershipControls(value){cdk().traceProperty(this.node,"OwnershipControls"),this._ownershipControls=value}get publicAccessBlockConfiguration(){return this._publicAccessBlockConfiguration}set publicAccessBlockConfiguration(value){cdk().traceProperty(this.node,"PublicAccessBlockConfiguration"),this._publicAccessBlockConfiguration=value}get replicationConfiguration(){return this._replicationConfiguration}set replicationConfiguration(value){cdk().traceProperty(this.node,"ReplicationConfiguration"),this._replicationConfiguration=value}get tagsRaw(){return this._tagsRaw}set tagsRaw(value){cdk().traceProperty(this.node,"Tags"),this._tagsRaw=value}get versioningConfiguration(){return this._versioningConfiguration}set versioningConfiguration(value){cdk().traceProperty(this.node,"VersioningConfiguration"),this._versioningConfiguration=value}get websiteConfiguration(){return this._websiteConfiguration}set websiteConfiguration(value){cdk().traceProperty(this.node,"WebsiteConfiguration"),this._websiteConfiguration=value}get attrArn(){return cdk().Token.asString(this.getAtt("Arn",cdk().ResolutionTypeHint.STRING))}get attrDomainName(){return cdk().Token.asString(this.getAtt("DomainName",cdk().ResolutionTypeHint.STRING))}get attrDualStackDomainName(){return cdk().Token.asString(this.getAtt("DualStackDomainName",cdk().ResolutionTypeHint.STRING))}get attrMetadataConfigurationDestination(){return this.getAtt("MetadataConfiguration.Destination")}get attrMetadataConfigurationInventoryTableConfigurationTableArn(){return cdk().Token.asString(this.getAtt("MetadataConfiguration.InventoryTableConfiguration.TableArn",cdk().ResolutionTypeHint.STRING))}get attrMetadataConfigurationInventoryTableConfigurationTableName(){return cdk().Token.asString(this.getAtt("MetadataConfiguration.InventoryTableConfiguration.TableName",cdk().ResolutionTypeHint.STRING))}get attrMetadataConfigurationJournalTableConfigurationTableArn(){return cdk().Token.asString(this.getAtt("MetadataConfiguration.JournalTableConfiguration.TableArn",cdk().ResolutionTypeHint.STRING))}get attrMetadataConfigurationJournalTableConfigurationTableName(){return cdk().Token.asString(this.getAtt("MetadataConfiguration.JournalTableConfiguration.TableName",cdk().ResolutionTypeHint.STRING))}get attrMetadataTableConfigurationS3TablesDestinationTableArn(){return cdk().Token.asString(this.getAtt("MetadataTableConfiguration.S3TablesDestination.TableArn",cdk().ResolutionTypeHint.STRING))}get attrMetadataTableConfigurationS3TablesDestinationTableNamespace(){return cdk().Token.asString(this.getAtt("MetadataTableConfiguration.S3TablesDestination.TableNamespace",cdk().ResolutionTypeHint.STRING))}get attrRegionalDomainName(){return cdk().Token.asString(this.getAtt("RegionalDomainName",cdk().ResolutionTypeHint.STRING))}get attrWebsiteUrl(){return cdk().Token.asString(this.getAtt("WebsiteURL",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{abacStatus:this._abacStatus,accelerateConfiguration:this._accelerateConfiguration,accessControl:this._accessControl,analyticsConfigurations:this._analyticsConfigurations,bucketEncryption:this._bucketEncryption,bucketName:this._bucketName,bucketNamePrefix:this._bucketNamePrefix,bucketNamespace:this._bucketNamespace,corsConfiguration:this._corsConfiguration,intelligentTieringConfigurations:this._intelligentTieringConfigurations,inventoryConfigurations:this._inventoryConfigurations,lifecycleConfiguration:this._lifecycleConfiguration,loggingConfiguration:this._loggingConfiguration,metadataConfiguration:this._metadataConfiguration,metadataTableConfiguration:this._metadataTableConfiguration,metricsConfigurations:this._metricsConfigurations,notificationConfiguration:this._notificationConfiguration,objectLockConfiguration:this._objectLockConfiguration,objectLockEnabled:this._objectLockEnabled,ownershipControls:this._ownershipControls,publicAccessBlockConfiguration:this._publicAccessBlockConfiguration,replicationConfiguration:this._replicationConfiguration,tags:this.tags.renderTags(),versioningConfiguration:this._versioningConfiguration,websiteConfiguration:this._websiteConfiguration}}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",CfnBucket.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnBucketPropsToCloudFormation(props)}}exports.CfnBucket=CfnBucket;function CfnBucketAccelerateConfigurationPropertyValidator(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("accelerationStatus",cdk().requiredValidator)(properties.accelerationStatus)),errors.collect(cdk().propertyValidator("accelerationStatus",cdk().validateString)(properties.accelerationStatus)),errors.wrap('supplied properties not correct for "AccelerateConfigurationProperty"')}function convertCfnBucketAccelerateConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketAccelerateConfigurationPropertyValidator(properties).assertSuccess(),{AccelerationStatus:cdk().stringToCloudFormation(properties.accelerationStatus)}):properties}function CfnBucketAccelerateConfigurationPropertyFromCloudFormation(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("accelerationStatus","AccelerationStatus",properties.AccelerationStatus!=null?cfn_parse().FromCloudFormation.getString(properties.AccelerationStatus):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketDestinationPropertyValidator(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("bucketAccountId",cdk().validateString)(properties.bucketAccountId)),errors.collect(cdk().propertyValidator("bucketArn",cdk().requiredValidator)(properties.bucketArn)),errors.collect(cdk().propertyValidator("bucketArn",cdk().validateString)(properties.bucketArn)),errors.collect(cdk().propertyValidator("format",cdk().requiredValidator)(properties.format)),errors.collect(cdk().propertyValidator("format",cdk().validateString)(properties.format)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.wrap('supplied properties not correct for "DestinationProperty"')}function convertCfnBucketDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketDestinationPropertyValidator(properties).assertSuccess(),{BucketAccountId:cdk().stringToCloudFormation(properties.bucketAccountId),BucketArn:cdk().stringToCloudFormation(properties.bucketArn),Format:cdk().stringToCloudFormation(properties.format),Prefix:cdk().stringToCloudFormation(properties.prefix)}):properties}function CfnBucketDestinationPropertyFromCloudFormation(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("bucketAccountId","BucketAccountId",properties.BucketAccountId!=null?cfn_parse().FromCloudFormation.getString(properties.BucketAccountId):void 0),ret.addPropertyResult("bucketArn","BucketArn",properties.BucketArn!=null?cfn_parse().FromCloudFormation.getString(properties.BucketArn):void 0),ret.addPropertyResult("format","Format",properties.Format!=null?cfn_parse().FromCloudFormation.getString(properties.Format):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketDataExportPropertyValidator(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("destination",cdk().requiredValidator)(properties.destination)),errors.collect(cdk().propertyValidator("destination",CfnBucketDestinationPropertyValidator)(properties.destination)),errors.collect(cdk().propertyValidator("outputSchemaVersion",cdk().requiredValidator)(properties.outputSchemaVersion)),errors.collect(cdk().propertyValidator("outputSchemaVersion",cdk().validateString)(properties.outputSchemaVersion)),errors.wrap('supplied properties not correct for "DataExportProperty"')}function convertCfnBucketDataExportPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketDataExportPropertyValidator(properties).assertSuccess(),{Destination:convertCfnBucketDestinationPropertyToCloudFormation(properties.destination),OutputSchemaVersion:cdk().stringToCloudFormation(properties.outputSchemaVersion)}):properties}function CfnBucketDataExportPropertyFromCloudFormation(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("destination","Destination",properties.Destination!=null?CfnBucketDestinationPropertyFromCloudFormation(properties.Destination):void 0),ret.addPropertyResult("outputSchemaVersion","OutputSchemaVersion",properties.OutputSchemaVersion!=null?cfn_parse().FromCloudFormation.getString(properties.OutputSchemaVersion):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketStorageClassAnalysisPropertyValidator(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("dataExport",CfnBucketDataExportPropertyValidator)(properties.dataExport)),errors.wrap('supplied properties not correct for "StorageClassAnalysisProperty"')}function convertCfnBucketStorageClassAnalysisPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketStorageClassAnalysisPropertyValidator(properties).assertSuccess(),{DataExport:convertCfnBucketDataExportPropertyToCloudFormation(properties.dataExport)}):properties}function CfnBucketStorageClassAnalysisPropertyFromCloudFormation(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("dataExport","DataExport",properties.DataExport!=null?CfnBucketDataExportPropertyFromCloudFormation(properties.DataExport):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketTagFilterPropertyValidator(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("key",cdk().requiredValidator)(properties.key)),errors.collect(cdk().propertyValidator("key",cdk().validateString)(properties.key)),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 "TagFilterProperty"')}function convertCfnBucketTagFilterPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketTagFilterPropertyValidator(properties).assertSuccess(),{Key:cdk().stringToCloudFormation(properties.key),Value:cdk().stringToCloudFormation(properties.value)}):properties}function CfnBucketTagFilterPropertyFromCloudFormation(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("key","Key",properties.Key!=null?cfn_parse().FromCloudFormation.getString(properties.Key):void 0),ret.addPropertyResult("value","Value",properties.Value!=null?cfn_parse().FromCloudFormation.getString(properties.Value):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketAnalyticsConfigurationPropertyValidator(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("id",cdk().requiredValidator)(properties.id)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("storageClassAnalysis",cdk().requiredValidator)(properties.storageClassAnalysis)),errors.collect(cdk().propertyValidator("storageClassAnalysis",CfnBucketStorageClassAnalysisPropertyValidator)(properties.storageClassAnalysis)),errors.collect(cdk().propertyValidator("tagFilters",cdk().listValidator(CfnBucketTagFilterPropertyValidator))(properties.tagFilters)),errors.wrap('supplied properties not correct for "AnalyticsConfigurationProperty"')}function convertCfnBucketAnalyticsConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketAnalyticsConfigurationPropertyValidator(properties).assertSuccess(),{Id:cdk().stringToCloudFormation(properties.id),Prefix:cdk().stringToCloudFormation(properties.prefix),StorageClassAnalysis:convertCfnBucketStorageClassAnalysisPropertyToCloudFormation(properties.storageClassAnalysis),TagFilters:cdk().listMapper(convertCfnBucketTagFilterPropertyToCloudFormation)(properties.tagFilters)}):properties}function CfnBucketAnalyticsConfigurationPropertyFromCloudFormation(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("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("storageClassAnalysis","StorageClassAnalysis",properties.StorageClassAnalysis!=null?CfnBucketStorageClassAnalysisPropertyFromCloudFormation(properties.StorageClassAnalysis):void 0),ret.addPropertyResult("tagFilters","TagFilters",properties.TagFilters!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTagFilterPropertyFromCloudFormation)(properties.TagFilters):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketServerSideEncryptionByDefaultPropertyValidator(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("kmsMasterKeyId",cdk().validateString)(properties.kmsMasterKeyId)),errors.collect(cdk().propertyValidator("sseAlgorithm",cdk().requiredValidator)(properties.sseAlgorithm)),errors.collect(cdk().propertyValidator("sseAlgorithm",cdk().validateString)(properties.sseAlgorithm)),errors.wrap('supplied properties not correct for "ServerSideEncryptionByDefaultProperty"')}function convertCfnBucketServerSideEncryptionByDefaultPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketServerSideEncryptionByDefaultPropertyValidator(properties).assertSuccess(),{KMSMasterKeyID:cdk().stringToCloudFormation(properties.kmsMasterKeyId),SSEAlgorithm:cdk().stringToCloudFormation(properties.sseAlgorithm)}):properties}function CfnBucketServerSideEncryptionByDefaultPropertyFromCloudFormation(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("kmsMasterKeyId","KMSMasterKeyID",properties.KMSMasterKeyID!=null?cfn_parse().FromCloudFormation.getString(properties.KMSMasterKeyID):void 0),ret.addPropertyResult("sseAlgorithm","SSEAlgorithm",properties.SSEAlgorithm!=null?cfn_parse().FromCloudFormation.getString(properties.SSEAlgorithm):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketBlockedEncryptionTypesPropertyValidator(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("encryptionType",cdk().listValidator(cdk().validateString))(properties.encryptionType)),errors.wrap('supplied properties not correct for "BlockedEncryptionTypesProperty"')}function convertCfnBucketBlockedEncryptionTypesPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketBlockedEncryptionTypesPropertyValidator(properties).assertSuccess(),{EncryptionType:cdk().listMapper(cdk().stringToCloudFormation)(properties.encryptionType)}):properties}function CfnBucketBlockedEncryptionTypesPropertyFromCloudFormation(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("encryptionType","EncryptionType",properties.EncryptionType!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.EncryptionType):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketServerSideEncryptionRulePropertyValidator(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("blockedEncryptionTypes",CfnBucketBlockedEncryptionTypesPropertyValidator)(properties.blockedEncryptionTypes)),errors.collect(cdk().propertyValidator("bucketKeyEnabled",cdk().validateBoolean)(properties.bucketKeyEnabled)),errors.collect(cdk().propertyValidator("serverSideEncryptionByDefault",CfnBucketServerSideEncryptionByDefaultPropertyValidator)(properties.serverSideEncryptionByDefault)),errors.wrap('supplied properties not correct for "ServerSideEncryptionRuleProperty"')}function convertCfnBucketServerSideEncryptionRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketServerSideEncryptionRulePropertyValidator(properties).assertSuccess(),{BlockedEncryptionTypes:convertCfnBucketBlockedEncryptionTypesPropertyToCloudFormation(properties.blockedEncryptionTypes),BucketKeyEnabled:cdk().booleanToCloudFormation(properties.bucketKeyEnabled),ServerSideEncryptionByDefault:convertCfnBucketServerSideEncryptionByDefaultPropertyToCloudFormation(properties.serverSideEncryptionByDefault)}):properties}function CfnBucketServerSideEncryptionRulePropertyFromCloudFormation(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("blockedEncryptionTypes","BlockedEncryptionTypes",properties.BlockedEncryptionTypes!=null?CfnBucketBlockedEncryptionTypesPropertyFromCloudFormation(properties.BlockedEncryptionTypes):void 0),ret.addPropertyResult("bucketKeyEnabled","BucketKeyEnabled",properties.BucketKeyEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BucketKeyEnabled):void 0),ret.addPropertyResult("serverSideEncryptionByDefault","ServerSideEncryptionByDefault",properties.ServerSideEncryptionByDefault!=null?CfnBucketServerSideEncryptionByDefaultPropertyFromCloudFormation(properties.ServerSideEncryptionByDefault):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketBucketEncryptionPropertyValidator(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("serverSideEncryptionConfiguration",cdk().requiredValidator)(properties.serverSideEncryptionConfiguration)),errors.collect(cdk().propertyValidator("serverSideEncryptionConfiguration",cdk().listValidator(CfnBucketServerSideEncryptionRulePropertyValidator))(properties.serverSideEncryptionConfiguration)),errors.wrap('supplied properties not correct for "BucketEncryptionProperty"')}function convertCfnBucketBucketEncryptionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketBucketEncryptionPropertyValidator(properties).assertSuccess(),{ServerSideEncryptionConfiguration:cdk().listMapper(convertCfnBucketServerSideEncryptionRulePropertyToCloudFormation)(properties.serverSideEncryptionConfiguration)}):properties}function CfnBucketBucketEncryptionPropertyFromCloudFormation(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("serverSideEncryptionConfiguration","ServerSideEncryptionConfiguration",properties.ServerSideEncryptionConfiguration!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketServerSideEncryptionRulePropertyFromCloudFormation)(properties.ServerSideEncryptionConfiguration):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketCorsRulePropertyValidator(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("allowedHeaders",cdk().listValidator(cdk().validateString))(properties.allowedHeaders)),errors.collect(cdk().propertyValidator("allowedMethods",cdk().requiredValidator)(properties.allowedMethods)),errors.collect(cdk().propertyValidator("allowedMethods",cdk().listValidator(cdk().validateString))(properties.allowedMethods)),errors.collect(cdk().propertyValidator("allowedOrigins",cdk().requiredValidator)(properties.allowedOrigins)),errors.collect(cdk().propertyValidator("allowedOrigins",cdk().listValidator(cdk().validateString))(properties.allowedOrigins)),errors.collect(cdk().propertyValidator("exposedHeaders",cdk().listValidator(cdk().validateString))(properties.exposedHeaders)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("maxAge",cdk().validateNumber)(properties.maxAge)),errors.wrap('supplied properties not correct for "CorsRuleProperty"')}function convertCfnBucketCorsRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketCorsRulePropertyValidator(properties).assertSuccess(),{AllowedHeaders:cdk().listMapper(cdk().stringToCloudFormation)(properties.allowedHeaders),AllowedMethods:cdk().listMapper(cdk().stringToCloudFormation)(properties.allowedMethods),AllowedOrigins:cdk().listMapper(cdk().stringToCloudFormation)(properties.allowedOrigins),ExposedHeaders:cdk().listMapper(cdk().stringToCloudFormation)(properties.exposedHeaders),Id:cdk().stringToCloudFormation(properties.id),MaxAge:cdk().numberToCloudFormation(properties.maxAge)}):properties}function CfnBucketCorsRulePropertyFromCloudFormation(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("allowedHeaders","AllowedHeaders",properties.AllowedHeaders!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.AllowedHeaders):void 0),ret.addPropertyResult("allowedMethods","AllowedMethods",properties.AllowedMethods!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.AllowedMethods):void 0),ret.addPropertyResult("allowedOrigins","AllowedOrigins",properties.AllowedOrigins!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.AllowedOrigins):void 0),ret.addPropertyResult("exposedHeaders","ExposedHeaders",properties.ExposedHeaders!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.ExposedHeaders):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("maxAge","MaxAge",properties.MaxAge!=null?cfn_parse().FromCloudFormation.getNumber(properties.MaxAge):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketCorsConfigurationPropertyValidator(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("corsRules",cdk().requiredValidator)(properties.corsRules)),errors.collect(cdk().propertyValidator("corsRules",cdk().listValidator(CfnBucketCorsRulePropertyValidator))(properties.corsRules)),errors.wrap('supplied properties not correct for "CorsConfigurationProperty"')}function convertCfnBucketCorsConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketCorsConfigurationPropertyValidator(properties).assertSuccess(),{CorsRules:cdk().listMapper(convertCfnBucketCorsRulePropertyToCloudFormation)(properties.corsRules)}):properties}function CfnBucketCorsConfigurationPropertyFromCloudFormation(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("corsRules","CorsRules",properties.CorsRules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketCorsRulePropertyFromCloudFormation)(properties.CorsRules):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketTieringPropertyValidator(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("accessTier",cdk().requiredValidator)(properties.accessTier)),errors.collect(cdk().propertyValidator("accessTier",cdk().validateString)(properties.accessTier)),errors.collect(cdk().propertyValidator("days",cdk().requiredValidator)(properties.days)),errors.collect(cdk().propertyValidator("days",cdk().validateNumber)(properties.days)),errors.wrap('supplied properties not correct for "TieringProperty"')}function convertCfnBucketTieringPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketTieringPropertyValidator(properties).assertSuccess(),{AccessTier:cdk().stringToCloudFormation(properties.accessTier),Days:cdk().numberToCloudFormation(properties.days)}):properties}function CfnBucketTieringPropertyFromCloudFormation(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("accessTier","AccessTier",properties.AccessTier!=null?cfn_parse().FromCloudFormation.getString(properties.AccessTier):void 0),ret.addPropertyResult("days","Days",properties.Days!=null?cfn_parse().FromCloudFormation.getNumber(properties.Days):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketIntelligentTieringConfigurationPropertyValidator(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("id",cdk().requiredValidator)(properties.id)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.collect(cdk().propertyValidator("tagFilters",cdk().listValidator(CfnBucketTagFilterPropertyValidator))(properties.tagFilters)),errors.collect(cdk().propertyValidator("tierings",cdk().requiredValidator)(properties.tierings)),errors.collect(cdk().propertyValidator("tierings",cdk().listValidator(CfnBucketTieringPropertyValidator))(properties.tierings)),errors.wrap('supplied properties not correct for "IntelligentTieringConfigurationProperty"')}function convertCfnBucketIntelligentTieringConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketIntelligentTieringConfigurationPropertyValidator(properties).assertSuccess(),{Id:cdk().stringToCloudFormation(properties.id),Prefix:cdk().stringToCloudFormation(properties.prefix),Status:cdk().stringToCloudFormation(properties.status),TagFilters:cdk().listMapper(convertCfnBucketTagFilterPropertyToCloudFormation)(properties.tagFilters),Tierings:cdk().listMapper(convertCfnBucketTieringPropertyToCloudFormation)(properties.tierings)}):properties}function CfnBucketIntelligentTieringConfigurationPropertyFromCloudFormation(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("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addPropertyResult("tagFilters","TagFilters",properties.TagFilters!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTagFilterPropertyFromCloudFormation)(properties.TagFilters):void 0),ret.addPropertyResult("tierings","Tierings",properties.Tierings!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTieringPropertyFromCloudFormation)(properties.Tierings):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketInventoryConfigurationPropertyValidator(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("destination",cdk().requiredValidator)(properties.destination)),errors.collect(cdk().propertyValidator("destination",CfnBucketDestinationPropertyValidator)(properties.destination)),errors.collect(cdk().propertyValidator("enabled",cdk().requiredValidator)(properties.enabled)),errors.collect(cdk().propertyValidator("enabled",cdk().validateBoolean)(properties.enabled)),errors.collect(cdk().propertyValidator("id",cdk().requiredValidator)(properties.id)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("includedObjectVersions",cdk().requiredValidator)(properties.includedObjectVersions)),errors.collect(cdk().propertyValidator("includedObjectVersions",cdk().validateString)(properties.includedObjectVersions)),errors.collect(cdk().propertyValidator("optionalFields",cdk().listValidator(cdk().validateString))(properties.optionalFields)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("scheduleFrequency",cdk().requiredValidator)(properties.scheduleFrequency)),errors.collect(cdk().propertyValidator("scheduleFrequency",cdk().validateString)(properties.scheduleFrequency)),errors.wrap('supplied properties not correct for "InventoryConfigurationProperty"')}function convertCfnBucketInventoryConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketInventoryConfigurationPropertyValidator(properties).assertSuccess(),{Destination:convertCfnBucketDestinationPropertyToCloudFormation(properties.destination),Enabled:cdk().booleanToCloudFormation(properties.enabled),Id:cdk().stringToCloudFormation(properties.id),IncludedObjectVersions:cdk().stringToCloudFormation(properties.includedObjectVersions),OptionalFields:cdk().listMapper(cdk().stringToCloudFormation)(properties.optionalFields),Prefix:cdk().stringToCloudFormation(properties.prefix),ScheduleFrequency:cdk().stringToCloudFormation(properties.scheduleFrequency)}):properties}function CfnBucketInventoryConfigurationPropertyFromCloudFormation(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("destination","Destination",properties.Destination!=null?CfnBucketDestinationPropertyFromCloudFormation(properties.Destination):void 0),ret.addPropertyResult("enabled","Enabled",properties.Enabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.Enabled):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("includedObjectVersions","IncludedObjectVersions",properties.IncludedObjectVersions!=null?cfn_parse().FromCloudFormation.getString(properties.IncludedObjectVersions):void 0),ret.addPropertyResult("optionalFields","OptionalFields",properties.OptionalFields!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.OptionalFields):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("scheduleFrequency","ScheduleFrequency",properties.ScheduleFrequency!=null?cfn_parse().FromCloudFormation.getString(properties.ScheduleFrequency):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketAbortIncompleteMultipartUploadPropertyValidator(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("daysAfterInitiation",cdk().requiredValidator)(properties.daysAfterInitiation)),errors.collect(cdk().propertyValidator("daysAfterInitiation",cdk().validateNumber)(properties.daysAfterInitiation)),errors.wrap('supplied properties not correct for "AbortIncompleteMultipartUploadProperty"')}function convertCfnBucketAbortIncompleteMultipartUploadPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketAbortIncompleteMultipartUploadPropertyValidator(properties).assertSuccess(),{DaysAfterInitiation:cdk().numberToCloudFormation(properties.daysAfterInitiation)}):properties}function CfnBucketAbortIncompleteMultipartUploadPropertyFromCloudFormation(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("daysAfterInitiation","DaysAfterInitiation",properties.DaysAfterInitiation!=null?cfn_parse().FromCloudFormation.getNumber(properties.DaysAfterInitiation):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketNoncurrentVersionExpirationPropertyValidator(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("newerNoncurrentVersions",cdk().validateNumber)(properties.newerNoncurrentVersions)),errors.collect(cdk().propertyValidator("noncurrentDays",cdk().requiredValidator)(properties.noncurrentDays)),errors.collect(cdk().propertyValidator("noncurrentDays",cdk().validateNumber)(properties.noncurrentDays)),errors.wrap('supplied properties not correct for "NoncurrentVersionExpirationProperty"')}function convertCfnBucketNoncurrentVersionExpirationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketNoncurrentVersionExpirationPropertyValidator(properties).assertSuccess(),{NewerNoncurrentVersions:cdk().numberToCloudFormation(properties.newerNoncurrentVersions),NoncurrentDays:cdk().numberToCloudFormation(properties.noncurrentDays)}):properties}function CfnBucketNoncurrentVersionExpirationPropertyFromCloudFormation(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("newerNoncurrentVersions","NewerNoncurrentVersions",properties.NewerNoncurrentVersions!=null?cfn_parse().FromCloudFormation.getNumber(properties.NewerNoncurrentVersions):void 0),ret.addPropertyResult("noncurrentDays","NoncurrentDays",properties.NoncurrentDays!=null?cfn_parse().FromCloudFormation.getNumber(properties.NoncurrentDays):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketNoncurrentVersionTransitionPropertyValidator(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("newerNoncurrentVersions",cdk().validateNumber)(properties.newerNoncurrentVersions)),errors.collect(cdk().propertyValidator("storageClass",cdk().requiredValidator)(properties.storageClass)),errors.collect(cdk().propertyValidator("storageClass",cdk().validateString)(properties.storageClass)),errors.collect(cdk().propertyValidator("transitionInDays",cdk().requiredValidator)(properties.transitionInDays)),errors.collect(cdk().propertyValidator("transitionInDays",cdk().validateNumber)(properties.transitionInDays)),errors.wrap('supplied properties not correct for "NoncurrentVersionTransitionProperty"')}function convertCfnBucketNoncurrentVersionTransitionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketNoncurrentVersionTransitionPropertyValidator(properties).assertSuccess(),{NewerNoncurrentVersions:cdk().numberToCloudFormation(properties.newerNoncurrentVersions),StorageClass:cdk().stringToCloudFormation(properties.storageClass),TransitionInDays:cdk().numberToCloudFormation(properties.transitionInDays)}):properties}function CfnBucketNoncurrentVersionTransitionPropertyFromCloudFormation(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("newerNoncurrentVersions","NewerNoncurrentVersions",properties.NewerNoncurrentVersions!=null?cfn_parse().FromCloudFormation.getNumber(properties.NewerNoncurrentVersions):void 0),ret.addPropertyResult("storageClass","StorageClass",properties.StorageClass!=null?cfn_parse().FromCloudFormation.getString(properties.StorageClass):void 0),ret.addPropertyResult("transitionInDays","TransitionInDays",properties.TransitionInDays!=null?cfn_parse().FromCloudFormation.getNumber(properties.TransitionInDays):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketTransitionPropertyValidator(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("storageClass",cdk().requiredValidator)(properties.storageClass)),errors.collect(cdk().propertyValidator("storageClass",cdk().validateString)(properties.storageClass)),errors.collect(cdk().propertyValidator("transitionDate",cdk().validateDate)(properties.transitionDate)),errors.collect(cdk().propertyValidator("transitionInDays",cdk().validateNumber)(properties.transitionInDays)),errors.wrap('supplied properties not correct for "TransitionProperty"')}function convertCfnBucketTransitionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketTransitionPropertyValidator(properties).assertSuccess(),{StorageClass:cdk().stringToCloudFormation(properties.storageClass),TransitionDate:cdk().dateToCloudFormation(properties.transitionDate),TransitionInDays:cdk().numberToCloudFormation(properties.transitionInDays)}):properties}function CfnBucketTransitionPropertyFromCloudFormation(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("storageClass","StorageClass",properties.StorageClass!=null?cfn_parse().FromCloudFormation.getString(properties.StorageClass):void 0),ret.addPropertyResult("transitionDate","TransitionDate",properties.TransitionDate!=null?cfn_parse().FromCloudFormation.getDate(properties.TransitionDate):void 0),ret.addPropertyResult("transitionInDays","TransitionInDays",properties.TransitionInDays!=null?cfn_parse().FromCloudFormation.getNumber(properties.TransitionInDays):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRulePropertyValidator(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("abortIncompleteMultipartUpload",CfnBucketAbortIncompleteMultipartUploadPropertyValidator)(properties.abortIncompleteMultipartUpload)),errors.collect(cdk().propertyValidator("expirationDate",cdk().validateDate)(properties.expirationDate)),errors.collect(cdk().propertyValidator("expirationInDays",cdk().validateNumber)(properties.expirationInDays)),errors.collect(cdk().propertyValidator("expiredObjectDeleteMarker",cdk().validateBoolean)(properties.expiredObjectDeleteMarker)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("noncurrentVersionExpiration",CfnBucketNoncurrentVersionExpirationPropertyValidator)(properties.noncurrentVersionExpiration)),errors.collect(cdk().propertyValidator("noncurrentVersionExpirationInDays",cdk().validateNumber)(properties.noncurrentVersionExpirationInDays)),errors.collect(cdk().propertyValidator("noncurrentVersionTransition",CfnBucketNoncurrentVersionTransitionPropertyValidator)(properties.noncurrentVersionTransition)),errors.collect(cdk().propertyValidator("noncurrentVersionTransitions",cdk().listValidator(CfnBucketNoncurrentVersionTransitionPropertyValidator))(properties.noncurrentVersionTransitions)),errors.collect(cdk().propertyValidator("objectSizeGreaterThan",cdk().validateNumber)(properties.objectSizeGreaterThan)),errors.collect(cdk().propertyValidator("objectSizeLessThan",cdk().validateNumber)(properties.objectSizeLessThan)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.collect(cdk().propertyValidator("tagFilters",cdk().listValidator(CfnBucketTagFilterPropertyValidator))(properties.tagFilters)),errors.collect(cdk().propertyValidator("transition",CfnBucketTransitionPropertyValidator)(properties.transition)),errors.collect(cdk().propertyValidator("transitions",cdk().listValidator(CfnBucketTransitionPropertyValidator))(properties.transitions)),errors.wrap('supplied properties not correct for "RuleProperty"')}function convertCfnBucketRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRulePropertyValidator(properties).assertSuccess(),{AbortIncompleteMultipartUpload:convertCfnBucketAbortIncompleteMultipartUploadPropertyToCloudFormation(properties.abortIncompleteMultipartUpload),ExpirationDate:cdk().dateToCloudFormation(properties.expirationDate),ExpirationInDays:cdk().numberToCloudFormation(properties.expirationInDays),ExpiredObjectDeleteMarker:cdk().booleanToCloudFormation(properties.expiredObjectDeleteMarker),Id:cdk().stringToCloudFormation(properties.id),NoncurrentVersionExpiration:convertCfnBucketNoncurrentVersionExpirationPropertyToCloudFormation(properties.noncurrentVersionExpiration),NoncurrentVersionExpirationInDays:cdk().numberToCloudFormation(properties.noncurrentVersionExpirationInDays),NoncurrentVersionTransition:convertCfnBucketNoncurrentVersionTransitionPropertyToCloudFormation(properties.noncurrentVersionTransition),NoncurrentVersionTransitions:cdk().listMapper(convertCfnBucketNoncurrentVersionTransitionPropertyToCloudFormation)(properties.noncurrentVersionTransitions),ObjectSizeGreaterThan:cdk().numberToCloudFormation(properties.objectSizeGreaterThan),ObjectSizeLessThan:cdk().numberToCloudFormation(properties.objectSizeLessThan),Prefix:cdk().stringToCloudFormation(properties.prefix),Status:cdk().stringToCloudFormation(properties.status),TagFilters:cdk().listMapper(convertCfnBucketTagFilterPropertyToCloudFormation)(properties.tagFilters),Transition:convertCfnBucketTransitionPropertyToCloudFormation(properties.transition),Transitions:cdk().listMapper(convertCfnBucketTransitionPropertyToCloudFormation)(properties.transitions)}):properties}function CfnBucketRulePropertyFromCloudFormation(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("abortIncompleteMultipartUpload","AbortIncompleteMultipartUpload",properties.AbortIncompleteMultipartUpload!=null?CfnBucketAbortIncompleteMultipartUploadPropertyFromCloudFormation(properties.AbortIncompleteMultipartUpload):void 0),ret.addPropertyResult("expirationDate","ExpirationDate",properties.ExpirationDate!=null?cfn_parse().FromCloudFormation.getDate(properties.ExpirationDate):void 0),ret.addPropertyResult("expirationInDays","ExpirationInDays",properties.ExpirationInDays!=null?cfn_parse().FromCloudFormation.getNumber(properties.ExpirationInDays):void 0),ret.addPropertyResult("expiredObjectDeleteMarker","ExpiredObjectDeleteMarker",properties.ExpiredObjectDeleteMarker!=null?cfn_parse().FromCloudFormation.getBoolean(properties.ExpiredObjectDeleteMarker):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("noncurrentVersionExpiration","NoncurrentVersionExpiration",properties.NoncurrentVersionExpiration!=null?CfnBucketNoncurrentVersionExpirationPropertyFromCloudFormation(properties.NoncurrentVersionExpiration):void 0),ret.addPropertyResult("noncurrentVersionExpirationInDays","NoncurrentVersionExpirationInDays",properties.NoncurrentVersionExpirationInDays!=null?cfn_parse().FromCloudFormation.getNumber(properties.NoncurrentVersionExpirationInDays):void 0),ret.addPropertyResult("noncurrentVersionTransition","NoncurrentVersionTransition",properties.NoncurrentVersionTransition!=null?CfnBucketNoncurrentVersionTransitionPropertyFromCloudFormation(properties.NoncurrentVersionTransition):void 0),ret.addPropertyResult("noncurrentVersionTransitions","NoncurrentVersionTransitions",properties.NoncurrentVersionTransitions!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketNoncurrentVersionTransitionPropertyFromCloudFormation)(properties.NoncurrentVersionTransitions):void 0),ret.addPropertyResult("objectSizeGreaterThan","ObjectSizeGreaterThan",properties.ObjectSizeGreaterThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.ObjectSizeGreaterThan):void 0),ret.addPropertyResult("objectSizeLessThan","ObjectSizeLessThan",properties.ObjectSizeLessThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.ObjectSizeLessThan):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addPropertyResult("tagFilters","TagFilters",properties.TagFilters!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTagFilterPropertyFromCloudFormation)(properties.TagFilters):void 0),ret.addPropertyResult("transition","Transition",properties.Transition!=null?CfnBucketTransitionPropertyFromCloudFormation(properties.Transition):void 0),ret.addPropertyResult("transitions","Transitions",properties.Transitions!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTransitionPropertyFromCloudFormation)(properties.Transitions):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketLifecycleConfigurationPropertyValidator(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("rules",cdk().requiredValidator)(properties.rules)),errors.collect(cdk().propertyValidator("rules",cdk().listValidator(CfnBucketRulePropertyValidator))(properties.rules)),errors.collect(cdk().propertyValidator("transitionDefaultMinimumObjectSize",cdk().validateString)(properties.transitionDefaultMinimumObjectSize)),errors.wrap('supplied properties not correct for "LifecycleConfigurationProperty"')}function convertCfnBucketLifecycleConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketLifecycleConfigurationPropertyValidator(properties).assertSuccess(),{Rules:cdk().listMapper(convertCfnBucketRulePropertyToCloudFormation)(properties.rules),TransitionDefaultMinimumObjectSize:cdk().stringToCloudFormation(properties.transitionDefaultMinimumObjectSize)}):properties}function CfnBucketLifecycleConfigurationPropertyFromCloudFormation(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("rules","Rules",properties.Rules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketRulePropertyFromCloudFormation)(properties.Rules):void 0),ret.addPropertyResult("transitionDefaultMinimumObjectSize","TransitionDefaultMinimumObjectSize",properties.TransitionDefaultMinimumObjectSize!=null?cfn_parse().FromCloudFormation.getString(properties.TransitionDefaultMinimumObjectSize):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketPartitionedPrefixPropertyValidator(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("partitionDateSource",cdk().validateString)(properties.partitionDateSource)),errors.wrap('supplied properties not correct for "PartitionedPrefixProperty"')}function convertCfnBucketPartitionedPrefixPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketPartitionedPrefixPropertyValidator(properties).assertSuccess(),{PartitionDateSource:cdk().stringToCloudFormation(properties.partitionDateSource)}):properties}function CfnBucketPartitionedPrefixPropertyFromCloudFormation(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("partitionDateSource","PartitionDateSource",properties.PartitionDateSource!=null?cfn_parse().FromCloudFormation.getString(properties.PartitionDateSource):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketTargetObjectKeyFormatPropertyValidator(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("partitionedPrefix",CfnBucketPartitionedPrefixPropertyValidator)(properties.partitionedPrefix)),errors.collect(cdk().propertyValidator("simplePrefix",cdk().validateObject)(properties.simplePrefix)),errors.wrap('supplied properties not correct for "TargetObjectKeyFormatProperty"')}function convertCfnBucketTargetObjectKeyFormatPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketTargetObjectKeyFormatPropertyValidator(properties).assertSuccess(),{PartitionedPrefix:convertCfnBucketPartitionedPrefixPropertyToCloudFormation(properties.partitionedPrefix),SimplePrefix:cdk().objectToCloudFormation(properties.simplePrefix)}):properties}function CfnBucketTargetObjectKeyFormatPropertyFromCloudFormation(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("partitionedPrefix","PartitionedPrefix",properties.PartitionedPrefix!=null?CfnBucketPartitionedPrefixPropertyFromCloudFormation(properties.PartitionedPrefix):void 0),ret.addPropertyResult("simplePrefix","SimplePrefix",properties.SimplePrefix!=null?cfn_parse().FromCloudFormation.getAny(properties.SimplePrefix):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketLoggingConfigurationPropertyValidator(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("destinationBucketName",cdk().validateString)(properties.destinationBucketName)),errors.collect(cdk().propertyValidator("logFilePrefix",cdk().validateString)(properties.logFilePrefix)),errors.collect(cdk().propertyValidator("targetObjectKeyFormat",CfnBucketTargetObjectKeyFormatPropertyValidator)(properties.targetObjectKeyFormat)),errors.wrap('supplied properties not correct for "LoggingConfigurationProperty"')}function convertCfnBucketLoggingConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketLoggingConfigurationPropertyValidator(properties).assertSuccess(),{DestinationBucketName:cdk().stringToCloudFormation(properties.destinationBucketName),LogFilePrefix:cdk().stringToCloudFormation(properties.logFilePrefix),TargetObjectKeyFormat:convertCfnBucketTargetObjectKeyFormatPropertyToCloudFormation(properties.targetObjectKeyFormat)}):properties}function CfnBucketLoggingConfigurationPropertyFromCloudFormation(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("destinationBucketName","DestinationBucketName",properties.DestinationBucketName!=null?cfn_parse().FromCloudFormation.getString(properties.DestinationBucketName):void 0),ret.addPropertyResult("logFilePrefix","LogFilePrefix",properties.LogFilePrefix!=null?cfn_parse().FromCloudFormation.getString(properties.LogFilePrefix):void 0),ret.addPropertyResult("targetObjectKeyFormat","TargetObjectKeyFormat",properties.TargetObjectKeyFormat!=null?CfnBucketTargetObjectKeyFormatPropertyFromCloudFormation(properties.TargetObjectKeyFormat):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetricsConfigurationPropertyValidator(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("accessPointArn",cdk().validateString)(properties.accessPointArn)),errors.collect(cdk().propertyValidator("id",cdk().requiredValidator)(properties.id)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("tagFilters",cdk().listValidator(CfnBucketTagFilterPropertyValidator))(properties.tagFilters)),errors.wrap('supplied properties not correct for "MetricsConfigurationProperty"')}function convertCfnBucketMetricsConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetricsConfigurationPropertyValidator(properties).assertSuccess(),{AccessPointArn:cdk().stringToCloudFormation(properties.accessPointArn),Id:cdk().stringToCloudFormation(properties.id),Prefix:cdk().stringToCloudFormation(properties.prefix),TagFilters:cdk().listMapper(convertCfnBucketTagFilterPropertyToCloudFormation)(properties.tagFilters)}):properties}function CfnBucketMetricsConfigurationPropertyFromCloudFormation(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("accessPointArn","AccessPointArn",properties.AccessPointArn!=null?cfn_parse().FromCloudFormation.getString(properties.AccessPointArn):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("tagFilters","TagFilters",properties.TagFilters!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTagFilterPropertyFromCloudFormation)(properties.TagFilters):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketEventBridgeConfigurationPropertyValidator(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("eventBridgeEnabled",cdk().requiredValidator)(properties.eventBridgeEnabled)),errors.collect(cdk().propertyValidator("eventBridgeEnabled",cdk().validateBoolean)(properties.eventBridgeEnabled)),errors.wrap('supplied properties not correct for "EventBridgeConfigurationProperty"')}function convertCfnBucketEventBridgeConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketEventBridgeConfigurationPropertyValidator(properties).assertSuccess(),{EventBridgeEnabled:cdk().booleanToCloudFormation(properties.eventBridgeEnabled)}):properties}function CfnBucketEventBridgeConfigurationPropertyFromCloudFormation(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("eventBridgeEnabled","EventBridgeEnabled",properties.EventBridgeEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.EventBridgeEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketFilterRulePropertyValidator(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("value",cdk().requiredValidator)(properties.value)),errors.collect(cdk().propertyValidator("value",cdk().validateString)(properties.value)),errors.wrap('supplied properties not correct for "FilterRuleProperty"')}function convertCfnBucketFilterRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketFilterRulePropertyValidator(properties).assertSuccess(),{Name:cdk().stringToCloudFormation(properties.name),Value:cdk().stringToCloudFormation(properties.value)}):properties}function CfnBucketFilterRulePropertyFromCloudFormation(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("value","Value",properties.Value!=null?cfn_parse().FromCloudFormation.getString(properties.Value):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketS3KeyFilterPropertyValidator(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("rules",cdk().requiredValidator)(properties.rules)),errors.collect(cdk().propertyValidator("rules",cdk().listValidator(CfnBucketFilterRulePropertyValidator))(properties.rules)),errors.wrap('supplied properties not correct for "S3KeyFilterProperty"')}function convertCfnBucketS3KeyFilterPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketS3KeyFilterPropertyValidator(properties).assertSuccess(),{Rules:cdk().listMapper(convertCfnBucketFilterRulePropertyToCloudFormation)(properties.rules)}):properties}function CfnBucketS3KeyFilterPropertyFromCloudFormation(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("rules","Rules",properties.Rules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketFilterRulePropertyFromCloudFormation)(properties.Rules):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketNotificationFilterPropertyValidator(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("s3Key",cdk().requiredValidator)(properties.s3Key)),errors.collect(cdk().propertyValidator("s3Key",CfnBucketS3KeyFilterPropertyValidator)(properties.s3Key)),errors.wrap('supplied properties not correct for "NotificationFilterProperty"')}function convertCfnBucketNotificationFilterPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketNotificationFilterPropertyValidator(properties).assertSuccess(),{S3Key:convertCfnBucketS3KeyFilterPropertyToCloudFormation(properties.s3Key)}):properties}function CfnBucketNotificationFilterPropertyFromCloudFormation(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("s3Key","S3Key",properties.S3Key!=null?CfnBucketS3KeyFilterPropertyFromCloudFormation(properties.S3Key):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketLambdaConfigurationPropertyValidator(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("event",cdk().requiredValidator)(properties.event)),errors.collect(cdk().propertyValidator("event",cdk().validateString)(properties.event)),errors.collect(cdk().propertyValidator("filter",CfnBucketNotificationFilterPropertyValidator)(properties.filter)),errors.collect(cdk().propertyValidator("function",cdk().requiredValidator)(properties.function)),errors.collect(cdk().propertyValidator("function",cdk().validateString)(properties.function)),errors.wrap('supplied properties not correct for "LambdaConfigurationProperty"')}function convertCfnBucketLambdaConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketLambdaConfigurationPropertyValidator(properties).assertSuccess(),{Event:cdk().stringToCloudFormation(properties.event),Filter:convertCfnBucketNotificationFilterPropertyToCloudFormation(properties.filter),Function:cdk().stringToCloudFormation(properties.function)}):properties}function CfnBucketLambdaConfigurationPropertyFromCloudFormation(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("event","Event",properties.Event!=null?cfn_parse().FromCloudFormation.getString(properties.Event):void 0),ret.addPropertyResult("filter","Filter",properties.Filter!=null?CfnBucketNotificationFilterPropertyFromCloudFormation(properties.Filter):void 0),ret.addPropertyResult("function","Function",properties.Function!=null?cfn_parse().FromCloudFormation.getString(properties.Function):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketQueueConfigurationPropertyValidator(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("event",cdk().requiredValidator)(properties.event)),errors.collect(cdk().propertyValidator("event",cdk().validateString)(properties.event)),errors.collect(cdk().propertyValidator("filter",CfnBucketNotificationFilterPropertyValidator)(properties.filter)),errors.collect(cdk().propertyValidator("queue",cdk().requiredValidator)(properties.queue)),errors.collect(cdk().propertyValidator("queue",cdk().validateString)(properties.queue)),errors.wrap('supplied properties not correct for "QueueConfigurationProperty"')}function convertCfnBucketQueueConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketQueueConfigurationPropertyValidator(properties).assertSuccess(),{Event:cdk().stringToCloudFormation(properties.event),Filter:convertCfnBucketNotificationFilterPropertyToCloudFormation(properties.filter),Queue:cdk().stringToCloudFormation(properties.queue)}):properties}function CfnBucketQueueConfigurationPropertyFromCloudFormation(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("event","Event",properties.Event!=null?cfn_parse().FromCloudFormation.getString(properties.Event):void 0),ret.addPropertyResult("filter","Filter",properties.Filter!=null?CfnBucketNotificationFilterPropertyFromCloudFormation(properties.Filter):void 0),ret.addPropertyResult("queue","Queue",properties.Queue!=null?cfn_parse().FromCloudFormation.getString(properties.Queue):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketTopicConfigurationPropertyValidator(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("event",cdk().requiredValidator)(properties.event)),errors.collect(cdk().propertyValidator("event",cdk().validateString)(properties.event)),errors.collect(cdk().propertyValidator("filter",CfnBucketNotificationFilterPropertyValidator)(properties.filter)),errors.collect(cdk().propertyValidator("topic",cdk().requiredValidator)(properties.topic)),errors.collect(cdk().propertyValidator("topic",cdk().validateString)(properties.topic)),errors.wrap('supplied properties not correct for "TopicConfigurationProperty"')}function convertCfnBucketTopicConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketTopicConfigurationPropertyValidator(properties).assertSuccess(),{Event:cdk().stringToCloudFormation(properties.event),Filter:convertCfnBucketNotificationFilterPropertyToCloudFormation(properties.filter),Topic:cdk().stringToCloudFormation(properties.topic)}):properties}function CfnBucketTopicConfigurationPropertyFromCloudFormation(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("event","Event",properties.Event!=null?cfn_parse().FromCloudFormation.getString(properties.Event):void 0),ret.addPropertyResult("filter","Filter",properties.Filter!=null?CfnBucketNotificationFilterPropertyFromCloudFormation(properties.Filter):void 0),ret.addPropertyResult("topic","Topic",properties.Topic!=null?cfn_parse().FromCloudFormation.getString(properties.Topic):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketNotificationConfigurationPropertyValidator(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("eventBridgeConfiguration",CfnBucketEventBridgeConfigurationPropertyValidator)(properties.eventBridgeConfiguration)),errors.collect(cdk().propertyValidator("lambdaConfigurations",cdk().listValidator(CfnBucketLambdaConfigurationPropertyValidator))(properties.lambdaConfigurations)),errors.collect(cdk().propertyValidator("queueConfigurations",cdk().listValidator(CfnBucketQueueConfigurationPropertyValidator))(properties.queueConfigurations)),errors.collect(cdk().propertyValidator("topicConfigurations",cdk().listValidator(CfnBucketTopicConfigurationPropertyValidator))(properties.topicConfigurations)),errors.wrap('supplied properties not correct for "NotificationConfigurationProperty"')}function convertCfnBucketNotificationConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketNotificationConfigurationPropertyValidator(properties).assertSuccess(),{EventBridgeConfiguration:convertCfnBucketEventBridgeConfigurationPropertyToCloudFormation(properties.eventBridgeConfiguration),LambdaConfigurations:cdk().listMapper(convertCfnBucketLambdaConfigurationPropertyToCloudFormation)(properties.lambdaConfigurations),QueueConfigurations:cdk().listMapper(convertCfnBucketQueueConfigurationPropertyToCloudFormation)(properties.queueConfigurations),TopicConfigurations:cdk().listMapper(convertCfnBucketTopicConfigurationPropertyToCloudFormation)(properties.topicConfigurations)}):properties}function CfnBucketNotificationConfigurationPropertyFromCloudFormation(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("eventBridgeConfiguration","EventBridgeConfiguration",properties.EventBridgeConfiguration!=null?CfnBucketEventBridgeConfigurationPropertyFromCloudFormation(properties.EventBridgeConfiguration):void 0),ret.addPropertyResult("lambdaConfigurations","LambdaConfigurations",properties.LambdaConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketLambdaConfigurationPropertyFromCloudFormation)(properties.LambdaConfigurations):void 0),ret.addPropertyResult("queueConfigurations","QueueConfigurations",properties.QueueConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketQueueConfigurationPropertyFromCloudFormation)(properties.QueueConfigurations):void 0),ret.addPropertyResult("topicConfigurations","TopicConfigurations",properties.TopicConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTopicConfigurationPropertyFromCloudFormation)(properties.TopicConfigurations):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketDefaultRetentionPropertyValidator(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("days",cdk().validateNumber)(properties.days)),errors.collect(cdk().propertyValidator("mode",cdk().validateString)(properties.mode)),errors.collect(cdk().propertyValidator("years",cdk().validateNumber)(properties.years)),errors.wrap('supplied properties not correct for "DefaultRetentionProperty"')}function convertCfnBucketDefaultRetentionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketDefaultRetentionPropertyValidator(properties).assertSuccess(),{Days:cdk().numberToCloudFormation(properties.days),Mode:cdk().stringToCloudFormation(properties.mode),Years:cdk().numberToCloudFormation(properties.years)}):properties}function CfnBucketDefaultRetentionPropertyFromCloudFormation(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("days","Days",properties.Days!=null?cfn_parse().FromCloudFormation.getNumber(properties.Days):void 0),ret.addPropertyResult("mode","Mode",properties.Mode!=null?cfn_parse().FromCloudFormation.getString(properties.Mode):void 0),ret.addPropertyResult("years","Years",properties.Years!=null?cfn_parse().FromCloudFormation.getNumber(properties.Years):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketObjectLockRulePropertyValidator(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("defaultRetention",CfnBucketDefaultRetentionPropertyValidator)(properties.defaultRetention)),errors.wrap('supplied properties not correct for "ObjectLockRuleProperty"')}function convertCfnBucketObjectLockRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketObjectLockRulePropertyValidator(properties).assertSuccess(),{DefaultRetention:convertCfnBucketDefaultRetentionPropertyToCloudFormation(properties.defaultRetention)}):properties}function CfnBucketObjectLockRulePropertyFromCloudFormation(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("defaultRetention","DefaultRetention",properties.DefaultRetention!=null?CfnBucketDefaultRetentionPropertyFromCloudFormation(properties.DefaultRetention):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketObjectLockConfigurationPropertyValidator(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("objectLockEnabled",cdk().validateString)(properties.objectLockEnabled)),errors.collect(cdk().propertyValidator("rule",CfnBucketObjectLockRulePropertyValidator)(properties.rule)),errors.wrap('supplied properties not correct for "ObjectLockConfigurationProperty"')}function convertCfnBucketObjectLockConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketObjectLockConfigurationPropertyValidator(properties).assertSuccess(),{ObjectLockEnabled:cdk().stringToCloudFormation(properties.objectLockEnabled),Rule:convertCfnBucketObjectLockRulePropertyToCloudFormation(properties.rule)}):properties}function CfnBucketObjectLockConfigurationPropertyFromCloudFormation(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("objectLockEnabled","ObjectLockEnabled",properties.ObjectLockEnabled!=null?cfn_parse().FromCloudFormation.getString(properties.ObjectLockEnabled):void 0),ret.addPropertyResult("rule","Rule",properties.Rule!=null?CfnBucketObjectLockRulePropertyFromCloudFormation(properties.Rule):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketOwnershipControlsRulePropertyValidator(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("objectOwnership",cdk().validateString)(properties.objectOwnership)),errors.wrap('supplied properties not correct for "OwnershipControlsRuleProperty"')}function convertCfnBucketOwnershipControlsRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketOwnershipControlsRulePropertyValidator(properties).assertSuccess(),{ObjectOwnership:cdk().stringToCloudFormation(properties.objectOwnership)}):properties}function CfnBucketOwnershipControlsRulePropertyFromCloudFormation(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("objectOwnership","ObjectOwnership",properties.ObjectOwnership!=null?cfn_parse().FromCloudFormation.getString(properties.ObjectOwnership):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketOwnershipControlsPropertyValidator(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("rules",cdk().requiredValidator)(properties.rules)),errors.collect(cdk().propertyValidator("rules",cdk().listValidator(CfnBucketOwnershipControlsRulePropertyValidator))(properties.rules)),errors.wrap('supplied properties not correct for "OwnershipControlsProperty"')}function convertCfnBucketOwnershipControlsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketOwnershipControlsPropertyValidator(properties).assertSuccess(),{Rules:cdk().listMapper(convertCfnBucketOwnershipControlsRulePropertyToCloudFormation)(properties.rules)}):properties}function CfnBucketOwnershipControlsPropertyFromCloudFormation(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("rules","Rules",properties.Rules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketOwnershipControlsRulePropertyFromCloudFormation)(properties.Rules):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketPublicAccessBlockConfigurationPropertyValidator(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("blockPublicAcls",cdk().validateBoolean)(properties.blockPublicAcls)),errors.collect(cdk().propertyValidator("blockPublicPolicy",cdk().validateBoolean)(properties.blockPublicPolicy)),errors.collect(cdk().propertyValidator("ignorePublicAcls",cdk().validateBoolean)(properties.ignorePublicAcls)),errors.collect(cdk().propertyValidator("restrictPublicBuckets",cdk().validateBoolean)(properties.restrictPublicBuckets)),errors.wrap('supplied properties not correct for "PublicAccessBlockConfigurationProperty"')}function convertCfnBucketPublicAccessBlockConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketPublicAccessBlockConfigurationPropertyValidator(properties).assertSuccess(),{BlockPublicAcls:cdk().booleanToCloudFormation(properties.blockPublicAcls),BlockPublicPolicy:cdk().booleanToCloudFormation(properties.blockPublicPolicy),IgnorePublicAcls:cdk().booleanToCloudFormation(properties.ignorePublicAcls),RestrictPublicBuckets:cdk().booleanToCloudFormation(properties.restrictPublicBuckets)}):properties}function CfnBucketPublicAccessBlockConfigurationPropertyFromCloudFormation(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("blockPublicAcls","BlockPublicAcls",properties.BlockPublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicAcls):void 0),ret.addPropertyResult("blockPublicPolicy","BlockPublicPolicy",properties.BlockPublicPolicy!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicPolicy):void 0),ret.addPropertyResult("ignorePublicAcls","IgnorePublicAcls",properties.IgnorePublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IgnorePublicAcls):void 0),ret.addPropertyResult("restrictPublicBuckets","RestrictPublicBuckets",properties.RestrictPublicBuckets!=null?cfn_parse().FromCloudFormation.getBoolean(properties.RestrictPublicBuckets):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketDeleteMarkerReplicationPropertyValidator(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("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "DeleteMarkerReplicationProperty"')}function convertCfnBucketDeleteMarkerReplicationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketDeleteMarkerReplicationPropertyValidator(properties).assertSuccess(),{Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketDeleteMarkerReplicationPropertyFromCloudFormation(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("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketAccessControlTranslationPropertyValidator(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("owner",cdk().requiredValidator)(properties.owner)),errors.collect(cdk().propertyValidator("owner",cdk().validateString)(properties.owner)),errors.wrap('supplied properties not correct for "AccessControlTranslationProperty"')}function convertCfnBucketAccessControlTranslationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketAccessControlTranslationPropertyValidator(properties).assertSuccess(),{Owner:cdk().stringToCloudFormation(properties.owner)}):properties}function CfnBucketAccessControlTranslationPropertyFromCloudFormation(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("owner","Owner",properties.Owner!=null?cfn_parse().FromCloudFormation.getString(properties.Owner):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketEncryptionConfigurationPropertyValidator(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("replicaKmsKeyId",cdk().requiredValidator)(properties.replicaKmsKeyId)),errors.collect(cdk().propertyValidator("replicaKmsKeyId",cdk().validateString)(properties.replicaKmsKeyId)),errors.wrap('supplied properties not correct for "EncryptionConfigurationProperty"')}function convertCfnBucketEncryptionConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketEncryptionConfigurationPropertyValidator(properties).assertSuccess(),{ReplicaKmsKeyID:cdk().stringToCloudFormation(properties.replicaKmsKeyId)}):properties}function CfnBucketEncryptionConfigurationPropertyFromCloudFormation(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("replicaKmsKeyId","ReplicaKmsKeyID",properties.ReplicaKmsKeyID!=null?cfn_parse().FromCloudFormation.getString(properties.ReplicaKmsKeyID):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationTimeValuePropertyValidator(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("minutes",cdk().requiredValidator)(properties.minutes)),errors.collect(cdk().propertyValidator("minutes",cdk().validateNumber)(properties.minutes)),errors.wrap('supplied properties not correct for "ReplicationTimeValueProperty"')}function convertCfnBucketReplicationTimeValuePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationTimeValuePropertyValidator(properties).assertSuccess(),{Minutes:cdk().numberToCloudFormation(properties.minutes)}):properties}function CfnBucketReplicationTimeValuePropertyFromCloudFormation(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("minutes","Minutes",properties.Minutes!=null?cfn_parse().FromCloudFormation.getNumber(properties.Minutes):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetricsPropertyValidator(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("eventThreshold",CfnBucketReplicationTimeValuePropertyValidator)(properties.eventThreshold)),errors.collect(cdk().propertyValidator("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "MetricsProperty"')}function convertCfnBucketMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetricsPropertyValidator(properties).assertSuccess(),{EventThreshold:convertCfnBucketReplicationTimeValuePropertyToCloudFormation(properties.eventThreshold),Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketMetricsPropertyFromCloudFormation(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("eventThreshold","EventThreshold",properties.EventThreshold!=null?CfnBucketReplicationTimeValuePropertyFromCloudFormation(properties.EventThreshold):void 0),ret.addPropertyResult("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationTimePropertyValidator(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("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.collect(cdk().propertyValidator("time",cdk().requiredValidator)(properties.time)),errors.collect(cdk().propertyValidator("time",CfnBucketReplicationTimeValuePropertyValidator)(properties.time)),errors.wrap('supplied properties not correct for "ReplicationTimeProperty"')}function convertCfnBucketReplicationTimePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationTimePropertyValidator(properties).assertSuccess(),{Status:cdk().stringToCloudFormation(properties.status),Time:convertCfnBucketReplicationTimeValuePropertyToCloudFormation(properties.time)}):properties}function CfnBucketReplicationTimePropertyFromCloudFormation(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("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addPropertyResult("time","Time",properties.Time!=null?CfnBucketReplicationTimeValuePropertyFromCloudFormation(properties.Time):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationDestinationPropertyValidator(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("accessControlTranslation",CfnBucketAccessControlTranslationPropertyValidator)(properties.accessControlTranslation)),errors.collect(cdk().propertyValidator("account",cdk().validateString)(properties.account)),errors.collect(cdk().propertyValidator("bucket",cdk().requiredValidator)(properties.bucket)),errors.collect(cdk().propertyValidator("bucket",cdk().validateString)(properties.bucket)),errors.collect(cdk().propertyValidator("encryptionConfiguration",CfnBucketEncryptionConfigurationPropertyValidator)(properties.encryptionConfiguration)),errors.collect(cdk().propertyValidator("metrics",CfnBucketMetricsPropertyValidator)(properties.metrics)),errors.collect(cdk().propertyValidator("replicationTime",CfnBucketReplicationTimePropertyValidator)(properties.replicationTime)),errors.collect(cdk().propertyValidator("storageClass",cdk().validateString)(properties.storageClass)),errors.wrap('supplied properties not correct for "ReplicationDestinationProperty"')}function convertCfnBucketReplicationDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationDestinationPropertyValidator(properties).assertSuccess(),{AccessControlTranslation:convertCfnBucketAccessControlTranslationPropertyToCloudFormation(properties.accessControlTranslation),Account:cdk().stringToCloudFormation(properties.account),Bucket:cdk().stringToCloudFormation(properties.bucket),EncryptionConfiguration:convertCfnBucketEncryptionConfigurationPropertyToCloudFormation(properties.encryptionConfiguration),Metrics:convertCfnBucketMetricsPropertyToCloudFormation(properties.metrics),ReplicationTime:convertCfnBucketReplicationTimePropertyToCloudFormation(properties.replicationTime),StorageClass:cdk().stringToCloudFormation(properties.storageClass)}):properties}function CfnBucketReplicationDestinationPropertyFromCloudFormation(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("accessControlTranslation","AccessControlTranslation",properties.AccessControlTranslation!=null?CfnBucketAccessControlTranslationPropertyFromCloudFormation(properties.AccessControlTranslation):void 0),ret.addPropertyResult("account","Account",properties.Account!=null?cfn_parse().FromCloudFormation.getString(properties.Account):void 0),ret.addPropertyResult("bucket","Bucket",properties.Bucket!=null?cfn_parse().FromCloudFormation.getString(properties.Bucket):void 0),ret.addPropertyResult("encryptionConfiguration","EncryptionConfiguration",properties.EncryptionConfiguration!=null?CfnBucketEncryptionConfigurationPropertyFromCloudFormation(properties.EncryptionConfiguration):void 0),ret.addPropertyResult("metrics","Metrics",properties.Metrics!=null?CfnBucketMetricsPropertyFromCloudFormation(properties.Metrics):void 0),ret.addPropertyResult("replicationTime","ReplicationTime",properties.ReplicationTime!=null?CfnBucketReplicationTimePropertyFromCloudFormation(properties.ReplicationTime):void 0),ret.addPropertyResult("storageClass","StorageClass",properties.StorageClass!=null?cfn_parse().FromCloudFormation.getString(properties.StorageClass):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationRuleAndOperatorPropertyValidator(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("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("tagFilters",cdk().listValidator(CfnBucketTagFilterPropertyValidator))(properties.tagFilters)),errors.wrap('supplied properties not correct for "ReplicationRuleAndOperatorProperty"')}function convertCfnBucketReplicationRuleAndOperatorPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationRuleAndOperatorPropertyValidator(properties).assertSuccess(),{Prefix:cdk().stringToCloudFormation(properties.prefix),TagFilters:cdk().listMapper(convertCfnBucketTagFilterPropertyToCloudFormation)(properties.tagFilters)}):properties}function CfnBucketReplicationRuleAndOperatorPropertyFromCloudFormation(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("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("tagFilters","TagFilters",properties.TagFilters!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketTagFilterPropertyFromCloudFormation)(properties.TagFilters):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationRuleFilterPropertyValidator(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("and",CfnBucketReplicationRuleAndOperatorPropertyValidator)(properties.and)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("tagFilter",CfnBucketTagFilterPropertyValidator)(properties.tagFilter)),errors.wrap('supplied properties not correct for "ReplicationRuleFilterProperty"')}function convertCfnBucketReplicationRuleFilterPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationRuleFilterPropertyValidator(properties).assertSuccess(),{And:convertCfnBucketReplicationRuleAndOperatorPropertyToCloudFormation(properties.and),Prefix:cdk().stringToCloudFormation(properties.prefix),TagFilter:convertCfnBucketTagFilterPropertyToCloudFormation(properties.tagFilter)}):properties}function CfnBucketReplicationRuleFilterPropertyFromCloudFormation(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("and","And",properties.And!=null?CfnBucketReplicationRuleAndOperatorPropertyFromCloudFormation(properties.And):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("tagFilter","TagFilter",properties.TagFilter!=null?CfnBucketTagFilterPropertyFromCloudFormation(properties.TagFilter):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicaModificationsPropertyValidator(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("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "ReplicaModificationsProperty"')}function convertCfnBucketReplicaModificationsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicaModificationsPropertyValidator(properties).assertSuccess(),{Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketReplicaModificationsPropertyFromCloudFormation(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("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketSseKmsEncryptedObjectsPropertyValidator(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("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "SseKmsEncryptedObjectsProperty"')}function convertCfnBucketSseKmsEncryptedObjectsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketSseKmsEncryptedObjectsPropertyValidator(properties).assertSuccess(),{Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketSseKmsEncryptedObjectsPropertyFromCloudFormation(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("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketSourceSelectionCriteriaPropertyValidator(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("replicaModifications",CfnBucketReplicaModificationsPropertyValidator)(properties.replicaModifications)),errors.collect(cdk().propertyValidator("sseKmsEncryptedObjects",CfnBucketSseKmsEncryptedObjectsPropertyValidator)(properties.sseKmsEncryptedObjects)),errors.wrap('supplied properties not correct for "SourceSelectionCriteriaProperty"')}function convertCfnBucketSourceSelectionCriteriaPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketSourceSelectionCriteriaPropertyValidator(properties).assertSuccess(),{ReplicaModifications:convertCfnBucketReplicaModificationsPropertyToCloudFormation(properties.replicaModifications),SseKmsEncryptedObjects:convertCfnBucketSseKmsEncryptedObjectsPropertyToCloudFormation(properties.sseKmsEncryptedObjects)}):properties}function CfnBucketSourceSelectionCriteriaPropertyFromCloudFormation(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("replicaModifications","ReplicaModifications",properties.ReplicaModifications!=null?CfnBucketReplicaModificationsPropertyFromCloudFormation(properties.ReplicaModifications):void 0),ret.addPropertyResult("sseKmsEncryptedObjects","SseKmsEncryptedObjects",properties.SseKmsEncryptedObjects!=null?CfnBucketSseKmsEncryptedObjectsPropertyFromCloudFormation(properties.SseKmsEncryptedObjects):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationRulePropertyValidator(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("deleteMarkerReplication",CfnBucketDeleteMarkerReplicationPropertyValidator)(properties.deleteMarkerReplication)),errors.collect(cdk().propertyValidator("destination",cdk().requiredValidator)(properties.destination)),errors.collect(cdk().propertyValidator("destination",CfnBucketReplicationDestinationPropertyValidator)(properties.destination)),errors.collect(cdk().propertyValidator("filter",CfnBucketReplicationRuleFilterPropertyValidator)(properties.filter)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.collect(cdk().propertyValidator("priority",cdk().validateNumber)(properties.priority)),errors.collect(cdk().propertyValidator("sourceSelectionCriteria",CfnBucketSourceSelectionCriteriaPropertyValidator)(properties.sourceSelectionCriteria)),errors.collect(cdk().propertyValidator("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "ReplicationRuleProperty"')}function convertCfnBucketReplicationRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationRulePropertyValidator(properties).assertSuccess(),{DeleteMarkerReplication:convertCfnBucketDeleteMarkerReplicationPropertyToCloudFormation(properties.deleteMarkerReplication),Destination:convertCfnBucketReplicationDestinationPropertyToCloudFormation(properties.destination),Filter:convertCfnBucketReplicationRuleFilterPropertyToCloudFormation(properties.filter),Id:cdk().stringToCloudFormation(properties.id),Prefix:cdk().stringToCloudFormation(properties.prefix),Priority:cdk().numberToCloudFormation(properties.priority),SourceSelectionCriteria:convertCfnBucketSourceSelectionCriteriaPropertyToCloudFormation(properties.sourceSelectionCriteria),Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketReplicationRulePropertyFromCloudFormation(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("deleteMarkerReplication","DeleteMarkerReplication",properties.DeleteMarkerReplication!=null?CfnBucketDeleteMarkerReplicationPropertyFromCloudFormation(properties.DeleteMarkerReplication):void 0),ret.addPropertyResult("destination","Destination",properties.Destination!=null?CfnBucketReplicationDestinationPropertyFromCloudFormation(properties.Destination):void 0),ret.addPropertyResult("filter","Filter",properties.Filter!=null?CfnBucketReplicationRuleFilterPropertyFromCloudFormation(properties.Filter):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addPropertyResult("priority","Priority",properties.Priority!=null?cfn_parse().FromCloudFormation.getNumber(properties.Priority):void 0),ret.addPropertyResult("sourceSelectionCriteria","SourceSelectionCriteria",properties.SourceSelectionCriteria!=null?CfnBucketSourceSelectionCriteriaPropertyFromCloudFormation(properties.SourceSelectionCriteria):void 0),ret.addPropertyResult("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketReplicationConfigurationPropertyValidator(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("role",cdk().requiredValidator)(properties.role)),errors.collect(cdk().propertyValidator("role",cdk().validateString)(properties.role)),errors.collect(cdk().propertyValidator("rules",cdk().requiredValidator)(properties.rules)),errors.collect(cdk().propertyValidator("rules",cdk().listValidator(CfnBucketReplicationRulePropertyValidator))(properties.rules)),errors.wrap('supplied properties not correct for "ReplicationConfigurationProperty"')}function convertCfnBucketReplicationConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketReplicationConfigurationPropertyValidator(properties).assertSuccess(),{Role:cdk().stringToCloudFormation(properties.role),Rules:cdk().listMapper(convertCfnBucketReplicationRulePropertyToCloudFormation)(properties.rules)}):properties}function CfnBucketReplicationConfigurationPropertyFromCloudFormation(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("role","Role",properties.Role!=null?cfn_parse().FromCloudFormation.getString(properties.Role):void 0),ret.addPropertyResult("rules","Rules",properties.Rules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketReplicationRulePropertyFromCloudFormation)(properties.Rules):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketVersioningConfigurationPropertyValidator(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("status",cdk().requiredValidator)(properties.status)),errors.collect(cdk().propertyValidator("status",cdk().validateString)(properties.status)),errors.wrap('supplied properties not correct for "VersioningConfigurationProperty"')}function convertCfnBucketVersioningConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketVersioningConfigurationPropertyValidator(properties).assertSuccess(),{Status:cdk().stringToCloudFormation(properties.status)}):properties}function CfnBucketVersioningConfigurationPropertyFromCloudFormation(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("status","Status",properties.Status!=null?cfn_parse().FromCloudFormation.getString(properties.Status):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRedirectAllRequestsToPropertyValidator(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("hostName",cdk().requiredValidator)(properties.hostName)),errors.collect(cdk().propertyValidator("hostName",cdk().validateString)(properties.hostName)),errors.collect(cdk().propertyValidator("protocol",cdk().validateString)(properties.protocol)),errors.wrap('supplied properties not correct for "RedirectAllRequestsToProperty"')}function convertCfnBucketRedirectAllRequestsToPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRedirectAllRequestsToPropertyValidator(properties).assertSuccess(),{HostName:cdk().stringToCloudFormation(properties.hostName),Protocol:cdk().stringToCloudFormation(properties.protocol)}):properties}function CfnBucketRedirectAllRequestsToPropertyFromCloudFormation(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("hostName","HostName",properties.HostName!=null?cfn_parse().FromCloudFormation.getString(properties.HostName):void 0),ret.addPropertyResult("protocol","Protocol",properties.Protocol!=null?cfn_parse().FromCloudFormation.getString(properties.Protocol):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRedirectRulePropertyValidator(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("hostName",cdk().validateString)(properties.hostName)),errors.collect(cdk().propertyValidator("httpRedirectCode",cdk().validateString)(properties.httpRedirectCode)),errors.collect(cdk().propertyValidator("protocol",cdk().validateString)(properties.protocol)),errors.collect(cdk().propertyValidator("replaceKeyPrefixWith",cdk().validateString)(properties.replaceKeyPrefixWith)),errors.collect(cdk().propertyValidator("replaceKeyWith",cdk().validateString)(properties.replaceKeyWith)),errors.wrap('supplied properties not correct for "RedirectRuleProperty"')}function convertCfnBucketRedirectRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRedirectRulePropertyValidator(properties).assertSuccess(),{HostName:cdk().stringToCloudFormation(properties.hostName),HttpRedirectCode:cdk().stringToCloudFormation(properties.httpRedirectCode),Protocol:cdk().stringToCloudFormation(properties.protocol),ReplaceKeyPrefixWith:cdk().stringToCloudFormation(properties.replaceKeyPrefixWith),ReplaceKeyWith:cdk().stringToCloudFormation(properties.replaceKeyWith)}):properties}function CfnBucketRedirectRulePropertyFromCloudFormation(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("hostName","HostName",properties.HostName!=null?cfn_parse().FromCloudFormation.getString(properties.HostName):void 0),ret.addPropertyResult("httpRedirectCode","HttpRedirectCode",properties.HttpRedirectCode!=null?cfn_parse().FromCloudFormation.getString(properties.HttpRedirectCode):void 0),ret.addPropertyResult("protocol","Protocol",properties.Protocol!=null?cfn_parse().FromCloudFormation.getString(properties.Protocol):void 0),ret.addPropertyResult("replaceKeyPrefixWith","ReplaceKeyPrefixWith",properties.ReplaceKeyPrefixWith!=null?cfn_parse().FromCloudFormation.getString(properties.ReplaceKeyPrefixWith):void 0),ret.addPropertyResult("replaceKeyWith","ReplaceKeyWith",properties.ReplaceKeyWith!=null?cfn_parse().FromCloudFormation.getString(properties.ReplaceKeyWith):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRoutingRuleConditionPropertyValidator(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("httpErrorCodeReturnedEquals",cdk().validateString)(properties.httpErrorCodeReturnedEquals)),errors.collect(cdk().propertyValidator("keyPrefixEquals",cdk().validateString)(properties.keyPrefixEquals)),errors.wrap('supplied properties not correct for "RoutingRuleConditionProperty"')}function convertCfnBucketRoutingRuleConditionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRoutingRuleConditionPropertyValidator(properties).assertSuccess(),{HttpErrorCodeReturnedEquals:cdk().stringToCloudFormation(properties.httpErrorCodeReturnedEquals),KeyPrefixEquals:cdk().stringToCloudFormation(properties.keyPrefixEquals)}):properties}function CfnBucketRoutingRuleConditionPropertyFromCloudFormation(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("httpErrorCodeReturnedEquals","HttpErrorCodeReturnedEquals",properties.HttpErrorCodeReturnedEquals!=null?cfn_parse().FromCloudFormation.getString(properties.HttpErrorCodeReturnedEquals):void 0),ret.addPropertyResult("keyPrefixEquals","KeyPrefixEquals",properties.KeyPrefixEquals!=null?cfn_parse().FromCloudFormation.getString(properties.KeyPrefixEquals):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRoutingRulePropertyValidator(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("redirectRule",cdk().requiredValidator)(properties.redirectRule)),errors.collect(cdk().propertyValidator("redirectRule",CfnBucketRedirectRulePropertyValidator)(properties.redirectRule)),errors.collect(cdk().propertyValidator("routingRuleCondition",CfnBucketRoutingRuleConditionPropertyValidator)(properties.routingRuleCondition)),errors.wrap('supplied properties not correct for "RoutingRuleProperty"')}function convertCfnBucketRoutingRulePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRoutingRulePropertyValidator(properties).assertSuccess(),{RedirectRule:convertCfnBucketRedirectRulePropertyToCloudFormation(properties.redirectRule),RoutingRuleCondition:convertCfnBucketRoutingRuleConditionPropertyToCloudFormation(properties.routingRuleCondition)}):properties}function CfnBucketRoutingRulePropertyFromCloudFormation(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("redirectRule","RedirectRule",properties.RedirectRule!=null?CfnBucketRedirectRulePropertyFromCloudFormation(properties.RedirectRule):void 0),ret.addPropertyResult("routingRuleCondition","RoutingRuleCondition",properties.RoutingRuleCondition!=null?CfnBucketRoutingRuleConditionPropertyFromCloudFormation(properties.RoutingRuleCondition):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketWebsiteConfigurationPropertyValidator(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("errorDocument",cdk().validateString)(properties.errorDocument)),errors.collect(cdk().propertyValidator("indexDocument",cdk().validateString)(properties.indexDocument)),errors.collect(cdk().propertyValidator("redirectAllRequestsTo",CfnBucketRedirectAllRequestsToPropertyValidator)(properties.redirectAllRequestsTo)),errors.collect(cdk().propertyValidator("routingRules",cdk().listValidator(CfnBucketRoutingRulePropertyValidator))(properties.routingRules)),errors.wrap('supplied properties not correct for "WebsiteConfigurationProperty"')}function convertCfnBucketWebsiteConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketWebsiteConfigurationPropertyValidator(properties).assertSuccess(),{ErrorDocument:cdk().stringToCloudFormation(properties.errorDocument),IndexDocument:cdk().stringToCloudFormation(properties.indexDocument),RedirectAllRequestsTo:convertCfnBucketRedirectAllRequestsToPropertyToCloudFormation(properties.redirectAllRequestsTo),RoutingRules:cdk().listMapper(convertCfnBucketRoutingRulePropertyToCloudFormation)(properties.routingRules)}):properties}function CfnBucketWebsiteConfigurationPropertyFromCloudFormation(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("errorDocument","ErrorDocument",properties.ErrorDocument!=null?cfn_parse().FromCloudFormation.getString(properties.ErrorDocument):void 0),ret.addPropertyResult("indexDocument","IndexDocument",properties.IndexDocument!=null?cfn_parse().FromCloudFormation.getString(properties.IndexDocument):void 0),ret.addPropertyResult("redirectAllRequestsTo","RedirectAllRequestsTo",properties.RedirectAllRequestsTo!=null?CfnBucketRedirectAllRequestsToPropertyFromCloudFormation(properties.RedirectAllRequestsTo):void 0),ret.addPropertyResult("routingRules","RoutingRules",properties.RoutingRules!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketRoutingRulePropertyFromCloudFormation)(properties.RoutingRules):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketS3TablesDestinationPropertyValidator(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("tableArn",cdk().validateString)(properties.tableArn)),errors.collect(cdk().propertyValidator("tableBucketArn",cdk().requiredValidator)(properties.tableBucketArn)),errors.collect(cdk().propertyValidator("tableBucketArn",cdk().validateString)(properties.tableBucketArn)),errors.collect(cdk().propertyValidator("tableName",cdk().requiredValidator)(properties.tableName)),errors.collect(cdk().propertyValidator("tableName",cdk().validateString)(properties.tableName)),errors.collect(cdk().propertyValidator("tableNamespace",cdk().validateString)(properties.tableNamespace)),errors.wrap('supplied properties not correct for "S3TablesDestinationProperty"')}function convertCfnBucketS3TablesDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketS3TablesDestinationPropertyValidator(properties).assertSuccess(),{TableArn:cdk().stringToCloudFormation(properties.tableArn),TableBucketArn:cdk().stringToCloudFormation(properties.tableBucketArn),TableName:cdk().stringToCloudFormation(properties.tableName),TableNamespace:cdk().stringToCloudFormation(properties.tableNamespace)}):properties}function CfnBucketS3TablesDestinationPropertyFromCloudFormation(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("tableArn","TableArn",properties.TableArn!=null?cfn_parse().FromCloudFormation.getString(properties.TableArn):void 0),ret.addPropertyResult("tableBucketArn","TableBucketArn",properties.TableBucketArn!=null?cfn_parse().FromCloudFormation.getString(properties.TableBucketArn):void 0),ret.addPropertyResult("tableName","TableName",properties.TableName!=null?cfn_parse().FromCloudFormation.getString(properties.TableName):void 0),ret.addPropertyResult("tableNamespace","TableNamespace",properties.TableNamespace!=null?cfn_parse().FromCloudFormation.getString(properties.TableNamespace):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetadataTableConfigurationPropertyValidator(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("s3TablesDestination",cdk().requiredValidator)(properties.s3TablesDestination)),errors.collect(cdk().propertyValidator("s3TablesDestination",CfnBucketS3TablesDestinationPropertyValidator)(properties.s3TablesDestination)),errors.wrap('supplied properties not correct for "MetadataTableConfigurationProperty"')}function convertCfnBucketMetadataTableConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetadataTableConfigurationPropertyValidator(properties).assertSuccess(),{S3TablesDestination:convertCfnBucketS3TablesDestinationPropertyToCloudFormation(properties.s3TablesDestination)}):properties}function CfnBucketMetadataTableConfigurationPropertyFromCloudFormation(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("s3TablesDestination","S3TablesDestination",properties.S3TablesDestination!=null?CfnBucketS3TablesDestinationPropertyFromCloudFormation(properties.S3TablesDestination):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetadataDestinationPropertyValidator(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("tableBucketArn",cdk().validateString)(properties.tableBucketArn)),errors.collect(cdk().propertyValidator("tableBucketType",cdk().requiredValidator)(properties.tableBucketType)),errors.collect(cdk().propertyValidator("tableBucketType",cdk().validateString)(properties.tableBucketType)),errors.collect(cdk().propertyValidator("tableNamespace",cdk().validateString)(properties.tableNamespace)),errors.wrap('supplied properties not correct for "MetadataDestinationProperty"')}function convertCfnBucketMetadataDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetadataDestinationPropertyValidator(properties).assertSuccess(),{TableBucketArn:cdk().stringToCloudFormation(properties.tableBucketArn),TableBucketType:cdk().stringToCloudFormation(properties.tableBucketType),TableNamespace:cdk().stringToCloudFormation(properties.tableNamespace)}):properties}function CfnBucketMetadataDestinationPropertyFromCloudFormation(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("tableBucketArn","TableBucketArn",properties.TableBucketArn!=null?cfn_parse().FromCloudFormation.getString(properties.TableBucketArn):void 0),ret.addPropertyResult("tableBucketType","TableBucketType",properties.TableBucketType!=null?cfn_parse().FromCloudFormation.getString(properties.TableBucketType):void 0),ret.addPropertyResult("tableNamespace","TableNamespace",properties.TableNamespace!=null?cfn_parse().FromCloudFormation.getString(properties.TableNamespace):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketRecordExpirationPropertyValidator(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("days",cdk().validateNumber)(properties.days)),errors.collect(cdk().propertyValidator("expiration",cdk().requiredValidator)(properties.expiration)),errors.collect(cdk().propertyValidator("expiration",cdk().validateString)(properties.expiration)),errors.wrap('supplied properties not correct for "RecordExpirationProperty"')}function convertCfnBucketRecordExpirationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketRecordExpirationPropertyValidator(properties).assertSuccess(),{Days:cdk().numberToCloudFormation(properties.days),Expiration:cdk().stringToCloudFormation(properties.expiration)}):properties}function CfnBucketRecordExpirationPropertyFromCloudFormation(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("days","Days",properties.Days!=null?cfn_parse().FromCloudFormation.getNumber(properties.Days):void 0),ret.addPropertyResult("expiration","Expiration",properties.Expiration!=null?cfn_parse().FromCloudFormation.getString(properties.Expiration):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetadataTableEncryptionConfigurationPropertyValidator(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("kmsKeyArn",cdk().validateString)(properties.kmsKeyArn)),errors.collect(cdk().propertyValidator("sseAlgorithm",cdk().requiredValidator)(properties.sseAlgorithm)),errors.collect(cdk().propertyValidator("sseAlgorithm",cdk().validateString)(properties.sseAlgorithm)),errors.wrap('supplied properties not correct for "MetadataTableEncryptionConfigurationProperty"')}function convertCfnBucketMetadataTableEncryptionConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetadataTableEncryptionConfigurationPropertyValidator(properties).assertSuccess(),{KmsKeyArn:cdk().stringToCloudFormation(properties.kmsKeyArn),SseAlgorithm:cdk().stringToCloudFormation(properties.sseAlgorithm)}):properties}function CfnBucketMetadataTableEncryptionConfigurationPropertyFromCloudFormation(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("kmsKeyArn","KmsKeyArn",properties.KmsKeyArn!=null?cfn_parse().FromCloudFormation.getString(properties.KmsKeyArn):void 0),ret.addPropertyResult("sseAlgorithm","SseAlgorithm",properties.SseAlgorithm!=null?cfn_parse().FromCloudFormation.getString(properties.SseAlgorithm):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketJournalTableConfigurationPropertyValidator(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("encryptionConfiguration",CfnBucketMetadataTableEncryptionConfigurationPropertyValidator)(properties.encryptionConfiguration)),errors.collect(cdk().propertyValidator("recordExpiration",cdk().requiredValidator)(properties.recordExpiration)),errors.collect(cdk().propertyValidator("recordExpiration",CfnBucketRecordExpirationPropertyValidator)(properties.recordExpiration)),errors.collect(cdk().propertyValidator("tableArn",cdk().validateString)(properties.tableArn)),errors.collect(cdk().propertyValidator("tableName",cdk().validateString)(properties.tableName)),errors.wrap('supplied properties not correct for "JournalTableConfigurationProperty"')}function convertCfnBucketJournalTableConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketJournalTableConfigurationPropertyValidator(properties).assertSuccess(),{EncryptionConfiguration:convertCfnBucketMetadataTableEncryptionConfigurationPropertyToCloudFormation(properties.encryptionConfiguration),RecordExpiration:convertCfnBucketRecordExpirationPropertyToCloudFormation(properties.recordExpiration),TableArn:cdk().stringToCloudFormation(properties.tableArn),TableName:cdk().stringToCloudFormation(properties.tableName)}):properties}function CfnBucketJournalTableConfigurationPropertyFromCloudFormation(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("encryptionConfiguration","EncryptionConfiguration",properties.EncryptionConfiguration!=null?CfnBucketMetadataTableEncryptionConfigurationPropertyFromCloudFormation(properties.EncryptionConfiguration):void 0),ret.addPropertyResult("recordExpiration","RecordExpiration",properties.RecordExpiration!=null?CfnBucketRecordExpirationPropertyFromCloudFormation(properties.RecordExpiration):void 0),ret.addPropertyResult("tableArn","TableArn",properties.TableArn!=null?cfn_parse().FromCloudFormation.getString(properties.TableArn):void 0),ret.addPropertyResult("tableName","TableName",properties.TableName!=null?cfn_parse().FromCloudFormation.getString(properties.TableName):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketInventoryTableConfigurationPropertyValidator(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("configurationState",cdk().requiredValidator)(properties.configurationState)),errors.collect(cdk().propertyValidator("configurationState",cdk().validateString)(properties.configurationState)),errors.collect(cdk().propertyValidator("encryptionConfiguration",CfnBucketMetadataTableEncryptionConfigurationPropertyValidator)(properties.encryptionConfiguration)),errors.collect(cdk().propertyValidator("tableArn",cdk().validateString)(properties.tableArn)),errors.collect(cdk().propertyValidator("tableName",cdk().validateString)(properties.tableName)),errors.wrap('supplied properties not correct for "InventoryTableConfigurationProperty"')}function convertCfnBucketInventoryTableConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketInventoryTableConfigurationPropertyValidator(properties).assertSuccess(),{ConfigurationState:cdk().stringToCloudFormation(properties.configurationState),EncryptionConfiguration:convertCfnBucketMetadataTableEncryptionConfigurationPropertyToCloudFormation(properties.encryptionConfiguration),TableArn:cdk().stringToCloudFormation(properties.tableArn),TableName:cdk().stringToCloudFormation(properties.tableName)}):properties}function CfnBucketInventoryTableConfigurationPropertyFromCloudFormation(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("configurationState","ConfigurationState",properties.ConfigurationState!=null?cfn_parse().FromCloudFormation.getString(properties.ConfigurationState):void 0),ret.addPropertyResult("encryptionConfiguration","EncryptionConfiguration",properties.EncryptionConfiguration!=null?CfnBucketMetadataTableEncryptionConfigurationPropertyFromCloudFormation(properties.EncryptionConfiguration):void 0),ret.addPropertyResult("tableArn","TableArn",properties.TableArn!=null?cfn_parse().FromCloudFormation.getString(properties.TableArn):void 0),ret.addPropertyResult("tableName","TableName",properties.TableName!=null?cfn_parse().FromCloudFormation.getString(properties.TableName):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketMetadataConfigurationPropertyValidator(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("destination",CfnBucketMetadataDestinationPropertyValidator)(properties.destination)),errors.collect(cdk().propertyValidator("inventoryTableConfiguration",CfnBucketInventoryTableConfigurationPropertyValidator)(properties.inventoryTableConfiguration)),errors.collect(cdk().propertyValidator("journalTableConfiguration",cdk().requiredValidator)(properties.journalTableConfiguration)),errors.collect(cdk().propertyValidator("journalTableConfiguration",CfnBucketJournalTableConfigurationPropertyValidator)(properties.journalTableConfiguration)),errors.wrap('supplied properties not correct for "MetadataConfigurationProperty"')}function convertCfnBucketMetadataConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketMetadataConfigurationPropertyValidator(properties).assertSuccess(),{Destination:convertCfnBucketMetadataDestinationPropertyToCloudFormation(properties.destination),InventoryTableConfiguration:convertCfnBucketInventoryTableConfigurationPropertyToCloudFormation(properties.inventoryTableConfiguration),JournalTableConfiguration:convertCfnBucketJournalTableConfigurationPropertyToCloudFormation(properties.journalTableConfiguration)}):properties}function CfnBucketMetadataConfigurationPropertyFromCloudFormation(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("destination","Destination",properties.Destination!=null?CfnBucketMetadataDestinationPropertyFromCloudFormation(properties.Destination):void 0),ret.addPropertyResult("inventoryTableConfiguration","InventoryTableConfiguration",properties.InventoryTableConfiguration!=null?CfnBucketInventoryTableConfigurationPropertyFromCloudFormation(properties.InventoryTableConfiguration):void 0),ret.addPropertyResult("journalTableConfiguration","JournalTableConfiguration",properties.JournalTableConfiguration!=null?CfnBucketJournalTableConfigurationPropertyFromCloudFormation(properties.JournalTableConfiguration):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnBucketPropsValidator(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("abacStatus",cdk().validateString)(properties.abacStatus)),errors.collect(cdk().propertyValidator("accelerateConfiguration",CfnBucketAccelerateConfigurationPropertyValidator)(properties.accelerateConfiguration)),errors.collect(cdk().propertyValidator("accessControl",cdk().validateString)(properties.accessControl)),errors.collect(cdk().propertyValidator("analyticsConfigurations",cdk().listValidator(CfnBucketAnalyticsConfigurationPropertyValidator))(properties.analyticsConfigurations)),errors.collect(cdk().propertyValidator("bucketEncryption",CfnBucketBucketEncryptionPropertyValidator)(properties.bucketEncryption)),errors.collect(cdk().propertyValidator("bucketName",cdk().validateString)(properties.bucketName)),errors.collect(cdk().propertyValidator("bucketNamePrefix",cdk().validateString)(properties.bucketNamePrefix)),errors.collect(cdk().propertyValidator("bucketNamespace",cdk().validateString)(properties.bucketNamespace)),errors.collect(cdk().propertyValidator("corsConfiguration",CfnBucketCorsConfigurationPropertyValidator)(properties.corsConfiguration)),errors.collect(cdk().propertyValidator("intelligentTieringConfigurations",cdk().listValidator(CfnBucketIntelligentTieringConfigurationPropertyValidator))(properties.intelligentTieringConfigurations)),errors.collect(cdk().propertyValidator("inventoryConfigurations",cdk().listValidator(CfnBucketInventoryConfigurationPropertyValidator))(properties.inventoryConfigurations)),errors.collect(cdk().propertyValidator("lifecycleConfiguration",CfnBucketLifecycleConfigurationPropertyValidator)(properties.lifecycleConfiguration)),errors.collect(cdk().propertyValidator("loggingConfiguration",CfnBucketLoggingConfigurationPropertyValidator)(properties.loggingConfiguration)),errors.collect(cdk().propertyValidator("metadataConfiguration",CfnBucketMetadataConfigurationPropertyValidator)(properties.metadataConfiguration)),errors.collect(cdk().propertyValidator("metadataTableConfiguration",CfnBucketMetadataTableConfigurationPropertyValidator)(properties.metadataTableConfiguration)),errors.collect(cdk().propertyValidator("metricsConfigurations",cdk().listValidator(CfnBucketMetricsConfigurationPropertyValidator))(properties.metricsConfigurations)),errors.collect(cdk().propertyValidator("notificationConfiguration",CfnBucketNotificationConfigurationPropertyValidator)(properties.notificationConfiguration)),errors.collect(cdk().propertyValidator("objectLockConfiguration",CfnBucketObjectLockConfigurationPropertyValidator)(properties.objectLockConfiguration)),errors.collect(cdk().propertyValidator("objectLockEnabled",cdk().validateBoolean)(properties.objectLockEnabled)),errors.collect(cdk().propertyValidator("ownershipControls",CfnBucketOwnershipControlsPropertyValidator)(properties.ownershipControls)),errors.collect(cdk().propertyValidator("publicAccessBlockConfiguration",CfnBucketPublicAccessBlockConfigurationPropertyValidator)(properties.publicAccessBlockConfiguration)),errors.collect(cdk().propertyValidator("replicationConfiguration",CfnBucketReplicationConfigurationPropertyValidator)(properties.replicationConfiguration)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.collect(cdk().propertyValidator("versioningConfiguration",CfnBucketVersioningConfigurationPropertyValidator)(properties.versioningConfiguration)),errors.collect(cdk().propertyValidator("websiteConfiguration",CfnBucketWebsiteConfigurationPropertyValidator)(properties.websiteConfiguration)),errors.wrap('supplied properties not correct for "CfnBucketProps"')}function convertCfnBucketPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketPropsValidator(properties).assertSuccess(),{AbacStatus:cdk().stringToCloudFormation(properties.abacStatus),AccelerateConfiguration:convertCfnBucketAccelerateConfigurationPropertyToCloudFormation(properties.accelerateConfiguration),AccessControl:cdk().stringToCloudFormation(properties.accessControl),AnalyticsConfigurations:cdk().listMapper(convertCfnBucketAnalyticsConfigurationPropertyToCloudFormation)(properties.analyticsConfigurations),BucketEncryption:convertCfnBucketBucketEncryptionPropertyToCloudFormation(properties.bucketEncryption),BucketName:cdk().stringToCloudFormation(properties.bucketName),BucketNamePrefix:cdk().stringToCloudFormation(properties.bucketNamePrefix),BucketNamespace:cdk().stringToCloudFormation(properties.bucketNamespace),CorsConfiguration:convertCfnBucketCorsConfigurationPropertyToCloudFormation(properties.corsConfiguration),IntelligentTieringConfigurations:cdk().listMapper(convertCfnBucketIntelligentTieringConfigurationPropertyToCloudFormation)(properties.intelligentTieringConfigurations),InventoryConfigurations:cdk().listMapper(convertCfnBucketInventoryConfigurationPropertyToCloudFormation)(properties.inventoryConfigurations),LifecycleConfiguration:convertCfnBucketLifecycleConfigurationPropertyToCloudFormation(properties.lifecycleConfiguration),LoggingConfiguration:convertCfnBucketLoggingConfigurationPropertyToCloudFormation(properties.loggingConfiguration),MetadataConfiguration:convertCfnBucketMetadataConfigurationPropertyToCloudFormation(properties.metadataConfiguration),MetadataTableConfiguration:convertCfnBucketMetadataTableConfigurationPropertyToCloudFormation(properties.metadataTableConfiguration),MetricsConfigurations:cdk().listMapper(convertCfnBucketMetricsConfigurationPropertyToCloudFormation)(properties.metricsConfigurations),NotificationConfiguration:convertCfnBucketNotificationConfigurationPropertyToCloudFormation(properties.notificationConfiguration),ObjectLockConfiguration:convertCfnBucketObjectLockConfigurationPropertyToCloudFormation(properties.objectLockConfiguration),ObjectLockEnabled:cdk().booleanToCloudFormation(properties.objectLockEnabled),OwnershipControls:convertCfnBucketOwnershipControlsPropertyToCloudFormation(properties.ownershipControls),PublicAccessBlockConfiguration:convertCfnBucketPublicAccessBlockConfigurationPropertyToCloudFormation(properties.publicAccessBlockConfiguration),ReplicationConfiguration:convertCfnBucketReplicationConfigurationPropertyToCloudFormation(properties.replicationConfiguration),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags),VersioningConfiguration:convertCfnBucketVersioningConfigurationPropertyToCloudFormation(properties.versioningConfiguration),WebsiteConfiguration:convertCfnBucketWebsiteConfigurationPropertyToCloudFormation(properties.websiteConfiguration)}):properties}function CfnBucketPropsFromCloudFormation(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("abacStatus","AbacStatus",properties.AbacStatus!=null?cfn_parse().FromCloudFormation.getString(properties.AbacStatus):void 0),ret.addPropertyResult("accelerateConfiguration","AccelerateConfiguration",properties.AccelerateConfiguration!=null?CfnBucketAccelerateConfigurationPropertyFromCloudFormation(properties.AccelerateConfiguration):void 0),ret.addPropertyResult("accessControl","AccessControl",properties.AccessControl!=null?cfn_parse().FromCloudFormation.getString(properties.AccessControl):void 0),ret.addPropertyResult("analyticsConfigurations","AnalyticsConfigurations",properties.AnalyticsConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketAnalyticsConfigurationPropertyFromCloudFormation)(properties.AnalyticsConfigurations):void 0),ret.addPropertyResult("bucketEncryption","BucketEncryption",properties.BucketEncryption!=null?CfnBucketBucketEncryptionPropertyFromCloudFormation(properties.BucketEncryption):void 0),ret.addPropertyResult("bucketName","BucketName",properties.BucketName!=null?cfn_parse().FromCloudFormation.getString(properties.BucketName):void 0),ret.addPropertyResult("bucketNamePrefix","BucketNamePrefix",properties.BucketNamePrefix!=null?cfn_parse().FromCloudFormation.getString(properties.BucketNamePrefix):void 0),ret.addPropertyResult("bucketNamespace","BucketNamespace",properties.BucketNamespace!=null?cfn_parse().FromCloudFormation.getString(properties.BucketNamespace):void 0),ret.addPropertyResult("corsConfiguration","CorsConfiguration",properties.CorsConfiguration!=null?CfnBucketCorsConfigurationPropertyFromCloudFormation(properties.CorsConfiguration):void 0),ret.addPropertyResult("intelligentTieringConfigurations","IntelligentTieringConfigurations",properties.IntelligentTieringConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketIntelligentTieringConfigurationPropertyFromCloudFormation)(properties.IntelligentTieringConfigurations):void 0),ret.addPropertyResult("inventoryConfigurations","InventoryConfigurations",properties.InventoryConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketInventoryConfigurationPropertyFromCloudFormation)(properties.InventoryConfigurations):void 0),ret.addPropertyResult("lifecycleConfiguration","LifecycleConfiguration",properties.LifecycleConfiguration!=null?CfnBucketLifecycleConfigurationPropertyFromCloudFormation(properties.LifecycleConfiguration):void 0),ret.addPropertyResult("loggingConfiguration","LoggingConfiguration",properties.LoggingConfiguration!=null?CfnBucketLoggingConfigurationPropertyFromCloudFormation(properties.LoggingConfiguration):void 0),ret.addPropertyResult("metadataConfiguration","MetadataConfiguration",properties.MetadataConfiguration!=null?CfnBucketMetadataConfigurationPropertyFromCloudFormation(properties.MetadataConfiguration):void 0),ret.addPropertyResult("metadataTableConfiguration","MetadataTableConfiguration",properties.MetadataTableConfiguration!=null?CfnBucketMetadataTableConfigurationPropertyFromCloudFormation(properties.MetadataTableConfiguration):void 0),ret.addPropertyResult("metricsConfigurations","MetricsConfigurations",properties.MetricsConfigurations!=null?cfn_parse().FromCloudFormation.getArray(CfnBucketMetricsConfigurationPropertyFromCloudFormation)(properties.MetricsConfigurations):void 0),ret.addPropertyResult("notificationConfiguration","NotificationConfiguration",properties.NotificationConfiguration!=null?CfnBucketNotificationConfigurationPropertyFromCloudFormation(properties.NotificationConfiguration):void 0),ret.addPropertyResult("objectLockConfiguration","ObjectLockConfiguration",properties.ObjectLockConfiguration!=null?CfnBucketObjectLockConfigurationPropertyFromCloudFormation(properties.ObjectLockConfiguration):void 0),ret.addPropertyResult("objectLockEnabled","ObjectLockEnabled",properties.ObjectLockEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.ObjectLockEnabled):void 0),ret.addPropertyResult("ownershipControls","OwnershipControls",properties.OwnershipControls!=null?CfnBucketOwnershipControlsPropertyFromCloudFormation(properties.OwnershipControls):void 0),ret.addPropertyResult("publicAccessBlockConfiguration","PublicAccessBlockConfiguration",properties.PublicAccessBlockConfiguration!=null?CfnBucketPublicAccessBlockConfigurationPropertyFromCloudFormation(properties.PublicAccessBlockConfiguration):void 0),ret.addPropertyResult("replicationConfiguration","ReplicationConfiguration",properties.ReplicationConfiguration!=null?CfnBucketReplicationConfigurationPropertyFromCloudFormation(properties.ReplicationConfiguration):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addPropertyResult("versioningConfiguration","VersioningConfiguration",properties.VersioningConfiguration!=null?CfnBucketVersioningConfigurationPropertyFromCloudFormation(properties.VersioningConfiguration):void 0),ret.addPropertyResult("websiteConfiguration","WebsiteConfiguration",properties.WebsiteConfiguration!=null?CfnBucketWebsiteConfigurationPropertyFromCloudFormation(properties.WebsiteConfiguration):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnBucketPolicy extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnBucketPolicy",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::BucketPolicy";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnBucketPolicyPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnBucketPolicy(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}static isCfnBucketPolicy(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnBucketPolicy.CFN_RESOURCE_TYPE_NAME}_bucket;_policyDocument;cfnPropertyNames={bucket:"Bucket",policyDocument:"PolicyDocument"};constructor(scope,id,props){super(scope,id,{type:CfnBucketPolicy.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnBucketPolicyProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnBucketPolicy),error}cdk().requireProperty(props,"bucket",this),cdk().requireProperty(props,"policyDocument",this),this._bucket=cdk().getRefProperty(props.bucket?.bucketRef,"bucketName")??cdk().ensureStringOrUndefined(props.bucket,"bucket","s3.IBucketRef | string"),this._policyDocument=props.policyDocument}get bucketPolicyRef(){return{bucket:this.ref}}get bucket(){return this._bucket}set bucket(value){cdk().traceProperty(this.node,"Bucket"),this._bucket=value}get policyDocument(){return this._policyDocument}set policyDocument(value){cdk().traceProperty(this.node,"PolicyDocument"),this._policyDocument=value}get cfnProperties(){return{bucket:this._bucket,policyDocument:this._policyDocument}}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",CfnBucketPolicy.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnBucketPolicyPropsToCloudFormation(props)}}exports.CfnBucketPolicy=CfnBucketPolicy;function CfnBucketPolicyPropsValidator(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("bucket",cdk().requiredValidator)(properties.bucket)),errors.collect(cdk().propertyValidator("bucket",cdk().validateString)(properties.bucket)),errors.collect(cdk().propertyValidator("policyDocument",cdk().requiredValidator)(properties.policyDocument)),errors.collect(cdk().propertyValidator("policyDocument",cdk().validateObject)(properties.policyDocument)),errors.wrap('supplied properties not correct for "CfnBucketPolicyProps"')}function convertCfnBucketPolicyPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnBucketPolicyPropsValidator(properties).assertSuccess(),{Bucket:cdk().stringToCloudFormation(properties.bucket),PolicyDocument:cdk().objectToCloudFormation(properties.policyDocument)}):properties}function CfnBucketPolicyPropsFromCloudFormation(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("bucket","Bucket",properties.Bucket!=null?cfn_parse().FromCloudFormation.getString(properties.Bucket):void 0),ret.addPropertyResult("policyDocument","PolicyDocument",properties.PolicyDocument!=null?cfn_parse().FromCloudFormation.getAny(properties.PolicyDocument):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnMultiRegionAccessPoint extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnMultiRegionAccessPoint",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::MultiRegionAccessPoint";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnMultiRegionAccessPointPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnMultiRegionAccessPoint(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}static isCfnMultiRegionAccessPoint(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnMultiRegionAccessPoint.CFN_RESOURCE_TYPE_NAME}_name;_publicAccessBlockConfiguration;_regions;cfnPropertyNames={name:"Name",publicAccessBlockConfiguration:"PublicAccessBlockConfiguration",regions:"Regions"};constructor(scope,id,props){super(scope,id,{type:CfnMultiRegionAccessPoint.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnMultiRegionAccessPointProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnMultiRegionAccessPoint),error}cdk().requireProperty(props,"regions",this),this._name=props.name,this._publicAccessBlockConfiguration=props.publicAccessBlockConfiguration,this._regions=props.regions}get multiRegionAccessPointRef(){return{multiRegionAccessPointName:this.ref}}get name(){return this._name}set name(value){cdk().traceProperty(this.node,"Name"),this._name=value}get publicAccessBlockConfiguration(){return this._publicAccessBlockConfiguration}set publicAccessBlockConfiguration(value){cdk().traceProperty(this.node,"PublicAccessBlockConfiguration"),this._publicAccessBlockConfiguration=value}get regions(){return this._regions}set regions(value){cdk().traceProperty(this.node,"Regions"),this._regions=value}get attrAlias(){return cdk().Token.asString(this.getAtt("Alias",cdk().ResolutionTypeHint.STRING))}get attrCreatedAt(){return cdk().Token.asString(this.getAtt("CreatedAt",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{name:this._name,publicAccessBlockConfiguration:this._publicAccessBlockConfiguration,regions:this._regions}}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",CfnMultiRegionAccessPoint.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnMultiRegionAccessPointPropsToCloudFormation(props)}}exports.CfnMultiRegionAccessPoint=CfnMultiRegionAccessPoint;function CfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyValidator(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("blockPublicAcls",cdk().validateBoolean)(properties.blockPublicAcls)),errors.collect(cdk().propertyValidator("blockPublicPolicy",cdk().validateBoolean)(properties.blockPublicPolicy)),errors.collect(cdk().propertyValidator("ignorePublicAcls",cdk().validateBoolean)(properties.ignorePublicAcls)),errors.collect(cdk().propertyValidator("restrictPublicBuckets",cdk().validateBoolean)(properties.restrictPublicBuckets)),errors.wrap('supplied properties not correct for "PublicAccessBlockConfigurationProperty"')}function convertCfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyValidator(properties).assertSuccess(),{BlockPublicAcls:cdk().booleanToCloudFormation(properties.blockPublicAcls),BlockPublicPolicy:cdk().booleanToCloudFormation(properties.blockPublicPolicy),IgnorePublicAcls:cdk().booleanToCloudFormation(properties.ignorePublicAcls),RestrictPublicBuckets:cdk().booleanToCloudFormation(properties.restrictPublicBuckets)}):properties}function CfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyFromCloudFormation(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("blockPublicAcls","BlockPublicAcls",properties.BlockPublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicAcls):void 0),ret.addPropertyResult("blockPublicPolicy","BlockPublicPolicy",properties.BlockPublicPolicy!=null?cfn_parse().FromCloudFormation.getBoolean(properties.BlockPublicPolicy):void 0),ret.addPropertyResult("ignorePublicAcls","IgnorePublicAcls",properties.IgnorePublicAcls!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IgnorePublicAcls):void 0),ret.addPropertyResult("restrictPublicBuckets","RestrictPublicBuckets",properties.RestrictPublicBuckets!=null?cfn_parse().FromCloudFormation.getBoolean(properties.RestrictPublicBuckets):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnMultiRegionAccessPointRegionPropertyValidator(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("bucket",cdk().requiredValidator)(properties.bucket)),errors.collect(cdk().propertyValidator("bucket",cdk().validateString)(properties.bucket)),errors.collect(cdk().propertyValidator("bucketAccountId",cdk().validateString)(properties.bucketAccountId)),errors.wrap('supplied properties not correct for "RegionProperty"')}function convertCfnMultiRegionAccessPointRegionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnMultiRegionAccessPointRegionPropertyValidator(properties).assertSuccess(),{Bucket:cdk().stringToCloudFormation(properties.bucket),BucketAccountId:cdk().stringToCloudFormation(properties.bucketAccountId)}):properties}function CfnMultiRegionAccessPointRegionPropertyFromCloudFormation(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("bucket","Bucket",properties.Bucket!=null?cfn_parse().FromCloudFormation.getString(properties.Bucket):void 0),ret.addPropertyResult("bucketAccountId","BucketAccountId",properties.BucketAccountId!=null?cfn_parse().FromCloudFormation.getString(properties.BucketAccountId):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnMultiRegionAccessPointPropsValidator(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().validateString)(properties.name)),errors.collect(cdk().propertyValidator("publicAccessBlockConfiguration",CfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyValidator)(properties.publicAccessBlockConfiguration)),errors.collect(cdk().propertyValidator("regions",cdk().requiredValidator)(properties.regions)),errors.collect(cdk().propertyValidator("regions",cdk().listValidator(CfnMultiRegionAccessPointRegionPropertyValidator))(properties.regions)),errors.wrap('supplied properties not correct for "CfnMultiRegionAccessPointProps"')}function convertCfnMultiRegionAccessPointPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnMultiRegionAccessPointPropsValidator(properties).assertSuccess(),{Name:cdk().stringToCloudFormation(properties.name),PublicAccessBlockConfiguration:convertCfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyToCloudFormation(properties.publicAccessBlockConfiguration),Regions:cdk().listMapper(convertCfnMultiRegionAccessPointRegionPropertyToCloudFormation)(properties.regions)}):properties}function CfnMultiRegionAccessPointPropsFromCloudFormation(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("publicAccessBlockConfiguration","PublicAccessBlockConfiguration",properties.PublicAccessBlockConfiguration!=null?CfnMultiRegionAccessPointPublicAccessBlockConfigurationPropertyFromCloudFormation(properties.PublicAccessBlockConfiguration):void 0),ret.addPropertyResult("regions","Regions",properties.Regions!=null?cfn_parse().FromCloudFormation.getArray(CfnMultiRegionAccessPointRegionPropertyFromCloudFormation)(properties.Regions):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnMultiRegionAccessPointPolicy extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnMultiRegionAccessPointPolicy",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::MultiRegionAccessPointPolicy";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnMultiRegionAccessPointPolicyPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnMultiRegionAccessPointPolicy(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}static isCfnMultiRegionAccessPointPolicy(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnMultiRegionAccessPointPolicy.CFN_RESOURCE_TYPE_NAME}_mrapName;_policy;cfnPropertyNames={mrapName:"MrapName",policy:"Policy"};constructor(scope,id,props){super(scope,id,{type:CfnMultiRegionAccessPointPolicy.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnMultiRegionAccessPointPolicyProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnMultiRegionAccessPointPolicy),error}cdk().requireProperty(props,"mrapName",this),cdk().requireProperty(props,"policy",this),this._mrapName=props.mrapName,this._policy=props.policy}get multiRegionAccessPointPolicyRef(){return{mrapName:this.ref}}get mrapName(){return this._mrapName}set mrapName(value){cdk().traceProperty(this.node,"MrapName"),this._mrapName=value}get policy(){return this._policy}set policy(value){cdk().traceProperty(this.node,"Policy"),this._policy=value}get attrPolicyStatus(){return this.getAtt("PolicyStatus")}get attrPolicyStatusIsPublic(){return cdk().Token.asString(this.getAtt("PolicyStatus.IsPublic",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{mrapName:this._mrapName,policy:this._policy}}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",CfnMultiRegionAccessPointPolicy.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnMultiRegionAccessPointPolicyPropsToCloudFormation(props)}}exports.CfnMultiRegionAccessPointPolicy=CfnMultiRegionAccessPointPolicy;function CfnMultiRegionAccessPointPolicyPolicyStatusPropertyValidator(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("isPublic",cdk().requiredValidator)(properties.isPublic)),errors.collect(cdk().propertyValidator("isPublic",cdk().validateString)(properties.isPublic)),errors.wrap('supplied properties not correct for "PolicyStatusProperty"')}function convertCfnMultiRegionAccessPointPolicyPolicyStatusPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnMultiRegionAccessPointPolicyPolicyStatusPropertyValidator(properties).assertSuccess(),{IsPublic:cdk().stringToCloudFormation(properties.isPublic)}):properties}function CfnMultiRegionAccessPointPolicyPolicyStatusPropertyFromCloudFormation(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("isPublic","IsPublic",properties.IsPublic!=null?cfn_parse().FromCloudFormation.getString(properties.IsPublic):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnMultiRegionAccessPointPolicyPropsValidator(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("mrapName",cdk().requiredValidator)(properties.mrapName)),errors.collect(cdk().propertyValidator("mrapName",cdk().validateString)(properties.mrapName)),errors.collect(cdk().propertyValidator("policy",cdk().requiredValidator)(properties.policy)),errors.collect(cdk().propertyValidator("policy",cdk().validateObject)(properties.policy)),errors.wrap('supplied properties not correct for "CfnMultiRegionAccessPointPolicyProps"')}function convertCfnMultiRegionAccessPointPolicyPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnMultiRegionAccessPointPolicyPropsValidator(properties).assertSuccess(),{MrapName:cdk().stringToCloudFormation(properties.mrapName),Policy:cdk().objectToCloudFormation(properties.policy)}):properties}function CfnMultiRegionAccessPointPolicyPropsFromCloudFormation(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("mrapName","MrapName",properties.MrapName!=null?cfn_parse().FromCloudFormation.getString(properties.MrapName):void 0),ret.addPropertyResult("policy","Policy",properties.Policy!=null?cfn_parse().FromCloudFormation.getAny(properties.Policy):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnStorageLens extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnStorageLens",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::StorageLens";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnStorageLensPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnStorageLens(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}static isCfnStorageLens(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnStorageLens.CFN_RESOURCE_TYPE_NAME}_storageLensConfiguration;tags;_tagsRaw;cfnPropertyNames={storageLensConfiguration:"StorageLensConfiguration",tags:"Tags"};constructor(scope,id,props){super(scope,id,{type:CfnStorageLens.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnStorageLensProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnStorageLens),error}cdk().requireProperty(props,"storageLensConfiguration",this),this._storageLensConfiguration=props.storageLensConfiguration,this.tags=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::StorageLens",props.tags,{tagPropertyName:"tags"}),this._tagsRaw=props.tags}get storageLensRef(){return{storageLensId:this.ref}}get storageLensConfiguration(){return this._storageLensConfiguration}set storageLensConfiguration(value){cdk().traceProperty(this.node,"StorageLensConfiguration"),this._storageLensConfiguration=value}get tagsRaw(){return this._tagsRaw}set tagsRaw(value){cdk().traceProperty(this.node,"Tags"),this._tagsRaw=value}get attrStorageLensConfigurationStorageLensArn(){return cdk().Token.asString(this.getAtt("StorageLensConfiguration.StorageLensArn",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{storageLensConfiguration:this._storageLensConfiguration,tags:this.tags.renderTags()}}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",CfnStorageLens.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnStorageLensPropsToCloudFormation(props)}}exports.CfnStorageLens=CfnStorageLens;function CfnStorageLensAdvancedDataProtectionMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "AdvancedDataProtectionMetricsProperty"')}function convertCfnStorageLensAdvancedDataProtectionMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensAdvancedDataProtectionMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensAdvancedDataProtectionMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensActivityMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "ActivityMetricsProperty"')}function convertCfnStorageLensActivityMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensActivityMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensActivityMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensSelectionCriteriaPropertyValidator(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("delimiter",cdk().validateString)(properties.delimiter)),errors.collect(cdk().propertyValidator("maxDepth",cdk().validateNumber)(properties.maxDepth)),errors.collect(cdk().propertyValidator("minStorageBytesPercentage",cdk().validateNumber)(properties.minStorageBytesPercentage)),errors.wrap('supplied properties not correct for "SelectionCriteriaProperty"')}function convertCfnStorageLensSelectionCriteriaPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensSelectionCriteriaPropertyValidator(properties).assertSuccess(),{Delimiter:cdk().stringToCloudFormation(properties.delimiter),MaxDepth:cdk().numberToCloudFormation(properties.maxDepth),MinStorageBytesPercentage:cdk().numberToCloudFormation(properties.minStorageBytesPercentage)}):properties}function CfnStorageLensSelectionCriteriaPropertyFromCloudFormation(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("delimiter","Delimiter",properties.Delimiter!=null?cfn_parse().FromCloudFormation.getString(properties.Delimiter):void 0),ret.addPropertyResult("maxDepth","MaxDepth",properties.MaxDepth!=null?cfn_parse().FromCloudFormation.getNumber(properties.MaxDepth):void 0),ret.addPropertyResult("minStorageBytesPercentage","MinStorageBytesPercentage",properties.MinStorageBytesPercentage!=null?cfn_parse().FromCloudFormation.getNumber(properties.MinStorageBytesPercentage):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensPrefixLevelStorageMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.collect(cdk().propertyValidator("selectionCriteria",CfnStorageLensSelectionCriteriaPropertyValidator)(properties.selectionCriteria)),errors.wrap('supplied properties not correct for "PrefixLevelStorageMetricsProperty"')}function convertCfnStorageLensPrefixLevelStorageMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensPrefixLevelStorageMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled),SelectionCriteria:convertCfnStorageLensSelectionCriteriaPropertyToCloudFormation(properties.selectionCriteria)}):properties}function CfnStorageLensPrefixLevelStorageMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addPropertyResult("selectionCriteria","SelectionCriteria",properties.SelectionCriteria!=null?CfnStorageLensSelectionCriteriaPropertyFromCloudFormation(properties.SelectionCriteria):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensPrefixLevelPropertyValidator(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("storageMetrics",cdk().requiredValidator)(properties.storageMetrics)),errors.collect(cdk().propertyValidator("storageMetrics",CfnStorageLensPrefixLevelStorageMetricsPropertyValidator)(properties.storageMetrics)),errors.wrap('supplied properties not correct for "PrefixLevelProperty"')}function convertCfnStorageLensPrefixLevelPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensPrefixLevelPropertyValidator(properties).assertSuccess(),{StorageMetrics:convertCfnStorageLensPrefixLevelStorageMetricsPropertyToCloudFormation(properties.storageMetrics)}):properties}function CfnStorageLensPrefixLevelPropertyFromCloudFormation(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("storageMetrics","StorageMetrics",properties.StorageMetrics!=null?CfnStorageLensPrefixLevelStorageMetricsPropertyFromCloudFormation(properties.StorageMetrics):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensAdvancedCostOptimizationMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "AdvancedCostOptimizationMetricsProperty"')}function convertCfnStorageLensAdvancedCostOptimizationMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensAdvancedCostOptimizationMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensAdvancedCostOptimizationMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensDetailedStatusCodesMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "DetailedStatusCodesMetricsProperty"')}function convertCfnStorageLensDetailedStatusCodesMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensDetailedStatusCodesMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensDetailedStatusCodesMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensAdvancedPerformanceMetricsPropertyValidator(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("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "AdvancedPerformanceMetricsProperty"')}function convertCfnStorageLensAdvancedPerformanceMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensAdvancedPerformanceMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensAdvancedPerformanceMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensBucketLevelPropertyValidator(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("activityMetrics",CfnStorageLensActivityMetricsPropertyValidator)(properties.activityMetrics)),errors.collect(cdk().propertyValidator("advancedCostOptimizationMetrics",CfnStorageLensAdvancedCostOptimizationMetricsPropertyValidator)(properties.advancedCostOptimizationMetrics)),errors.collect(cdk().propertyValidator("advancedDataProtectionMetrics",CfnStorageLensAdvancedDataProtectionMetricsPropertyValidator)(properties.advancedDataProtectionMetrics)),errors.collect(cdk().propertyValidator("advancedPerformanceMetrics",CfnStorageLensAdvancedPerformanceMetricsPropertyValidator)(properties.advancedPerformanceMetrics)),errors.collect(cdk().propertyValidator("detailedStatusCodesMetrics",CfnStorageLensDetailedStatusCodesMetricsPropertyValidator)(properties.detailedStatusCodesMetrics)),errors.collect(cdk().propertyValidator("prefixLevel",CfnStorageLensPrefixLevelPropertyValidator)(properties.prefixLevel)),errors.wrap('supplied properties not correct for "BucketLevelProperty"')}function convertCfnStorageLensBucketLevelPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensBucketLevelPropertyValidator(properties).assertSuccess(),{ActivityMetrics:convertCfnStorageLensActivityMetricsPropertyToCloudFormation(properties.activityMetrics),AdvancedCostOptimizationMetrics:convertCfnStorageLensAdvancedCostOptimizationMetricsPropertyToCloudFormation(properties.advancedCostOptimizationMetrics),AdvancedDataProtectionMetrics:convertCfnStorageLensAdvancedDataProtectionMetricsPropertyToCloudFormation(properties.advancedDataProtectionMetrics),AdvancedPerformanceMetrics:convertCfnStorageLensAdvancedPerformanceMetricsPropertyToCloudFormation(properties.advancedPerformanceMetrics),DetailedStatusCodesMetrics:convertCfnStorageLensDetailedStatusCodesMetricsPropertyToCloudFormation(properties.detailedStatusCodesMetrics),PrefixLevel:convertCfnStorageLensPrefixLevelPropertyToCloudFormation(properties.prefixLevel)}):properties}function CfnStorageLensBucketLevelPropertyFromCloudFormation(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("activityMetrics","ActivityMetrics",properties.ActivityMetrics!=null?CfnStorageLensActivityMetricsPropertyFromCloudFormation(properties.ActivityMetrics):void 0),ret.addPropertyResult("advancedCostOptimizationMetrics","AdvancedCostOptimizationMetrics",properties.AdvancedCostOptimizationMetrics!=null?CfnStorageLensAdvancedCostOptimizationMetricsPropertyFromCloudFormation(properties.AdvancedCostOptimizationMetrics):void 0),ret.addPropertyResult("advancedDataProtectionMetrics","AdvancedDataProtectionMetrics",properties.AdvancedDataProtectionMetrics!=null?CfnStorageLensAdvancedDataProtectionMetricsPropertyFromCloudFormation(properties.AdvancedDataProtectionMetrics):void 0),ret.addPropertyResult("advancedPerformanceMetrics","AdvancedPerformanceMetrics",properties.AdvancedPerformanceMetrics!=null?CfnStorageLensAdvancedPerformanceMetricsPropertyFromCloudFormation(properties.AdvancedPerformanceMetrics):void 0),ret.addPropertyResult("detailedStatusCodesMetrics","DetailedStatusCodesMetrics",properties.DetailedStatusCodesMetrics!=null?CfnStorageLensDetailedStatusCodesMetricsPropertyFromCloudFormation(properties.DetailedStatusCodesMetrics):void 0),ret.addPropertyResult("prefixLevel","PrefixLevel",properties.PrefixLevel!=null?CfnStorageLensPrefixLevelPropertyFromCloudFormation(properties.PrefixLevel):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensStorageLensGroupSelectionCriteriaPropertyValidator(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("exclude",cdk().listValidator(cdk().validateString))(properties.exclude)),errors.collect(cdk().propertyValidator("include",cdk().listValidator(cdk().validateString))(properties.include)),errors.wrap('supplied properties not correct for "StorageLensGroupSelectionCriteriaProperty"')}function convertCfnStorageLensStorageLensGroupSelectionCriteriaPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensStorageLensGroupSelectionCriteriaPropertyValidator(properties).assertSuccess(),{Exclude:cdk().listMapper(cdk().stringToCloudFormation)(properties.exclude),Include:cdk().listMapper(cdk().stringToCloudFormation)(properties.include)}):properties}function CfnStorageLensStorageLensGroupSelectionCriteriaPropertyFromCloudFormation(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("exclude","Exclude",properties.Exclude!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.Exclude):void 0),ret.addPropertyResult("include","Include",properties.Include!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.Include):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensStorageLensGroupLevelPropertyValidator(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("storageLensGroupSelectionCriteria",CfnStorageLensStorageLensGroupSelectionCriteriaPropertyValidator)(properties.storageLensGroupSelectionCriteria)),errors.wrap('supplied properties not correct for "StorageLensGroupLevelProperty"')}function convertCfnStorageLensStorageLensGroupLevelPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensStorageLensGroupLevelPropertyValidator(properties).assertSuccess(),{StorageLensGroupSelectionCriteria:convertCfnStorageLensStorageLensGroupSelectionCriteriaPropertyToCloudFormation(properties.storageLensGroupSelectionCriteria)}):properties}function CfnStorageLensStorageLensGroupLevelPropertyFromCloudFormation(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("storageLensGroupSelectionCriteria","StorageLensGroupSelectionCriteria",properties.StorageLensGroupSelectionCriteria!=null?CfnStorageLensStorageLensGroupSelectionCriteriaPropertyFromCloudFormation(properties.StorageLensGroupSelectionCriteria):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensAccountLevelPropertyValidator(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("activityMetrics",CfnStorageLensActivityMetricsPropertyValidator)(properties.activityMetrics)),errors.collect(cdk().propertyValidator("advancedCostOptimizationMetrics",CfnStorageLensAdvancedCostOptimizationMetricsPropertyValidator)(properties.advancedCostOptimizationMetrics)),errors.collect(cdk().propertyValidator("advancedDataProtectionMetrics",CfnStorageLensAdvancedDataProtectionMetricsPropertyValidator)(properties.advancedDataProtectionMetrics)),errors.collect(cdk().propertyValidator("advancedPerformanceMetrics",CfnStorageLensAdvancedPerformanceMetricsPropertyValidator)(properties.advancedPerformanceMetrics)),errors.collect(cdk().propertyValidator("bucketLevel",cdk().requiredValidator)(properties.bucketLevel)),errors.collect(cdk().propertyValidator("bucketLevel",CfnStorageLensBucketLevelPropertyValidator)(properties.bucketLevel)),errors.collect(cdk().propertyValidator("detailedStatusCodesMetrics",CfnStorageLensDetailedStatusCodesMetricsPropertyValidator)(properties.detailedStatusCodesMetrics)),errors.collect(cdk().propertyValidator("storageLensGroupLevel",CfnStorageLensStorageLensGroupLevelPropertyValidator)(properties.storageLensGroupLevel)),errors.wrap('supplied properties not correct for "AccountLevelProperty"')}function convertCfnStorageLensAccountLevelPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensAccountLevelPropertyValidator(properties).assertSuccess(),{ActivityMetrics:convertCfnStorageLensActivityMetricsPropertyToCloudFormation(properties.activityMetrics),AdvancedCostOptimizationMetrics:convertCfnStorageLensAdvancedCostOptimizationMetricsPropertyToCloudFormation(properties.advancedCostOptimizationMetrics),AdvancedDataProtectionMetrics:convertCfnStorageLensAdvancedDataProtectionMetricsPropertyToCloudFormation(properties.advancedDataProtectionMetrics),AdvancedPerformanceMetrics:convertCfnStorageLensAdvancedPerformanceMetricsPropertyToCloudFormation(properties.advancedPerformanceMetrics),BucketLevel:convertCfnStorageLensBucketLevelPropertyToCloudFormation(properties.bucketLevel),DetailedStatusCodesMetrics:convertCfnStorageLensDetailedStatusCodesMetricsPropertyToCloudFormation(properties.detailedStatusCodesMetrics),StorageLensGroupLevel:convertCfnStorageLensStorageLensGroupLevelPropertyToCloudFormation(properties.storageLensGroupLevel)}):properties}function CfnStorageLensAccountLevelPropertyFromCloudFormation(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("activityMetrics","ActivityMetrics",properties.ActivityMetrics!=null?CfnStorageLensActivityMetricsPropertyFromCloudFormation(properties.ActivityMetrics):void 0),ret.addPropertyResult("advancedCostOptimizationMetrics","AdvancedCostOptimizationMetrics",properties.AdvancedCostOptimizationMetrics!=null?CfnStorageLensAdvancedCostOptimizationMetricsPropertyFromCloudFormation(properties.AdvancedCostOptimizationMetrics):void 0),ret.addPropertyResult("advancedDataProtectionMetrics","AdvancedDataProtectionMetrics",properties.AdvancedDataProtectionMetrics!=null?CfnStorageLensAdvancedDataProtectionMetricsPropertyFromCloudFormation(properties.AdvancedDataProtectionMetrics):void 0),ret.addPropertyResult("advancedPerformanceMetrics","AdvancedPerformanceMetrics",properties.AdvancedPerformanceMetrics!=null?CfnStorageLensAdvancedPerformanceMetricsPropertyFromCloudFormation(properties.AdvancedPerformanceMetrics):void 0),ret.addPropertyResult("bucketLevel","BucketLevel",properties.BucketLevel!=null?CfnStorageLensBucketLevelPropertyFromCloudFormation(properties.BucketLevel):void 0),ret.addPropertyResult("detailedStatusCodesMetrics","DetailedStatusCodesMetrics",properties.DetailedStatusCodesMetrics!=null?CfnStorageLensDetailedStatusCodesMetricsPropertyFromCloudFormation(properties.DetailedStatusCodesMetrics):void 0),ret.addPropertyResult("storageLensGroupLevel","StorageLensGroupLevel",properties.StorageLensGroupLevel!=null?CfnStorageLensStorageLensGroupLevelPropertyFromCloudFormation(properties.StorageLensGroupLevel):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensBucketsAndRegionsPropertyValidator(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("buckets",cdk().listValidator(cdk().validateString))(properties.buckets)),errors.collect(cdk().propertyValidator("regions",cdk().listValidator(cdk().validateString))(properties.regions)),errors.wrap('supplied properties not correct for "BucketsAndRegionsProperty"')}function convertCfnStorageLensBucketsAndRegionsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensBucketsAndRegionsPropertyValidator(properties).assertSuccess(),{Buckets:cdk().listMapper(cdk().stringToCloudFormation)(properties.buckets),Regions:cdk().listMapper(cdk().stringToCloudFormation)(properties.regions)}):properties}function CfnStorageLensBucketsAndRegionsPropertyFromCloudFormation(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("buckets","Buckets",properties.Buckets!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.Buckets):void 0),ret.addPropertyResult("regions","Regions",properties.Regions!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.Regions):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensAwsOrgPropertyValidator(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("arn",cdk().requiredValidator)(properties.arn)),errors.collect(cdk().propertyValidator("arn",cdk().validateString)(properties.arn)),errors.wrap('supplied properties not correct for "AwsOrgProperty"')}function convertCfnStorageLensAwsOrgPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensAwsOrgPropertyValidator(properties).assertSuccess(),{Arn:cdk().stringToCloudFormation(properties.arn)}):properties}function CfnStorageLensAwsOrgPropertyFromCloudFormation(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("arn","Arn",properties.Arn!=null?cfn_parse().FromCloudFormation.getString(properties.Arn):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensSSEKMSPropertyValidator(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("keyId",cdk().requiredValidator)(properties.keyId)),errors.collect(cdk().propertyValidator("keyId",cdk().validateString)(properties.keyId)),errors.wrap('supplied properties not correct for "SSEKMSProperty"')}function convertCfnStorageLensSSEKMSPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensSSEKMSPropertyValidator(properties).assertSuccess(),{KeyId:cdk().stringToCloudFormation(properties.keyId)}):properties}function CfnStorageLensSSEKMSPropertyFromCloudFormation(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("keyId","KeyId",properties.KeyId!=null?cfn_parse().FromCloudFormation.getString(properties.KeyId):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensEncryptionPropertyValidator(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("ssekms",CfnStorageLensSSEKMSPropertyValidator)(properties.ssekms)),errors.collect(cdk().propertyValidator("sses3",cdk().validateObject)(properties.sses3)),errors.wrap('supplied properties not correct for "EncryptionProperty"')}function convertCfnStorageLensEncryptionPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensEncryptionPropertyValidator(properties).assertSuccess(),{SSEKMS:convertCfnStorageLensSSEKMSPropertyToCloudFormation(properties.ssekms),SSES3:cdk().objectToCloudFormation(properties.sses3)}):properties}function CfnStorageLensEncryptionPropertyFromCloudFormation(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("ssekms","SSEKMS",properties.SSEKMS!=null?CfnStorageLensSSEKMSPropertyFromCloudFormation(properties.SSEKMS):void 0),ret.addPropertyResult("sses3","SSES3",properties.SSES3!=null?cfn_parse().FromCloudFormation.getAny(properties.SSES3):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensS3BucketDestinationPropertyValidator(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("accountId",cdk().requiredValidator)(properties.accountId)),errors.collect(cdk().propertyValidator("accountId",cdk().validateString)(properties.accountId)),errors.collect(cdk().propertyValidator("arn",cdk().requiredValidator)(properties.arn)),errors.collect(cdk().propertyValidator("arn",cdk().validateString)(properties.arn)),errors.collect(cdk().propertyValidator("encryption",CfnStorageLensEncryptionPropertyValidator)(properties.encryption)),errors.collect(cdk().propertyValidator("format",cdk().requiredValidator)(properties.format)),errors.collect(cdk().propertyValidator("format",cdk().validateString)(properties.format)),errors.collect(cdk().propertyValidator("outputSchemaVersion",cdk().requiredValidator)(properties.outputSchemaVersion)),errors.collect(cdk().propertyValidator("outputSchemaVersion",cdk().validateString)(properties.outputSchemaVersion)),errors.collect(cdk().propertyValidator("prefix",cdk().validateString)(properties.prefix)),errors.wrap('supplied properties not correct for "S3BucketDestinationProperty"')}function convertCfnStorageLensS3BucketDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensS3BucketDestinationPropertyValidator(properties).assertSuccess(),{AccountId:cdk().stringToCloudFormation(properties.accountId),Arn:cdk().stringToCloudFormation(properties.arn),Encryption:convertCfnStorageLensEncryptionPropertyToCloudFormation(properties.encryption),Format:cdk().stringToCloudFormation(properties.format),OutputSchemaVersion:cdk().stringToCloudFormation(properties.outputSchemaVersion),Prefix:cdk().stringToCloudFormation(properties.prefix)}):properties}function CfnStorageLensS3BucketDestinationPropertyFromCloudFormation(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("accountId","AccountId",properties.AccountId!=null?cfn_parse().FromCloudFormation.getString(properties.AccountId):void 0),ret.addPropertyResult("arn","Arn",properties.Arn!=null?cfn_parse().FromCloudFormation.getString(properties.Arn):void 0),ret.addPropertyResult("encryption","Encryption",properties.Encryption!=null?CfnStorageLensEncryptionPropertyFromCloudFormation(properties.Encryption):void 0),ret.addPropertyResult("format","Format",properties.Format!=null?cfn_parse().FromCloudFormation.getString(properties.Format):void 0),ret.addPropertyResult("outputSchemaVersion","OutputSchemaVersion",properties.OutputSchemaVersion!=null?cfn_parse().FromCloudFormation.getString(properties.OutputSchemaVersion):void 0),ret.addPropertyResult("prefix","Prefix",properties.Prefix!=null?cfn_parse().FromCloudFormation.getString(properties.Prefix):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensCloudWatchMetricsPropertyValidator(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("isEnabled",cdk().requiredValidator)(properties.isEnabled)),errors.collect(cdk().propertyValidator("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "CloudWatchMetricsProperty"')}function convertCfnStorageLensCloudWatchMetricsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensCloudWatchMetricsPropertyValidator(properties).assertSuccess(),{IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensCloudWatchMetricsPropertyFromCloudFormation(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("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensStorageLensTableDestinationPropertyValidator(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("encryption",CfnStorageLensEncryptionPropertyValidator)(properties.encryption)),errors.collect(cdk().propertyValidator("isEnabled",cdk().requiredValidator)(properties.isEnabled)),errors.collect(cdk().propertyValidator("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.wrap('supplied properties not correct for "StorageLensTableDestinationProperty"')}function convertCfnStorageLensStorageLensTableDestinationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensStorageLensTableDestinationPropertyValidator(properties).assertSuccess(),{Encryption:convertCfnStorageLensEncryptionPropertyToCloudFormation(properties.encryption),IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled)}):properties}function CfnStorageLensStorageLensTableDestinationPropertyFromCloudFormation(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("encryption","Encryption",properties.Encryption!=null?CfnStorageLensEncryptionPropertyFromCloudFormation(properties.Encryption):void 0),ret.addPropertyResult("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensDataExportPropertyValidator(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("cloudWatchMetrics",CfnStorageLensCloudWatchMetricsPropertyValidator)(properties.cloudWatchMetrics)),errors.collect(cdk().propertyValidator("s3BucketDestination",CfnStorageLensS3BucketDestinationPropertyValidator)(properties.s3BucketDestination)),errors.collect(cdk().propertyValidator("storageLensTableDestination",CfnStorageLensStorageLensTableDestinationPropertyValidator)(properties.storageLensTableDestination)),errors.wrap('supplied properties not correct for "DataExportProperty"')}function convertCfnStorageLensDataExportPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensDataExportPropertyValidator(properties).assertSuccess(),{CloudWatchMetrics:convertCfnStorageLensCloudWatchMetricsPropertyToCloudFormation(properties.cloudWatchMetrics),S3BucketDestination:convertCfnStorageLensS3BucketDestinationPropertyToCloudFormation(properties.s3BucketDestination),StorageLensTableDestination:convertCfnStorageLensStorageLensTableDestinationPropertyToCloudFormation(properties.storageLensTableDestination)}):properties}function CfnStorageLensDataExportPropertyFromCloudFormation(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("cloudWatchMetrics","CloudWatchMetrics",properties.CloudWatchMetrics!=null?CfnStorageLensCloudWatchMetricsPropertyFromCloudFormation(properties.CloudWatchMetrics):void 0),ret.addPropertyResult("s3BucketDestination","S3BucketDestination",properties.S3BucketDestination!=null?CfnStorageLensS3BucketDestinationPropertyFromCloudFormation(properties.S3BucketDestination):void 0),ret.addPropertyResult("storageLensTableDestination","StorageLensTableDestination",properties.StorageLensTableDestination!=null?CfnStorageLensStorageLensTableDestinationPropertyFromCloudFormation(properties.StorageLensTableDestination):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensStorageLensExpandedPrefixesDataExportPropertyValidator(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("s3BucketDestination",CfnStorageLensS3BucketDestinationPropertyValidator)(properties.s3BucketDestination)),errors.collect(cdk().propertyValidator("storageLensTableDestination",CfnStorageLensStorageLensTableDestinationPropertyValidator)(properties.storageLensTableDestination)),errors.wrap('supplied properties not correct for "StorageLensExpandedPrefixesDataExportProperty"')}function convertCfnStorageLensStorageLensExpandedPrefixesDataExportPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensStorageLensExpandedPrefixesDataExportPropertyValidator(properties).assertSuccess(),{S3BucketDestination:convertCfnStorageLensS3BucketDestinationPropertyToCloudFormation(properties.s3BucketDestination),StorageLensTableDestination:convertCfnStorageLensStorageLensTableDestinationPropertyToCloudFormation(properties.storageLensTableDestination)}):properties}function CfnStorageLensStorageLensExpandedPrefixesDataExportPropertyFromCloudFormation(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("s3BucketDestination","S3BucketDestination",properties.S3BucketDestination!=null?CfnStorageLensS3BucketDestinationPropertyFromCloudFormation(properties.S3BucketDestination):void 0),ret.addPropertyResult("storageLensTableDestination","StorageLensTableDestination",properties.StorageLensTableDestination!=null?CfnStorageLensStorageLensTableDestinationPropertyFromCloudFormation(properties.StorageLensTableDestination):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensStorageLensConfigurationPropertyValidator(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("accountLevel",cdk().requiredValidator)(properties.accountLevel)),errors.collect(cdk().propertyValidator("accountLevel",CfnStorageLensAccountLevelPropertyValidator)(properties.accountLevel)),errors.collect(cdk().propertyValidator("awsOrg",CfnStorageLensAwsOrgPropertyValidator)(properties.awsOrg)),errors.collect(cdk().propertyValidator("dataExport",CfnStorageLensDataExportPropertyValidator)(properties.dataExport)),errors.collect(cdk().propertyValidator("exclude",CfnStorageLensBucketsAndRegionsPropertyValidator)(properties.exclude)),errors.collect(cdk().propertyValidator("expandedPrefixesDataExport",CfnStorageLensStorageLensExpandedPrefixesDataExportPropertyValidator)(properties.expandedPrefixesDataExport)),errors.collect(cdk().propertyValidator("id",cdk().requiredValidator)(properties.id)),errors.collect(cdk().propertyValidator("id",cdk().validateString)(properties.id)),errors.collect(cdk().propertyValidator("include",CfnStorageLensBucketsAndRegionsPropertyValidator)(properties.include)),errors.collect(cdk().propertyValidator("isEnabled",cdk().requiredValidator)(properties.isEnabled)),errors.collect(cdk().propertyValidator("isEnabled",cdk().validateBoolean)(properties.isEnabled)),errors.collect(cdk().propertyValidator("prefixDelimiter",cdk().validateString)(properties.prefixDelimiter)),errors.collect(cdk().propertyValidator("storageLensArn",cdk().validateString)(properties.storageLensArn)),errors.wrap('supplied properties not correct for "StorageLensConfigurationProperty"')}function convertCfnStorageLensStorageLensConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensStorageLensConfigurationPropertyValidator(properties).assertSuccess(),{AccountLevel:convertCfnStorageLensAccountLevelPropertyToCloudFormation(properties.accountLevel),AwsOrg:convertCfnStorageLensAwsOrgPropertyToCloudFormation(properties.awsOrg),DataExport:convertCfnStorageLensDataExportPropertyToCloudFormation(properties.dataExport),Exclude:convertCfnStorageLensBucketsAndRegionsPropertyToCloudFormation(properties.exclude),ExpandedPrefixesDataExport:convertCfnStorageLensStorageLensExpandedPrefixesDataExportPropertyToCloudFormation(properties.expandedPrefixesDataExport),Id:cdk().stringToCloudFormation(properties.id),Include:convertCfnStorageLensBucketsAndRegionsPropertyToCloudFormation(properties.include),IsEnabled:cdk().booleanToCloudFormation(properties.isEnabled),PrefixDelimiter:cdk().stringToCloudFormation(properties.prefixDelimiter),StorageLensArn:cdk().stringToCloudFormation(properties.storageLensArn)}):properties}function CfnStorageLensStorageLensConfigurationPropertyFromCloudFormation(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("accountLevel","AccountLevel",properties.AccountLevel!=null?CfnStorageLensAccountLevelPropertyFromCloudFormation(properties.AccountLevel):void 0),ret.addPropertyResult("awsOrg","AwsOrg",properties.AwsOrg!=null?CfnStorageLensAwsOrgPropertyFromCloudFormation(properties.AwsOrg):void 0),ret.addPropertyResult("dataExport","DataExport",properties.DataExport!=null?CfnStorageLensDataExportPropertyFromCloudFormation(properties.DataExport):void 0),ret.addPropertyResult("exclude","Exclude",properties.Exclude!=null?CfnStorageLensBucketsAndRegionsPropertyFromCloudFormation(properties.Exclude):void 0),ret.addPropertyResult("expandedPrefixesDataExport","ExpandedPrefixesDataExport",properties.ExpandedPrefixesDataExport!=null?CfnStorageLensStorageLensExpandedPrefixesDataExportPropertyFromCloudFormation(properties.ExpandedPrefixesDataExport):void 0),ret.addPropertyResult("id","Id",properties.Id!=null?cfn_parse().FromCloudFormation.getString(properties.Id):void 0),ret.addPropertyResult("include","Include",properties.Include!=null?CfnStorageLensBucketsAndRegionsPropertyFromCloudFormation(properties.Include):void 0),ret.addPropertyResult("isEnabled","IsEnabled",properties.IsEnabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.IsEnabled):void 0),ret.addPropertyResult("prefixDelimiter","PrefixDelimiter",properties.PrefixDelimiter!=null?cfn_parse().FromCloudFormation.getString(properties.PrefixDelimiter):void 0),ret.addPropertyResult("storageLensArn","StorageLensArn",properties.StorageLensArn!=null?cfn_parse().FromCloudFormation.getString(properties.StorageLensArn):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensPropsValidator(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("storageLensConfiguration",cdk().requiredValidator)(properties.storageLensConfiguration)),errors.collect(cdk().propertyValidator("storageLensConfiguration",CfnStorageLensStorageLensConfigurationPropertyValidator)(properties.storageLensConfiguration)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "CfnStorageLensProps"')}function convertCfnStorageLensPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensPropsValidator(properties).assertSuccess(),{StorageLensConfiguration:convertCfnStorageLensStorageLensConfigurationPropertyToCloudFormation(properties.storageLensConfiguration),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnStorageLensPropsFromCloudFormation(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("storageLensConfiguration","StorageLensConfiguration",properties.StorageLensConfiguration!=null?CfnStorageLensStorageLensConfigurationPropertyFromCloudFormation(properties.StorageLensConfiguration):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnAccessGrant extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnAccessGrant",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::AccessGrant";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnAccessGrantPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnAccessGrant(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}static isCfnAccessGrant(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnAccessGrant.CFN_RESOURCE_TYPE_NAME}static arnForAccessGrant(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IAccessGrantRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForAccessGrant),error}return resource.accessGrantRef.accessGrantArn}_accessGrantsLocationConfiguration;_accessGrantsLocationId;_applicationArn;cdkTagManager;_grantee;_permission;_s3PrefixType;_tags;cfnPropertyNames={accessGrantsLocationConfiguration:"AccessGrantsLocationConfiguration",accessGrantsLocationId:"AccessGrantsLocationId",applicationArn:"ApplicationArn",tags:"Tags",grantee:"Grantee",permission:"Permission",s3PrefixType:"S3PrefixType"};constructor(scope,id,props){super(scope,id,{type:CfnAccessGrant.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnAccessGrantProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnAccessGrant),error}cdk().requireProperty(props,"accessGrantsLocationId",this),cdk().requireProperty(props,"grantee",this),cdk().requireProperty(props,"permission",this),this._accessGrantsLocationConfiguration=props.accessGrantsLocationConfiguration,this._accessGrantsLocationId=props.accessGrantsLocationId,this._applicationArn=props.applicationArn,this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::AccessGrant",void 0,{tagPropertyName:"tags"}),this._grantee=props.grantee,this._permission=props.permission,this._s3PrefixType=props.s3PrefixType,this._tags=props.tags}get accessGrantRef(){return{accessGrantId:this.ref,accessGrantArn:this.attrAccessGrantArn}}get accessGrantsLocationConfiguration(){return this._accessGrantsLocationConfiguration}set accessGrantsLocationConfiguration(value){cdk().traceProperty(this.node,"AccessGrantsLocationConfiguration"),this._accessGrantsLocationConfiguration=value}get accessGrantsLocationId(){return this._accessGrantsLocationId}set accessGrantsLocationId(value){cdk().traceProperty(this.node,"AccessGrantsLocationId"),this._accessGrantsLocationId=value}get applicationArn(){return this._applicationArn}set applicationArn(value){cdk().traceProperty(this.node,"ApplicationArn"),this._applicationArn=value}get grantee(){return this._grantee}set grantee(value){cdk().traceProperty(this.node,"Grantee"),this._grantee=value}get permission(){return this._permission}set permission(value){cdk().traceProperty(this.node,"Permission"),this._permission=value}get s3PrefixType(){return this._s3PrefixType}set s3PrefixType(value){cdk().traceProperty(this.node,"S3PrefixType"),this._s3PrefixType=value}get tags(){return this._tags}set tags(value){cdk().traceProperty(this.node,"Tags"),this._tags=value}get attrAccessGrantArn(){return cdk().Token.asString(this.getAtt("AccessGrantArn",cdk().ResolutionTypeHint.STRING))}get attrAccessGrantId(){return cdk().Token.asString(this.getAtt("AccessGrantId",cdk().ResolutionTypeHint.STRING))}get attrGrantScope(){return cdk().Token.asString(this.getAtt("GrantScope",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{accessGrantsLocationConfiguration:this._accessGrantsLocationConfiguration,accessGrantsLocationId:this._accessGrantsLocationId,applicationArn:this._applicationArn,tags:this.cdkTagManager.renderTags(this._tags),grantee:this._grantee,permission:this._permission,s3PrefixType:this._s3PrefixType}}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",CfnAccessGrant.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnAccessGrantPropsToCloudFormation(props)}}exports.CfnAccessGrant=CfnAccessGrant;function CfnAccessGrantGranteePropertyValidator(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("granteeIdentifier",cdk().requiredValidator)(properties.granteeIdentifier)),errors.collect(cdk().propertyValidator("granteeIdentifier",cdk().validateString)(properties.granteeIdentifier)),errors.collect(cdk().propertyValidator("granteeType",cdk().requiredValidator)(properties.granteeType)),errors.collect(cdk().propertyValidator("granteeType",cdk().validateString)(properties.granteeType)),errors.wrap('supplied properties not correct for "GranteeProperty"')}function convertCfnAccessGrantGranteePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessGrantGranteePropertyValidator(properties).assertSuccess(),{GranteeIdentifier:cdk().stringToCloudFormation(properties.granteeIdentifier),GranteeType:cdk().stringToCloudFormation(properties.granteeType)}):properties}function CfnAccessGrantGranteePropertyFromCloudFormation(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("granteeIdentifier","GranteeIdentifier",properties.GranteeIdentifier!=null?cfn_parse().FromCloudFormation.getString(properties.GranteeIdentifier):void 0),ret.addPropertyResult("granteeType","GranteeType",properties.GranteeType!=null?cfn_parse().FromCloudFormation.getString(properties.GranteeType):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnAccessGrantAccessGrantsLocationConfigurationPropertyValidator(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("s3SubPrefix",cdk().requiredValidator)(properties.s3SubPrefix)),errors.collect(cdk().propertyValidator("s3SubPrefix",cdk().validateString)(properties.s3SubPrefix)),errors.wrap('supplied properties not correct for "AccessGrantsLocationConfigurationProperty"')}function convertCfnAccessGrantAccessGrantsLocationConfigurationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessGrantAccessGrantsLocationConfigurationPropertyValidator(properties).assertSuccess(),{S3SubPrefix:cdk().stringToCloudFormation(properties.s3SubPrefix)}):properties}function CfnAccessGrantAccessGrantsLocationConfigurationPropertyFromCloudFormation(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("s3SubPrefix","S3SubPrefix",properties.S3SubPrefix!=null?cfn_parse().FromCloudFormation.getString(properties.S3SubPrefix):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnAccessGrantPropsValidator(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("accessGrantsLocationConfiguration",CfnAccessGrantAccessGrantsLocationConfigurationPropertyValidator)(properties.accessGrantsLocationConfiguration)),errors.collect(cdk().propertyValidator("accessGrantsLocationId",cdk().requiredValidator)(properties.accessGrantsLocationId)),errors.collect(cdk().propertyValidator("accessGrantsLocationId",cdk().validateString)(properties.accessGrantsLocationId)),errors.collect(cdk().propertyValidator("applicationArn",cdk().validateString)(properties.applicationArn)),errors.collect(cdk().propertyValidator("grantee",cdk().requiredValidator)(properties.grantee)),errors.collect(cdk().propertyValidator("grantee",CfnAccessGrantGranteePropertyValidator)(properties.grantee)),errors.collect(cdk().propertyValidator("permission",cdk().requiredValidator)(properties.permission)),errors.collect(cdk().propertyValidator("permission",cdk().validateString)(properties.permission)),errors.collect(cdk().propertyValidator("s3PrefixType",cdk().validateString)(properties.s3PrefixType)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "CfnAccessGrantProps"')}function convertCfnAccessGrantPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessGrantPropsValidator(properties).assertSuccess(),{AccessGrantsLocationConfiguration:convertCfnAccessGrantAccessGrantsLocationConfigurationPropertyToCloudFormation(properties.accessGrantsLocationConfiguration),AccessGrantsLocationId:cdk().stringToCloudFormation(properties.accessGrantsLocationId),ApplicationArn:cdk().stringToCloudFormation(properties.applicationArn),Grantee:convertCfnAccessGrantGranteePropertyToCloudFormation(properties.grantee),Permission:cdk().stringToCloudFormation(properties.permission),S3PrefixType:cdk().stringToCloudFormation(properties.s3PrefixType),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnAccessGrantPropsFromCloudFormation(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("accessGrantsLocationConfiguration","AccessGrantsLocationConfiguration",properties.AccessGrantsLocationConfiguration!=null?CfnAccessGrantAccessGrantsLocationConfigurationPropertyFromCloudFormation(properties.AccessGrantsLocationConfiguration):void 0),ret.addPropertyResult("accessGrantsLocationId","AccessGrantsLocationId",properties.AccessGrantsLocationId!=null?cfn_parse().FromCloudFormation.getString(properties.AccessGrantsLocationId):void 0),ret.addPropertyResult("applicationArn","ApplicationArn",properties.ApplicationArn!=null?cfn_parse().FromCloudFormation.getString(properties.ApplicationArn):void 0),ret.addPropertyResult("grantee","Grantee",properties.Grantee!=null?CfnAccessGrantGranteePropertyFromCloudFormation(properties.Grantee):void 0),ret.addPropertyResult("permission","Permission",properties.Permission!=null?cfn_parse().FromCloudFormation.getString(properties.Permission):void 0),ret.addPropertyResult("s3PrefixType","S3PrefixType",properties.S3PrefixType!=null?cfn_parse().FromCloudFormation.getString(properties.S3PrefixType):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnAccessGrantsInstance extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnAccessGrantsInstance",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::AccessGrantsInstance";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnAccessGrantsInstancePropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnAccessGrantsInstance(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}static isCfnAccessGrantsInstance(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnAccessGrantsInstance.CFN_RESOURCE_TYPE_NAME}static arnForAccessGrantsInstance(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IAccessGrantsInstanceRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForAccessGrantsInstance),error}return resource.accessGrantsInstanceRef.accessGrantsInstanceArn}cdkTagManager;_identityCenterArn;_tags;cfnPropertyNames={tags:"Tags",identityCenterArn:"IdentityCenterArn"};constructor(scope,id,props={}){super(scope,id,{type:CfnAccessGrantsInstance.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnAccessGrantsInstanceProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnAccessGrantsInstance),error}this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::AccessGrantsInstance",void 0,{tagPropertyName:"tags"}),this._identityCenterArn=props.identityCenterArn,this._tags=props.tags}get accessGrantsInstanceRef(){return{accessGrantsInstanceArn:this.ref}}get identityCenterArn(){return this._identityCenterArn}set identityCenterArn(value){cdk().traceProperty(this.node,"IdentityCenterArn"),this._identityCenterArn=value}get tags(){return this._tags}set tags(value){cdk().traceProperty(this.node,"Tags"),this._tags=value}get attrAccessGrantsInstanceArn(){return cdk().Token.asString(this.getAtt("AccessGrantsInstanceArn",cdk().ResolutionTypeHint.STRING))}get attrAccessGrantsInstanceId(){return cdk().Token.asString(this.getAtt("AccessGrantsInstanceId",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{tags:this.cdkTagManager.renderTags(this._tags),identityCenterArn:this._identityCenterArn}}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",CfnAccessGrantsInstance.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnAccessGrantsInstancePropsToCloudFormation(props)}}exports.CfnAccessGrantsInstance=CfnAccessGrantsInstance;function CfnAccessGrantsInstancePropsValidator(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("identityCenterArn",cdk().validateString)(properties.identityCenterArn)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "CfnAccessGrantsInstanceProps"')}function convertCfnAccessGrantsInstancePropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessGrantsInstancePropsValidator(properties).assertSuccess(),{IdentityCenterArn:cdk().stringToCloudFormation(properties.identityCenterArn),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnAccessGrantsInstancePropsFromCloudFormation(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("identityCenterArn","IdentityCenterArn",properties.IdentityCenterArn!=null?cfn_parse().FromCloudFormation.getString(properties.IdentityCenterArn):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnAccessGrantsLocation extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnAccessGrantsLocation",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::AccessGrantsLocation";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnAccessGrantsLocationPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnAccessGrantsLocation(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}static isCfnAccessGrantsLocation(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnAccessGrantsLocation.CFN_RESOURCE_TYPE_NAME}static arnForAccessGrantsLocation(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IAccessGrantsLocationRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForAccessGrantsLocation),error}return resource.accessGrantsLocationRef.accessGrantsLocationArn}cdkTagManager;_iamRoleArn;_locationScope;_tags;cfnPropertyNames={tags:"Tags",iamRoleArn:"IamRoleArn",locationScope:"LocationScope"};constructor(scope,id,props){super(scope,id,{type:CfnAccessGrantsLocation.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnAccessGrantsLocationProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnAccessGrantsLocation),error}cdk().requireProperty(props,"iamRoleArn",this),cdk().requireProperty(props,"locationScope",this),this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::AccessGrantsLocation",void 0,{tagPropertyName:"tags"}),this._iamRoleArn=props.iamRoleArn,this._locationScope=props.locationScope,this._tags=props.tags}get accessGrantsLocationRef(){return{accessGrantsLocationId:this.ref,accessGrantsLocationArn:this.attrAccessGrantsLocationArn}}get iamRoleArn(){return this._iamRoleArn}set iamRoleArn(value){cdk().traceProperty(this.node,"IamRoleArn"),this._iamRoleArn=value}get locationScope(){return this._locationScope}set locationScope(value){cdk().traceProperty(this.node,"LocationScope"),this._locationScope=value}get tags(){return this._tags}set tags(value){cdk().traceProperty(this.node,"Tags"),this._tags=value}get attrAccessGrantsLocationArn(){return cdk().Token.asString(this.getAtt("AccessGrantsLocationArn",cdk().ResolutionTypeHint.STRING))}get attrAccessGrantsLocationId(){return cdk().Token.asString(this.getAtt("AccessGrantsLocationId",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{tags:this.cdkTagManager.renderTags(this._tags),iamRoleArn:this._iamRoleArn,locationScope:this._locationScope}}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",CfnAccessGrantsLocation.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnAccessGrantsLocationPropsToCloudFormation(props)}}exports.CfnAccessGrantsLocation=CfnAccessGrantsLocation;function CfnAccessGrantsLocationPropsValidator(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("iamRoleArn",cdk().requiredValidator)(properties.iamRoleArn)),errors.collect(cdk().propertyValidator("iamRoleArn",cdk().validateString)(properties.iamRoleArn)),errors.collect(cdk().propertyValidator("locationScope",cdk().requiredValidator)(properties.locationScope)),errors.collect(cdk().propertyValidator("locationScope",cdk().validateString)(properties.locationScope)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "CfnAccessGrantsLocationProps"')}function convertCfnAccessGrantsLocationPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnAccessGrantsLocationPropsValidator(properties).assertSuccess(),{IamRoleArn:cdk().stringToCloudFormation(properties.iamRoleArn),LocationScope:cdk().stringToCloudFormation(properties.locationScope),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnAccessGrantsLocationPropsFromCloudFormation(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("iamRoleArn","IamRoleArn",properties.IamRoleArn!=null?cfn_parse().FromCloudFormation.getString(properties.IamRoleArn):void 0),ret.addPropertyResult("locationScope","LocationScope",properties.LocationScope!=null?cfn_parse().FromCloudFormation.getString(properties.LocationScope):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnStorageLensGroup extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_s3.CfnStorageLensGroup",version:"2.252.0"};static CFN_RESOURCE_TYPE_NAME="AWS::S3::StorageLensGroup";static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnStorageLensGroupPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError(cfn_parse().lit`UnexpectedIResolvable`,"Unexpected IResolvable",scope);const ret=new CfnStorageLensGroup(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}static isCfnStorageLensGroup(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnStorageLensGroup.CFN_RESOURCE_TYPE_NAME}static arnForStorageLensGroup(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_s3_IStorageLensGroupRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForStorageLensGroup),error}return resource.storageLensGroupRef.storageLensGroupArn}cdkTagManager;_filter;_name;_tags;cfnPropertyNames={tags:"Tags",filter:"Filter",name:"Name"};constructor(scope,id,props){super(scope,id,{type:CfnStorageLensGroup.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_s3_CfnStorageLensGroupProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnStorageLensGroup),error}cdk().requireProperty(props,"filter",this),cdk().requireProperty(props,"name",this),this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::S3::StorageLensGroup",void 0,{tagPropertyName:"tags"}),this._filter=props.filter,this._name=props.name,this._tags=props.tags}get storageLensGroupRef(){return{storageLensGroupName:this.ref,storageLensGroupArn:this.attrStorageLensGroupArn}}get filter(){return this._filter}set filter(value){cdk().traceProperty(this.node,"Filter"),this._filter=value}get name(){return this._name}set name(value){cdk().traceProperty(this.node,"Name"),this._name=value}get tags(){return this._tags}set tags(value){cdk().traceProperty(this.node,"Tags"),this._tags=value}get attrStorageLensGroupArn(){return cdk().Token.asString(this.getAtt("StorageLensGroupArn",cdk().ResolutionTypeHint.STRING))}get cfnProperties(){return{tags:this.cdkTagManager.renderTags(this._tags),filter:this._filter,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",CfnStorageLensGroup.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:logicalId",this._synthesizeLogicalId()),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnStorageLensGroupPropsToCloudFormation(props)}}exports.CfnStorageLensGroup=CfnStorageLensGroup;function CfnStorageLensGroupMatchObjectSizePropertyValidator(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("bytesGreaterThan",cdk().validateNumber)(properties.bytesGreaterThan)),errors.collect(cdk().propertyValidator("bytesLessThan",cdk().validateNumber)(properties.bytesLessThan)),errors.wrap('supplied properties not correct for "MatchObjectSizeProperty"')}function convertCfnStorageLensGroupMatchObjectSizePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupMatchObjectSizePropertyValidator(properties).assertSuccess(),{BytesGreaterThan:cdk().numberToCloudFormation(properties.bytesGreaterThan),BytesLessThan:cdk().numberToCloudFormation(properties.bytesLessThan)}):properties}function CfnStorageLensGroupMatchObjectSizePropertyFromCloudFormation(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("bytesGreaterThan","BytesGreaterThan",properties.BytesGreaterThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.BytesGreaterThan):void 0),ret.addPropertyResult("bytesLessThan","BytesLessThan",properties.BytesLessThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.BytesLessThan):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensGroupMatchObjectAgePropertyValidator(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("daysGreaterThan",cdk().validateNumber)(properties.daysGreaterThan)),errors.collect(cdk().propertyValidator("daysLessThan",cdk().validateNumber)(properties.daysLessThan)),errors.wrap('supplied properties not correct for "MatchObjectAgeProperty"')}function convertCfnStorageLensGroupMatchObjectAgePropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupMatchObjectAgePropertyValidator(properties).assertSuccess(),{DaysGreaterThan:cdk().numberToCloudFormation(properties.daysGreaterThan),DaysLessThan:cdk().numberToCloudFormation(properties.daysLessThan)}):properties}function CfnStorageLensGroupMatchObjectAgePropertyFromCloudFormation(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("daysGreaterThan","DaysGreaterThan",properties.DaysGreaterThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.DaysGreaterThan):void 0),ret.addPropertyResult("daysLessThan","DaysLessThan",properties.DaysLessThan!=null?cfn_parse().FromCloudFormation.getNumber(properties.DaysLessThan):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensGroupAndPropertyValidator(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("matchAnyPrefix",cdk().listValidator(cdk().validateString))(properties.matchAnyPrefix)),errors.collect(cdk().propertyValidator("matchAnySuffix",cdk().listValidator(cdk().validateString))(properties.matchAnySuffix)),errors.collect(cdk().propertyValidator("matchAnyTag",cdk().listValidator(cdk().validateCfnTag))(properties.matchAnyTag)),errors.collect(cdk().propertyValidator("matchObjectAge",CfnStorageLensGroupMatchObjectAgePropertyValidator)(properties.matchObjectAge)),errors.collect(cdk().propertyValidator("matchObjectSize",CfnStorageLensGroupMatchObjectSizePropertyValidator)(properties.matchObjectSize)),errors.wrap('supplied properties not correct for "AndProperty"')}function convertCfnStorageLensGroupAndPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupAndPropertyValidator(properties).assertSuccess(),{MatchAnyPrefix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnyPrefix),MatchAnySuffix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnySuffix),MatchAnyTag:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.matchAnyTag),MatchObjectAge:convertCfnStorageLensGroupMatchObjectAgePropertyToCloudFormation(properties.matchObjectAge),MatchObjectSize:convertCfnStorageLensGroupMatchObjectSizePropertyToCloudFormation(properties.matchObjectSize)}):properties}function CfnStorageLensGroupAndPropertyFromCloudFormation(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("matchAnyPrefix","MatchAnyPrefix",properties.MatchAnyPrefix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnyPrefix):void 0),ret.addPropertyResult("matchAnySuffix","MatchAnySuffix",properties.MatchAnySuffix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnySuffix):void 0),ret.addPropertyResult("matchAnyTag","MatchAnyTag",properties.MatchAnyTag!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.MatchAnyTag):void 0),ret.addPropertyResult("matchObjectAge","MatchObjectAge",properties.MatchObjectAge!=null?CfnStorageLensGroupMatchObjectAgePropertyFromCloudFormation(properties.MatchObjectAge):void 0),ret.addPropertyResult("matchObjectSize","MatchObjectSize",properties.MatchObjectSize!=null?CfnStorageLensGroupMatchObjectSizePropertyFromCloudFormation(properties.MatchObjectSize):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensGroupOrPropertyValidator(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("matchAnyPrefix",cdk().listValidator(cdk().validateString))(properties.matchAnyPrefix)),errors.collect(cdk().propertyValidator("matchAnySuffix",cdk().listValidator(cdk().validateString))(properties.matchAnySuffix)),errors.collect(cdk().propertyValidator("matchAnyTag",cdk().listValidator(cdk().validateCfnTag))(properties.matchAnyTag)),errors.collect(cdk().propertyValidator("matchObjectAge",CfnStorageLensGroupMatchObjectAgePropertyValidator)(properties.matchObjectAge)),errors.collect(cdk().propertyValidator("matchObjectSize",CfnStorageLensGroupMatchObjectSizePropertyValidator)(properties.matchObjectSize)),errors.wrap('supplied properties not correct for "OrProperty"')}function convertCfnStorageLensGroupOrPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupOrPropertyValidator(properties).assertSuccess(),{MatchAnyPrefix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnyPrefix),MatchAnySuffix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnySuffix),MatchAnyTag:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.matchAnyTag),MatchObjectAge:convertCfnStorageLensGroupMatchObjectAgePropertyToCloudFormation(properties.matchObjectAge),MatchObjectSize:convertCfnStorageLensGroupMatchObjectSizePropertyToCloudFormation(properties.matchObjectSize)}):properties}function CfnStorageLensGroupOrPropertyFromCloudFormation(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("matchAnyPrefix","MatchAnyPrefix",properties.MatchAnyPrefix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnyPrefix):void 0),ret.addPropertyResult("matchAnySuffix","MatchAnySuffix",properties.MatchAnySuffix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnySuffix):void 0),ret.addPropertyResult("matchAnyTag","MatchAnyTag",properties.MatchAnyTag!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.MatchAnyTag):void 0),ret.addPropertyResult("matchObjectAge","MatchObjectAge",properties.MatchObjectAge!=null?CfnStorageLensGroupMatchObjectAgePropertyFromCloudFormation(properties.MatchObjectAge):void 0),ret.addPropertyResult("matchObjectSize","MatchObjectSize",properties.MatchObjectSize!=null?CfnStorageLensGroupMatchObjectSizePropertyFromCloudFormation(properties.MatchObjectSize):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensGroupFilterPropertyValidator(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("and",CfnStorageLensGroupAndPropertyValidator)(properties.and)),errors.collect(cdk().propertyValidator("matchAnyPrefix",cdk().listValidator(cdk().validateString))(properties.matchAnyPrefix)),errors.collect(cdk().propertyValidator("matchAnySuffix",cdk().listValidator(cdk().validateString))(properties.matchAnySuffix)),errors.collect(cdk().propertyValidator("matchAnyTag",cdk().listValidator(cdk().validateCfnTag))(properties.matchAnyTag)),errors.collect(cdk().propertyValidator("matchObjectAge",CfnStorageLensGroupMatchObjectAgePropertyValidator)(properties.matchObjectAge)),errors.collect(cdk().propertyValidator("matchObjectSize",CfnStorageLensGroupMatchObjectSizePropertyValidator)(properties.matchObjectSize)),errors.collect(cdk().propertyValidator("or",CfnStorageLensGroupOrPropertyValidator)(properties.or)),errors.wrap('supplied properties not correct for "FilterProperty"')}function convertCfnStorageLensGroupFilterPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupFilterPropertyValidator(properties).assertSuccess(),{And:convertCfnStorageLensGroupAndPropertyToCloudFormation(properties.and),MatchAnyPrefix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnyPrefix),MatchAnySuffix:cdk().listMapper(cdk().stringToCloudFormation)(properties.matchAnySuffix),MatchAnyTag:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.matchAnyTag),MatchObjectAge:convertCfnStorageLensGroupMatchObjectAgePropertyToCloudFormation(properties.matchObjectAge),MatchObjectSize:convertCfnStorageLensGroupMatchObjectSizePropertyToCloudFormation(properties.matchObjectSize),Or:convertCfnStorageLensGroupOrPropertyToCloudFormation(properties.or)}):properties}function CfnStorageLensGroupFilterPropertyFromCloudFormation(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("and","And",properties.And!=null?CfnStorageLensGroupAndPropertyFromCloudFormation(properties.And):void 0),ret.addPropertyResult("matchAnyPrefix","MatchAnyPrefix",properties.MatchAnyPrefix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnyPrefix):void 0),ret.addPropertyResult("matchAnySuffix","MatchAnySuffix",properties.MatchAnySuffix!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getString)(properties.MatchAnySuffix):void 0),ret.addPropertyResult("matchAnyTag","MatchAnyTag",properties.MatchAnyTag!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.MatchAnyTag):void 0),ret.addPropertyResult("matchObjectAge","MatchObjectAge",properties.MatchObjectAge!=null?CfnStorageLensGroupMatchObjectAgePropertyFromCloudFormation(properties.MatchObjectAge):void 0),ret.addPropertyResult("matchObjectSize","MatchObjectSize",properties.MatchObjectSize!=null?CfnStorageLensGroupMatchObjectSizePropertyFromCloudFormation(properties.MatchObjectSize):void 0),ret.addPropertyResult("or","Or",properties.Or!=null?CfnStorageLensGroupOrPropertyFromCloudFormation(properties.Or):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnStorageLensGroupPropsValidator(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("filter",cdk().requiredValidator)(properties.filter)),errors.collect(cdk().propertyValidator("filter",CfnStorageLensGroupFilterPropertyValidator)(properties.filter)),errors.collect(cdk().propertyValidator("name",cdk().requiredValidator)(properties.name)),errors.collect(cdk().propertyValidator("name",cdk().validateString)(properties.name)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "CfnStorageLensGroupProps"')}function convertCfnStorageLensGroupPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnStorageLensGroupPropsValidator(properties).assertSuccess(),{Filter:convertCfnStorageLensGroupFilterPropertyToCloudFormation(properties.filter),Name:cdk().stringToCloudFormation(properties.name),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnStorageLensGroupPropsFromCloudFormation(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("filter","Filter",properties.Filter!=null?CfnStorageLensGroupFilterPropertyFromCloudFormation(properties.Filter):void 0),ret.addPropertyResult("name","Name",properties.Name!=null?cfn_parse().FromCloudFormation.getString(properties.Name):void 0),ret.addPropertyResult("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}