aws-cdk-lib
Version:
Version 2 of the AWS Cloud Development Kit library
1 lines • 1.19 MB
JavaScript
"use strict";var _a,_b,_c,_d,_e,_f,_g,_h,_j,_k,_l,_m,_o,_p,_q,_r,_s,_t,_u,_v,_w,_x,_y,_z,_0,_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13,_14,_15,_16,_17,_18,_19,_20,_21,_22,_23,_24,_25,_26,_27,_28,_29,_30,_31,_32,_33,_34,_35,_36,_37,_38,_39,_40,_41,_42,_43,_44,_45,_46,_47,_48,_49,_50,_51,_52,_53,_54,_55,_56,_57,_58,_59,_60,_61,_62,_63,_64,_65,_66,_67,_68,_69,_70,_71,_72,_73,_74,_75,_76;Object.defineProperty(exports,"__esModule",{value:!0}),exports.CfnSecurityGroupEgress=exports.CfnSecurityGroup=exports.CfnRouteTable=exports.CfnRoute=exports.CfnPrefixList=exports.CfnPlacementGroup=exports.CfnNetworkPerformanceMetricSubscription=exports.CfnNetworkInterfacePermission=exports.CfnNetworkInterfaceAttachment=exports.CfnNetworkInterface=exports.CfnNetworkInsightsPath=exports.CfnNetworkInsightsAnalysis=exports.CfnNetworkInsightsAccessScopeAnalysis=exports.CfnNetworkInsightsAccessScope=exports.CfnNetworkAclEntry=exports.CfnNetworkAcl=exports.CfnNatGateway=exports.CfnLocalGatewayRouteTableVirtualInterfaceGroupAssociation=exports.CfnLocalGatewayRouteTableVPCAssociation=exports.CfnLocalGatewayRouteTable=exports.CfnLocalGatewayRoute=exports.CfnLaunchTemplate=exports.CfnKeyPair=exports.CfnInternetGateway=exports.CfnInstanceConnectEndpoint=exports.CfnInstance=exports.CfnIPAMScope=exports.CfnIPAMResourceDiscoveryAssociation=exports.CfnIPAMResourceDiscovery=exports.CfnIPAMPoolCidr=exports.CfnIPAMPool=exports.CfnIPAMAllocation=exports.CfnIPAM=exports.CfnHost=exports.CfnGatewayRouteTableAssociation=exports.CfnFlowLog=exports.CfnEnclaveCertificateIamRoleAssociation=exports.CfnEgressOnlyInternetGateway=exports.CfnEIPAssociation=exports.CfnEIP=exports.CfnEC2Fleet=exports.CfnDHCPOptions=exports.CfnCustomerGateway=exports.CfnClientVpnTargetNetworkAssociation=exports.CfnClientVpnRoute=exports.CfnClientVpnEndpoint=exports.CfnClientVpnAuthorizationRule=exports.CfnCarrierGateway=exports.CfnCapacityReservationFleet=exports.CfnCapacityReservation=void 0,exports.CfnVPCBlockPublicAccessExclusion=exports.CfnSnapshotBlockPublicAccess=exports.CfnSecurityGroupVpcAssociation=exports.CfnRouteServerPropagation=exports.CfnRouteServerPeer=exports.CfnRouteServerEndpoint=exports.CfnRouteServerAssociation=exports.CfnRouteServer=exports.CfnVolumeAttachment=exports.CfnVolume=exports.CfnVerifiedAccessTrustProvider=exports.CfnVerifiedAccessInstance=exports.CfnVerifiedAccessGroup=exports.CfnVerifiedAccessEndpoint=exports.CfnVPNGatewayRoutePropagation=exports.CfnVPNGateway=exports.CfnVPNConnectionRoute=exports.CfnVPNConnection=exports.CfnVPCPeeringConnection=exports.CfnVPCGatewayAttachment=exports.CfnVPCEndpointServicePermissions=exports.CfnVPCEndpointService=exports.CfnVPCEndpointConnectionNotification=exports.CfnVPCEndpoint=exports.CfnVPCDHCPOptionsAssociation=exports.CfnVPCCidrBlock=exports.CfnVPC=exports.CfnTransitGatewayVpcAttachment=exports.CfnTransitGatewayRouteTablePropagation=exports.CfnTransitGatewayRouteTableAssociation=exports.CfnTransitGatewayRouteTable=exports.CfnTransitGatewayRoute=exports.CfnTransitGatewayPeeringAttachment=exports.CfnTransitGatewayMulticastGroupSource=exports.CfnTransitGatewayMulticastGroupMember=exports.CfnTransitGatewayMulticastDomainAssociation=exports.CfnTransitGatewayMulticastDomain=exports.CfnTransitGatewayConnect=exports.CfnTransitGatewayAttachment=exports.CfnTransitGateway=exports.CfnTrafficMirrorTarget=exports.CfnTrafficMirrorSession=exports.CfnTrafficMirrorFilterRule=exports.CfnTrafficMirrorFilter=exports.CfnSubnetRouteTableAssociation=exports.CfnSubnetNetworkAclAssociation=exports.CfnSubnetCidrBlock=exports.CfnSubnet=exports.CfnSpotFleet=exports.CfnSecurityGroupIngress=void 0,exports.CfnVPCBlockPublicAccessOptions=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var cdk=()=>{var tmp=require("../../core");return cdk=()=>tmp,tmp},cfn_parse=()=>{var tmp=require("../../core/lib/helpers-internal");return cfn_parse=()=>tmp,tmp},cdk_errors=()=>{var tmp=require("../../core/lib/errors");return cdk_errors=()=>tmp,tmp};class CfnCapacityReservation extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnCapacityReservationPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnCapacityReservation(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnCapacityReservation.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ec2_CfnCapacityReservationProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnCapacityReservation),error}cdk().requireProperty(props,"instanceCount",this),cdk().requireProperty(props,"instancePlatform",this),cdk().requireProperty(props,"instanceType",this),this.attrAvailabilityZone=cdk().Token.asString(this.getAtt("AvailabilityZone",cdk().ResolutionTypeHint.STRING)),this.attrAvailableInstanceCount=cdk().Token.asNumber(this.getAtt("AvailableInstanceCount",cdk().ResolutionTypeHint.NUMBER)),this.attrCapacityAllocationSet=this.getAtt("CapacityAllocationSet"),this.attrCapacityReservationArn=cdk().Token.asString(this.getAtt("CapacityReservationArn",cdk().ResolutionTypeHint.STRING)),this.attrCapacityReservationFleetId=cdk().Token.asString(this.getAtt("CapacityReservationFleetId",cdk().ResolutionTypeHint.STRING)),this.attrCommitmentInfo=this.getAtt("CommitmentInfo"),this.attrCreateDate=cdk().Token.asString(this.getAtt("CreateDate",cdk().ResolutionTypeHint.STRING)),this.attrDeliveryPreference=cdk().Token.asString(this.getAtt("DeliveryPreference",cdk().ResolutionTypeHint.STRING)),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.attrInstanceType=cdk().Token.asString(this.getAtt("InstanceType",cdk().ResolutionTypeHint.STRING)),this.attrOwnerId=cdk().Token.asString(this.getAtt("OwnerId",cdk().ResolutionTypeHint.STRING)),this.attrReservationType=cdk().Token.asString(this.getAtt("ReservationType",cdk().ResolutionTypeHint.STRING)),this.attrStartDate=cdk().Token.asString(this.getAtt("StartDate",cdk().ResolutionTypeHint.STRING)),this.attrState=cdk().Token.asString(this.getAtt("State",cdk().ResolutionTypeHint.STRING)),this.attrTenancy=cdk().Token.asString(this.getAtt("Tenancy",cdk().ResolutionTypeHint.STRING)),this.attrTotalInstanceCount=cdk().Token.asNumber(this.getAtt("TotalInstanceCount",cdk().ResolutionTypeHint.NUMBER)),this.availabilityZone=props.availabilityZone,this.availabilityZoneId=props.availabilityZoneId,this.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::EC2::CapacityReservation",void 0,{tagPropertyName:"tagSpecifications"}),this.ebsOptimized=props.ebsOptimized,this.endDate=props.endDate,this.endDateType=props.endDateType,this.ephemeralStorage=props.ephemeralStorage,this.instanceCount=props.instanceCount,this.instanceMatchCriteria=props.instanceMatchCriteria,this.instancePlatform=props.instancePlatform,this.instanceType=props.instanceType,this.outPostArn=props.outPostArn,this.placementGroupArn=props.placementGroupArn,this.tagSpecifications=props.tagSpecifications,this.tenancy=props.tenancy,this.unusedReservationBillingOwnerId=props.unusedReservationBillingOwnerId}get cfnProperties(){return{availabilityZone:this.availabilityZone,availabilityZoneId:this.availabilityZoneId,tagSpecifications:this.cdkTagManager.renderTags(this.tagSpecifications),ebsOptimized:this.ebsOptimized,endDate:this.endDate,endDateType:this.endDateType,ephemeralStorage:this.ephemeralStorage,instanceCount:this.instanceCount,instanceMatchCriteria:this.instanceMatchCriteria,instancePlatform:this.instancePlatform,instanceType:this.instanceType,outPostArn:this.outPostArn,placementGroupArn:this.placementGroupArn,tenancy:this.tenancy,unusedReservationBillingOwnerId:this.unusedReservationBillingOwnerId}}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",CfnCapacityReservation.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnCapacityReservationPropsToCloudFormation(props)}}exports.CfnCapacityReservation=CfnCapacityReservation,_a=JSII_RTTI_SYMBOL_1,CfnCapacityReservation[_a]={fqn:"aws-cdk-lib.aws_ec2.CfnCapacityReservation",version:"2.202.0"},CfnCapacityReservation.CFN_RESOURCE_TYPE_NAME="AWS::EC2::CapacityReservation";function CfnCapacityReservationTagSpecificationPropertyValidator(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("resourceType",cdk().validateString)(properties.resourceType)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "TagSpecificationProperty"')}function convertCfnCapacityReservationTagSpecificationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationTagSpecificationPropertyValidator(properties).assertSuccess(),{ResourceType:cdk().stringToCloudFormation(properties.resourceType),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnCapacityReservationTagSpecificationPropertyFromCloudFormation(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("resourceType","ResourceType",properties.ResourceType!=null?cfn_parse().FromCloudFormation.getString(properties.ResourceType):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}function CfnCapacityReservationCapacityAllocationPropertyValidator(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("allocationType",cdk().validateString)(properties.allocationType)),errors.collect(cdk().propertyValidator("count",cdk().validateNumber)(properties.count)),errors.wrap('supplied properties not correct for "CapacityAllocationProperty"')}function convertCfnCapacityReservationCapacityAllocationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationCapacityAllocationPropertyValidator(properties).assertSuccess(),{AllocationType:cdk().stringToCloudFormation(properties.allocationType),Count:cdk().numberToCloudFormation(properties.count)}):properties}function CfnCapacityReservationCapacityAllocationPropertyFromCloudFormation(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("allocationType","AllocationType",properties.AllocationType!=null?cfn_parse().FromCloudFormation.getString(properties.AllocationType):void 0),ret.addPropertyResult("count","Count",properties.Count!=null?cfn_parse().FromCloudFormation.getNumber(properties.Count):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnCapacityReservationCommitmentInfoPropertyValidator(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("commitmentEndDate",cdk().validateString)(properties.commitmentEndDate)),errors.collect(cdk().propertyValidator("committedInstanceCount",cdk().validateNumber)(properties.committedInstanceCount)),errors.wrap('supplied properties not correct for "CommitmentInfoProperty"')}function convertCfnCapacityReservationCommitmentInfoPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationCommitmentInfoPropertyValidator(properties).assertSuccess(),{CommitmentEndDate:cdk().stringToCloudFormation(properties.commitmentEndDate),CommittedInstanceCount:cdk().numberToCloudFormation(properties.committedInstanceCount)}):properties}function CfnCapacityReservationCommitmentInfoPropertyFromCloudFormation(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("commitmentEndDate","CommitmentEndDate",properties.CommitmentEndDate!=null?cfn_parse().FromCloudFormation.getString(properties.CommitmentEndDate):void 0),ret.addPropertyResult("committedInstanceCount","CommittedInstanceCount",properties.CommittedInstanceCount!=null?cfn_parse().FromCloudFormation.getNumber(properties.CommittedInstanceCount):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnCapacityReservationPropsValidator(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("availabilityZone",cdk().validateString)(properties.availabilityZone)),errors.collect(cdk().propertyValidator("availabilityZoneId",cdk().validateString)(properties.availabilityZoneId)),errors.collect(cdk().propertyValidator("ebsOptimized",cdk().validateBoolean)(properties.ebsOptimized)),errors.collect(cdk().propertyValidator("endDate",cdk().validateString)(properties.endDate)),errors.collect(cdk().propertyValidator("endDateType",cdk().validateString)(properties.endDateType)),errors.collect(cdk().propertyValidator("ephemeralStorage",cdk().validateBoolean)(properties.ephemeralStorage)),errors.collect(cdk().propertyValidator("instanceCount",cdk().requiredValidator)(properties.instanceCount)),errors.collect(cdk().propertyValidator("instanceCount",cdk().validateNumber)(properties.instanceCount)),errors.collect(cdk().propertyValidator("instanceMatchCriteria",cdk().validateString)(properties.instanceMatchCriteria)),errors.collect(cdk().propertyValidator("instancePlatform",cdk().requiredValidator)(properties.instancePlatform)),errors.collect(cdk().propertyValidator("instancePlatform",cdk().validateString)(properties.instancePlatform)),errors.collect(cdk().propertyValidator("instanceType",cdk().requiredValidator)(properties.instanceType)),errors.collect(cdk().propertyValidator("instanceType",cdk().validateString)(properties.instanceType)),errors.collect(cdk().propertyValidator("outPostArn",cdk().validateString)(properties.outPostArn)),errors.collect(cdk().propertyValidator("placementGroupArn",cdk().validateString)(properties.placementGroupArn)),errors.collect(cdk().propertyValidator("tagSpecifications",cdk().listValidator(CfnCapacityReservationTagSpecificationPropertyValidator))(properties.tagSpecifications)),errors.collect(cdk().propertyValidator("tenancy",cdk().validateString)(properties.tenancy)),errors.collect(cdk().propertyValidator("unusedReservationBillingOwnerId",cdk().validateString)(properties.unusedReservationBillingOwnerId)),errors.wrap('supplied properties not correct for "CfnCapacityReservationProps"')}function convertCfnCapacityReservationPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationPropsValidator(properties).assertSuccess(),{AvailabilityZone:cdk().stringToCloudFormation(properties.availabilityZone),AvailabilityZoneId:cdk().stringToCloudFormation(properties.availabilityZoneId),EbsOptimized:cdk().booleanToCloudFormation(properties.ebsOptimized),EndDate:cdk().stringToCloudFormation(properties.endDate),EndDateType:cdk().stringToCloudFormation(properties.endDateType),EphemeralStorage:cdk().booleanToCloudFormation(properties.ephemeralStorage),InstanceCount:cdk().numberToCloudFormation(properties.instanceCount),InstanceMatchCriteria:cdk().stringToCloudFormation(properties.instanceMatchCriteria),InstancePlatform:cdk().stringToCloudFormation(properties.instancePlatform),InstanceType:cdk().stringToCloudFormation(properties.instanceType),OutPostArn:cdk().stringToCloudFormation(properties.outPostArn),PlacementGroupArn:cdk().stringToCloudFormation(properties.placementGroupArn),TagSpecifications:cdk().listMapper(convertCfnCapacityReservationTagSpecificationPropertyToCloudFormation)(properties.tagSpecifications),Tenancy:cdk().stringToCloudFormation(properties.tenancy),UnusedReservationBillingOwnerId:cdk().stringToCloudFormation(properties.unusedReservationBillingOwnerId)}):properties}function CfnCapacityReservationPropsFromCloudFormation(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("availabilityZone","AvailabilityZone",properties.AvailabilityZone!=null?cfn_parse().FromCloudFormation.getString(properties.AvailabilityZone):void 0),ret.addPropertyResult("availabilityZoneId","AvailabilityZoneId",properties.AvailabilityZoneId!=null?cfn_parse().FromCloudFormation.getString(properties.AvailabilityZoneId):void 0),ret.addPropertyResult("ebsOptimized","EbsOptimized",properties.EbsOptimized!=null?cfn_parse().FromCloudFormation.getBoolean(properties.EbsOptimized):void 0),ret.addPropertyResult("endDate","EndDate",properties.EndDate!=null?cfn_parse().FromCloudFormation.getString(properties.EndDate):void 0),ret.addPropertyResult("endDateType","EndDateType",properties.EndDateType!=null?cfn_parse().FromCloudFormation.getString(properties.EndDateType):void 0),ret.addPropertyResult("ephemeralStorage","EphemeralStorage",properties.EphemeralStorage!=null?cfn_parse().FromCloudFormation.getBoolean(properties.EphemeralStorage):void 0),ret.addPropertyResult("instanceCount","InstanceCount",properties.InstanceCount!=null?cfn_parse().FromCloudFormation.getNumber(properties.InstanceCount):void 0),ret.addPropertyResult("instanceMatchCriteria","InstanceMatchCriteria",properties.InstanceMatchCriteria!=null?cfn_parse().FromCloudFormation.getString(properties.InstanceMatchCriteria):void 0),ret.addPropertyResult("instancePlatform","InstancePlatform",properties.InstancePlatform!=null?cfn_parse().FromCloudFormation.getString(properties.InstancePlatform):void 0),ret.addPropertyResult("instanceType","InstanceType",properties.InstanceType!=null?cfn_parse().FromCloudFormation.getString(properties.InstanceType):void 0),ret.addPropertyResult("outPostArn","OutPostArn",properties.OutPostArn!=null?cfn_parse().FromCloudFormation.getString(properties.OutPostArn):void 0),ret.addPropertyResult("placementGroupArn","PlacementGroupArn",properties.PlacementGroupArn!=null?cfn_parse().FromCloudFormation.getString(properties.PlacementGroupArn):void 0),ret.addPropertyResult("tagSpecifications","TagSpecifications",properties.TagSpecifications!=null?cfn_parse().FromCloudFormation.getArray(CfnCapacityReservationTagSpecificationPropertyFromCloudFormation)(properties.TagSpecifications):void 0),ret.addPropertyResult("tenancy","Tenancy",properties.Tenancy!=null?cfn_parse().FromCloudFormation.getString(properties.Tenancy):void 0),ret.addPropertyResult("unusedReservationBillingOwnerId","UnusedReservationBillingOwnerId",properties.UnusedReservationBillingOwnerId!=null?cfn_parse().FromCloudFormation.getString(properties.UnusedReservationBillingOwnerId):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnCapacityReservationFleet extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnCapacityReservationFleetPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnCapacityReservationFleet(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props={}){super(scope,id,{type:CfnCapacityReservationFleet.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ec2_CfnCapacityReservationFleetProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnCapacityReservationFleet),error}this.attrCapacityReservationFleetId=cdk().Token.asString(this.getAtt("CapacityReservationFleetId",cdk().ResolutionTypeHint.STRING)),this.allocationStrategy=props.allocationStrategy,this.endDate=props.endDate,this.instanceMatchCriteria=props.instanceMatchCriteria,this.instanceTypeSpecifications=props.instanceTypeSpecifications,this.noRemoveEndDate=props.noRemoveEndDate,this.removeEndDate=props.removeEndDate,this.tagSpecifications=props.tagSpecifications,this.tenancy=props.tenancy,this.totalTargetCapacity=props.totalTargetCapacity}get cfnProperties(){return{allocationStrategy:this.allocationStrategy,endDate:this.endDate,instanceMatchCriteria:this.instanceMatchCriteria,instanceTypeSpecifications:this.instanceTypeSpecifications,noRemoveEndDate:this.noRemoveEndDate,removeEndDate:this.removeEndDate,tagSpecifications:this.tagSpecifications,tenancy:this.tenancy,totalTargetCapacity:this.totalTargetCapacity}}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",CfnCapacityReservationFleet.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnCapacityReservationFleetPropsToCloudFormation(props)}}exports.CfnCapacityReservationFleet=CfnCapacityReservationFleet,_b=JSII_RTTI_SYMBOL_1,CfnCapacityReservationFleet[_b]={fqn:"aws-cdk-lib.aws_ec2.CfnCapacityReservationFleet",version:"2.202.0"},CfnCapacityReservationFleet.CFN_RESOURCE_TYPE_NAME="AWS::EC2::CapacityReservationFleet";function CfnCapacityReservationFleetTagSpecificationPropertyValidator(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("resourceType",cdk().validateString)(properties.resourceType)),errors.collect(cdk().propertyValidator("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.wrap('supplied properties not correct for "TagSpecificationProperty"')}function convertCfnCapacityReservationFleetTagSpecificationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationFleetTagSpecificationPropertyValidator(properties).assertSuccess(),{ResourceType:cdk().stringToCloudFormation(properties.resourceType),Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags)}):properties}function CfnCapacityReservationFleetTagSpecificationPropertyFromCloudFormation(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("resourceType","ResourceType",properties.ResourceType!=null?cfn_parse().FromCloudFormation.getString(properties.ResourceType):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}function CfnCapacityReservationFleetInstanceTypeSpecificationPropertyValidator(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("availabilityZone",cdk().validateString)(properties.availabilityZone)),errors.collect(cdk().propertyValidator("availabilityZoneId",cdk().validateString)(properties.availabilityZoneId)),errors.collect(cdk().propertyValidator("ebsOptimized",cdk().validateBoolean)(properties.ebsOptimized)),errors.collect(cdk().propertyValidator("instancePlatform",cdk().validateString)(properties.instancePlatform)),errors.collect(cdk().propertyValidator("instanceType",cdk().validateString)(properties.instanceType)),errors.collect(cdk().propertyValidator("priority",cdk().validateNumber)(properties.priority)),errors.collect(cdk().propertyValidator("weight",cdk().validateNumber)(properties.weight)),errors.wrap('supplied properties not correct for "InstanceTypeSpecificationProperty"')}function convertCfnCapacityReservationFleetInstanceTypeSpecificationPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationFleetInstanceTypeSpecificationPropertyValidator(properties).assertSuccess(),{AvailabilityZone:cdk().stringToCloudFormation(properties.availabilityZone),AvailabilityZoneId:cdk().stringToCloudFormation(properties.availabilityZoneId),EbsOptimized:cdk().booleanToCloudFormation(properties.ebsOptimized),InstancePlatform:cdk().stringToCloudFormation(properties.instancePlatform),InstanceType:cdk().stringToCloudFormation(properties.instanceType),Priority:cdk().numberToCloudFormation(properties.priority),Weight:cdk().numberToCloudFormation(properties.weight)}):properties}function CfnCapacityReservationFleetInstanceTypeSpecificationPropertyFromCloudFormation(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("availabilityZone","AvailabilityZone",properties.AvailabilityZone!=null?cfn_parse().FromCloudFormation.getString(properties.AvailabilityZone):void 0),ret.addPropertyResult("availabilityZoneId","AvailabilityZoneId",properties.AvailabilityZoneId!=null?cfn_parse().FromCloudFormation.getString(properties.AvailabilityZoneId):void 0),ret.addPropertyResult("ebsOptimized","EbsOptimized",properties.EbsOptimized!=null?cfn_parse().FromCloudFormation.getBoolean(properties.EbsOptimized):void 0),ret.addPropertyResult("instancePlatform","InstancePlatform",properties.InstancePlatform!=null?cfn_parse().FromCloudFormation.getString(properties.InstancePlatform):void 0),ret.addPropertyResult("instanceType","InstanceType",properties.InstanceType!=null?cfn_parse().FromCloudFormation.getString(properties.InstanceType):void 0),ret.addPropertyResult("priority","Priority",properties.Priority!=null?cfn_parse().FromCloudFormation.getNumber(properties.Priority):void 0),ret.addPropertyResult("weight","Weight",properties.Weight!=null?cfn_parse().FromCloudFormation.getNumber(properties.Weight):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnCapacityReservationFleetPropsValidator(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("allocationStrategy",cdk().validateString)(properties.allocationStrategy)),errors.collect(cdk().propertyValidator("endDate",cdk().validateString)(properties.endDate)),errors.collect(cdk().propertyValidator("instanceMatchCriteria",cdk().validateString)(properties.instanceMatchCriteria)),errors.collect(cdk().propertyValidator("instanceTypeSpecifications",cdk().listValidator(CfnCapacityReservationFleetInstanceTypeSpecificationPropertyValidator))(properties.instanceTypeSpecifications)),errors.collect(cdk().propertyValidator("noRemoveEndDate",cdk().validateBoolean)(properties.noRemoveEndDate)),errors.collect(cdk().propertyValidator("removeEndDate",cdk().validateBoolean)(properties.removeEndDate)),errors.collect(cdk().propertyValidator("tagSpecifications",cdk().listValidator(CfnCapacityReservationFleetTagSpecificationPropertyValidator))(properties.tagSpecifications)),errors.collect(cdk().propertyValidator("tenancy",cdk().validateString)(properties.tenancy)),errors.collect(cdk().propertyValidator("totalTargetCapacity",cdk().validateNumber)(properties.totalTargetCapacity)),errors.wrap('supplied properties not correct for "CfnCapacityReservationFleetProps"')}function convertCfnCapacityReservationFleetPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCapacityReservationFleetPropsValidator(properties).assertSuccess(),{AllocationStrategy:cdk().stringToCloudFormation(properties.allocationStrategy),EndDate:cdk().stringToCloudFormation(properties.endDate),InstanceMatchCriteria:cdk().stringToCloudFormation(properties.instanceMatchCriteria),InstanceTypeSpecifications:cdk().listMapper(convertCfnCapacityReservationFleetInstanceTypeSpecificationPropertyToCloudFormation)(properties.instanceTypeSpecifications),NoRemoveEndDate:cdk().booleanToCloudFormation(properties.noRemoveEndDate),RemoveEndDate:cdk().booleanToCloudFormation(properties.removeEndDate),TagSpecifications:cdk().listMapper(convertCfnCapacityReservationFleetTagSpecificationPropertyToCloudFormation)(properties.tagSpecifications),Tenancy:cdk().stringToCloudFormation(properties.tenancy),TotalTargetCapacity:cdk().numberToCloudFormation(properties.totalTargetCapacity)}):properties}function CfnCapacityReservationFleetPropsFromCloudFormation(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("allocationStrategy","AllocationStrategy",properties.AllocationStrategy!=null?cfn_parse().FromCloudFormation.getString(properties.AllocationStrategy):void 0),ret.addPropertyResult("endDate","EndDate",properties.EndDate!=null?cfn_parse().FromCloudFormation.getString(properties.EndDate):void 0),ret.addPropertyResult("instanceMatchCriteria","InstanceMatchCriteria",properties.InstanceMatchCriteria!=null?cfn_parse().FromCloudFormation.getString(properties.InstanceMatchCriteria):void 0),ret.addPropertyResult("instanceTypeSpecifications","InstanceTypeSpecifications",properties.InstanceTypeSpecifications!=null?cfn_parse().FromCloudFormation.getArray(CfnCapacityReservationFleetInstanceTypeSpecificationPropertyFromCloudFormation)(properties.InstanceTypeSpecifications):void 0),ret.addPropertyResult("noRemoveEndDate","NoRemoveEndDate",properties.NoRemoveEndDate!=null?cfn_parse().FromCloudFormation.getBoolean(properties.NoRemoveEndDate):void 0),ret.addPropertyResult("removeEndDate","RemoveEndDate",properties.RemoveEndDate!=null?cfn_parse().FromCloudFormation.getBoolean(properties.RemoveEndDate):void 0),ret.addPropertyResult("tagSpecifications","TagSpecifications",properties.TagSpecifications!=null?cfn_parse().FromCloudFormation.getArray(CfnCapacityReservationFleetTagSpecificationPropertyFromCloudFormation)(properties.TagSpecifications):void 0),ret.addPropertyResult("tenancy","Tenancy",properties.Tenancy!=null?cfn_parse().FromCloudFormation.getString(properties.Tenancy):void 0),ret.addPropertyResult("totalTargetCapacity","TotalTargetCapacity",properties.TotalTargetCapacity!=null?cfn_parse().FromCloudFormation.getNumber(properties.TotalTargetCapacity):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnCarrierGateway extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnCarrierGatewayPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnCarrierGateway(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnCarrierGateway.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ec2_CfnCarrierGatewayProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnCarrierGateway),error}cdk().requireProperty(props,"vpcId",this),this.attrCarrierGatewayId=cdk().Token.asString(this.getAtt("CarrierGatewayId",cdk().ResolutionTypeHint.STRING)),this.attrOwnerId=cdk().Token.asString(this.getAtt("OwnerId",cdk().ResolutionTypeHint.STRING)),this.attrState=cdk().Token.asString(this.getAtt("State",cdk().ResolutionTypeHint.STRING)),this.tags=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::EC2::CarrierGateway",props.tags,{tagPropertyName:"tags"}),this.tagsRaw=props.tags,this.vpcId=props.vpcId}get cfnProperties(){return{tags:this.tags.renderTags(),vpcId:this.vpcId}}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",CfnCarrierGateway.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnCarrierGatewayPropsToCloudFormation(props)}}exports.CfnCarrierGateway=CfnCarrierGateway,_c=JSII_RTTI_SYMBOL_1,CfnCarrierGateway[_c]={fqn:"aws-cdk-lib.aws_ec2.CfnCarrierGateway",version:"2.202.0"},CfnCarrierGateway.CFN_RESOURCE_TYPE_NAME="AWS::EC2::CarrierGateway";function CfnCarrierGatewayPropsValidator(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("tags",cdk().listValidator(cdk().validateCfnTag))(properties.tags)),errors.collect(cdk().propertyValidator("vpcId",cdk().requiredValidator)(properties.vpcId)),errors.collect(cdk().propertyValidator("vpcId",cdk().validateString)(properties.vpcId)),errors.wrap('supplied properties not correct for "CfnCarrierGatewayProps"')}function convertCfnCarrierGatewayPropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnCarrierGatewayPropsValidator(properties).assertSuccess(),{Tags:cdk().listMapper(cdk().cfnTagToCloudFormation)(properties.tags),VpcId:cdk().stringToCloudFormation(properties.vpcId)}):properties}function CfnCarrierGatewayPropsFromCloudFormation(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("tags","Tags",properties.Tags!=null?cfn_parse().FromCloudFormation.getArray(cfn_parse().FromCloudFormation.getCfnTag)(properties.Tags):void 0),ret.addPropertyResult("vpcId","VpcId",properties.VpcId!=null?cfn_parse().FromCloudFormation.getString(properties.VpcId):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnClientVpnAuthorizationRule extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnClientVpnAuthorizationRulePropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnClientVpnAuthorizationRule(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnClientVpnAuthorizationRule.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ec2_CfnClientVpnAuthorizationRuleProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnClientVpnAuthorizationRule),error}cdk().requireProperty(props,"clientVpnEndpointId",this),cdk().requireProperty(props,"targetNetworkCidr",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.accessGroupId=props.accessGroupId,this.authorizeAllGroups=props.authorizeAllGroups,this.clientVpnEndpointId=props.clientVpnEndpointId,this.description=props.description,this.targetNetworkCidr=props.targetNetworkCidr}get cfnProperties(){return{accessGroupId:this.accessGroupId,authorizeAllGroups:this.authorizeAllGroups,clientVpnEndpointId:this.clientVpnEndpointId,description:this.description,targetNetworkCidr:this.targetNetworkCidr}}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",CfnClientVpnAuthorizationRule.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnClientVpnAuthorizationRulePropsToCloudFormation(props)}}exports.CfnClientVpnAuthorizationRule=CfnClientVpnAuthorizationRule,_d=JSII_RTTI_SYMBOL_1,CfnClientVpnAuthorizationRule[_d]={fqn:"aws-cdk-lib.aws_ec2.CfnClientVpnAuthorizationRule",version:"2.202.0"},CfnClientVpnAuthorizationRule.CFN_RESOURCE_TYPE_NAME="AWS::EC2::ClientVpnAuthorizationRule";function CfnClientVpnAuthorizationRulePropsValidator(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("accessGroupId",cdk().validateString)(properties.accessGroupId)),errors.collect(cdk().propertyValidator("authorizeAllGroups",cdk().validateBoolean)(properties.authorizeAllGroups)),errors.collect(cdk().propertyValidator("clientVpnEndpointId",cdk().requiredValidator)(properties.clientVpnEndpointId)),errors.collect(cdk().propertyValidator("clientVpnEndpointId",cdk().validateString)(properties.clientVpnEndpointId)),errors.collect(cdk().propertyValidator("description",cdk().validateString)(properties.description)),errors.collect(cdk().propertyValidator("targetNetworkCidr",cdk().requiredValidator)(properties.targetNetworkCidr)),errors.collect(cdk().propertyValidator("targetNetworkCidr",cdk().validateString)(properties.targetNetworkCidr)),errors.wrap('supplied properties not correct for "CfnClientVpnAuthorizationRuleProps"')}function convertCfnClientVpnAuthorizationRulePropsToCloudFormation(properties){return cdk().canInspect(properties)?(CfnClientVpnAuthorizationRulePropsValidator(properties).assertSuccess(),{AccessGroupId:cdk().stringToCloudFormation(properties.accessGroupId),AuthorizeAllGroups:cdk().booleanToCloudFormation(properties.authorizeAllGroups),ClientVpnEndpointId:cdk().stringToCloudFormation(properties.clientVpnEndpointId),Description:cdk().stringToCloudFormation(properties.description),TargetNetworkCidr:cdk().stringToCloudFormation(properties.targetNetworkCidr)}):properties}function CfnClientVpnAuthorizationRulePropsFromCloudFormation(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("accessGroupId","AccessGroupId",properties.AccessGroupId!=null?cfn_parse().FromCloudFormation.getString(properties.AccessGroupId):void 0),ret.addPropertyResult("authorizeAllGroups","AuthorizeAllGroups",properties.AuthorizeAllGroups!=null?cfn_parse().FromCloudFormation.getBoolean(properties.AuthorizeAllGroups):void 0),ret.addPropertyResult("clientVpnEndpointId","ClientVpnEndpointId",properties.ClientVpnEndpointId!=null?cfn_parse().FromCloudFormation.getString(properties.ClientVpnEndpointId):void 0),ret.addPropertyResult("description","Description",properties.Description!=null?cfn_parse().FromCloudFormation.getString(properties.Description):void 0),ret.addPropertyResult("targetNetworkCidr","TargetNetworkCidr",properties.TargetNetworkCidr!=null?cfn_parse().FromCloudFormation.getString(properties.TargetNetworkCidr):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}class CfnClientVpnEndpoint extends cdk().CfnResource{static _fromCloudFormation(scope,id,resourceAttributes,options){resourceAttributes=resourceAttributes||{};const resourceProperties=options.parser.parseValue(resourceAttributes.Properties),propsResult=CfnClientVpnEndpointPropsFromCloudFormation(resourceProperties);if(cdk().isResolvableObject(propsResult.value))throw new(cdk_errors()).ValidationError("Unexpected IResolvable",scope);const ret=new CfnClientVpnEndpoint(scope,id,propsResult.value);for(const[propKey,propVal]of Object.entries(propsResult.extraProperties))ret.addPropertyOverride(propKey,propVal);return options.parser.handleAttributes(ret,resourceAttributes,id),ret}constructor(scope,id,props){super(scope,id,{type:CfnClientVpnEndpoint.CFN_RESOURCE_TYPE_NAME,properties:props});try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ec2_CfnClientVpnEndpointProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,CfnClientVpnEndpoint),error}cdk().requireProperty(props,"authenticationOptions",this),cdk().requireProperty(props,"clientCidrBlock",this),cdk().requireProperty(props,"connectionLogOptions",this),cdk().requireProperty(props,"serverCertificateArn",this),this.attrId=cdk().Token.asString(this.getAtt("Id",cdk().ResolutionTypeHint.STRING)),this.authenticationOptions=props.authenticationOptions,this.clientCidrBlock=props.clientCidrBlock,this.clientConnectOptions=props.clientConnectOptions,this.clientLoginBannerOptions=props.clientLoginBannerOptions,this.clientRouteEnforcementOptions=props.clientRouteEnforcementOptions,this.connectionLogOptions=props.connectionLogOptions,this.description=props.description,this.disconnectOnSessionTimeout=props.disconnectOnSessionTimeout,this.dnsServers=props.dnsServers,this.securityGroupIds=props.securityGroupIds,this.selfServicePortal=props.selfServicePortal,this.serverCertificateArn=props.serverCertificateArn,this.sessionTimeoutHours=props.sessionTimeoutHours,this.splitTunnel=props.splitTunnel,this.tagSpecifications=props.tagSpecifications,this.transportProtocol=props.transportProtocol,this.vpcId=props.vpcId,this.vpnPort=props.vpnPort}get cfnProperties(){return{authenticationOptions:this.authenticationOptions,clientCidrBlock:this.clientCidrBlock,clientConnectOptions:this.clientConnectOptions,clientLoginBannerOptions:this.clientLoginBannerOptions,clientRouteEnforcementOptions:this.clientRouteEnforcementOptions,connectionLogOptions:this.connectionLogOptions,description:this.description,disconnectOnSessionTimeout:this.disconnectOnSessionTimeout,dnsServers:this.dnsServers,securityGroupIds:this.securityGroupIds,selfServicePortal:this.selfServicePortal,serverCertificateArn:this.serverCertificateArn,sessionTimeoutHours:this.sessionTimeoutHours,splitTunnel:this.splitTunnel,tagSpecifications:this.tagSpecifications,transportProtocol:this.transportProtocol,vpcId:this.vpcId,vpnPort:this.vpnPort}}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",CfnClientVpnEndpoint.CFN_RESOURCE_TYPE_NAME),inspector.addAttribute("aws:cdk:cloudformation:props",this.cfnProperties)}renderProperties(props){return convertCfnClientVpnEndpointPropsToCloudFormation(props)}}exports.CfnClientVpnEndpoint=CfnClientVpnEndpoint,_e=JSII_RTTI_SYMBOL_1,CfnClientVpnEndpoint[_e]={fqn:"aws-cdk-lib.aws_ec2.CfnClientVpnEndpoint",version:"2.202.0"},CfnClientVpnEndpoint.CFN_RESOURCE_TYPE_NAME="AWS::EC2::ClientVpnEndpoint";function CfnClientVpnEndpointClientConnectOptionsPropertyValidator(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("enabled",cdk().requiredValidator)(properties.enabled)),errors.collect(cdk().propertyValidator("enabled",cdk().validateBoolean)(properties.enabled)),errors.collect(cdk().propertyValidator("lambdaFunctionArn",cdk().validateString)(properties.lambdaFunctionArn)),errors.wrap('supplied properties not correct for "ClientConnectOptionsProperty"')}function convertCfnClientVpnEndpointClientConnectOptionsPropertyToCloudFormation(properties){return cdk().canInspect(properties)?(CfnClientVpnEndpointClientConnectOptionsPropertyValidator(properties).assertSuccess(),{Enabled:cdk().booleanToCloudFormation(properties.enabled),LambdaFunctionArn:cdk().stringToCloudFormation(properties.lambdaFunctionArn)}):properties}function CfnClientVpnEndpointClientConnectOptionsPropertyFromCloudFormation(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("enabled","Enabled",properties.Enabled!=null?cfn_parse().FromCloudFormation.getBoolean(properties.Enabled):void 0),ret.addPropertyResult("lambdaFunctionArn","LambdaFunctionArn",properties.LambdaFunctionArn!=null?cfn_parse().FromCloudFormation.getString(properties.LambdaFunctionArn):void 0),ret.addUnrecognizedPropertiesAsExtra(properties),ret}function CfnClientVpnEndpointTagSpecificationPropertyValidator(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("resourceType",cdk().requiredValidator)(properties.resourceType)),errors.collect(cdk().propertyValidator("resourceType",cdk().validateString)(properties.resourceType)),errors.collect(cdk().propertyValidator("tags",cdk().requiredValidator)(properties.tags)),errors.collect(cdk().propertyValidator("tags",cdk().l