UNPKG

aws-cdk-lib

Version:

Version 2 of the AWS Cloud Development Kit library

1 lines 1.39 MB
"use strict";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.CfnRouteServerPeer=exports.CfnRouteServerEndpoint=exports.CfnRouteServerAssociation=exports.CfnRouteServer=exports.CfnLocalGatewayVirtualInterfaceGroup=exports.CfnLocalGatewayVirtualInterface=exports.CfnIpPoolRouteTableAssociation=exports.CfnCapacityManagerDataExport=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.CfnVPNConcentrator=exports.CfnVPCEncryptionControl=exports.CfnVPCBlockPublicAccessOptions=exports.CfnVPCBlockPublicAccessExclusion=exports.CfnTransitGatewayMeteringPolicyEntry=exports.CfnTransitGatewayMeteringPolicy=exports.CfnTransitGatewayConnectPeer=exports.CfnSnapshotBlockPublicAccess=exports.CfnSecurityGroupVpcAssociation=exports.CfnRouteServerPropagation=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 CfnCapacityReservation extends cdk().CfnResource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_ec2.CfnCapacityReservation",version:"2.233.0"};static CFN_RESOURCE_TYPE_NAME="AWS::EC2::CapacityReservation";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}static isCfnCapacityReservation(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnCapacityReservation.CFN_RESOURCE_TYPE_NAME}static fromCapacityReservationArn(scope,id,arn){class Import extends cdk().Resource{capacityReservationRef;constructor(scope2,id2,arn2){super(scope2,id2,{environmentFromArn:arn2});const variables=new(cfn_parse()).TemplateString("arn:${Partition}:ec2:${Region}:${Account}:capacity-reservation/${CapacityReservationId}").parse(arn2);this.capacityReservationRef={capacityReservationId:variables.CapacityReservationId,capacityReservationArn:arn2}}}return new Import(scope,id,arn)}static fromCapacityReservationId(scope,id,capacityReservationId){class Import extends cdk().Resource{capacityReservationRef;constructor(scope2,id2,capacityReservationId2){const arn=new(cfn_parse()).TemplateString("arn:${Partition}:ec2:${Region}:${Account}:capacity-reservation/${CapacityReservationId}").interpolate({Partition:cdk().Stack.of(scope2).partition,Region:cdk().Stack.of(scope2).region,Account:cdk().Stack.of(scope2).account,CapacityReservationId:capacityReservationId2});super(scope2,id2,{environmentFromArn:arn}),this.capacityReservationRef={capacityReservationId:capacityReservationId2,capacityReservationArn:arn}}}return new Import(scope,id,capacityReservationId)}static arnForCapacityReservation(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_ec2_ICapacityReservationRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForCapacityReservation),error}return resource.capacityReservationRef.capacityReservationArn}attrAvailabilityZone;attrAvailableInstanceCount;attrCapacityAllocationSet;attrCapacityReservationArn;attrCapacityReservationFleetId;attrCommitmentInfo;attrCreateDate;attrDeliveryPreference;attrId;attrInstanceType;attrOwnerId;attrReservationType;attrStartDate;attrState;attrTenancy;attrTotalInstanceCount;availabilityZone;availabilityZoneId;cdkTagManager;ebsOptimized;endDate;endDateType;ephemeralStorage;instanceCount;instanceMatchCriteria;instancePlatform;instanceType;outPostArn;placementGroupArn;tagSpecifications;tenancy;unusedReservationBillingOwnerId;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 capacityReservationRef(){return{capacityReservationId:this.ref,capacityReservationArn:this.attrCapacityReservationArn}}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;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[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_ec2.CfnCapacityReservationFleet",version:"2.233.0"};static CFN_RESOURCE_TYPE_NAME="AWS::EC2::CapacityReservationFleet";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}static isCfnCapacityReservationFleet(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnCapacityReservationFleet.CFN_RESOURCE_TYPE_NAME}static fromCapacityReservationFleetId(scope,id,capacityReservationFleetId){class Import extends cdk().Resource{capacityReservationFleetRef;constructor(scope2,id2,capacityReservationFleetId2){super(scope2,id2),this.capacityReservationFleetRef={capacityReservationFleetId:capacityReservationFleetId2}}}return new Import(scope,id,capacityReservationFleetId)}static arnForCapacityReservationFleet(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_ec2_ICapacityReservationFleetRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForCapacityReservationFleet),error}return new(cfn_parse()).TemplateString("arn:${Partition}:ec2:${Region}:${Account}:capacity-reservation-fleet/${CapacityReservationFleetId}").interpolate({Partition:cdk().Stack.of(resource).partition,Region:cdk().Stack.of(resource).region,Account:cdk().Stack.of(resource).account,CapacityReservationFleetId:resource.capacityReservationFleetRef.capacityReservationFleetId})}attrCapacityReservationFleetId;allocationStrategy;cdkTagManager;endDate;instanceMatchCriteria;instanceTypeSpecifications;noRemoveEndDate;removeEndDate;tagSpecifications;tenancy;totalTargetCapacity;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.cdkTagManager=new(cdk()).TagManager(cdk().TagType.STANDARD,"AWS::EC2::CapacityReservationFleet",void 0,{tagPropertyName:"tagSpecifications"}),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 capacityReservationFleetRef(){return{capacityReservationFleetId:this.ref}}get cfnProperties(){return{allocationStrategy:this.allocationStrategy,tagSpecifications:this.cdkTagManager.renderTags(this.tagSpecifications),endDate:this.endDate,instanceMatchCriteria:this.instanceMatchCriteria,instanceTypeSpecifications:this.instanceTypeSpecifications,noRemoveEndDate:this.noRemoveEndDate,removeEndDate:this.removeEndDate,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;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[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_ec2.CfnCarrierGateway",version:"2.233.0"};static CFN_RESOURCE_TYPE_NAME="AWS::EC2::CarrierGateway";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}static isCfnCarrierGateway(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnCarrierGateway.CFN_RESOURCE_TYPE_NAME}static fromCarrierGatewayId(scope,id,carrierGatewayId){class Import extends cdk().Resource{carrierGatewayRef;constructor(scope2,id2,carrierGatewayId2){super(scope2,id2),this.carrierGatewayRef={carrierGatewayId:carrierGatewayId2}}}return new Import(scope,id,carrierGatewayId)}static arnForCarrierGateway(resource){try{jsiiDeprecationWarnings().aws_cdk_lib_interfaces_aws_ec2_ICarrierGatewayRef(resource)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.arnForCarrierGateway),error}return new(cfn_parse()).TemplateString("arn:${Partition}:ec2:${Region}:${Account}:carrier-gateway/${CarrierGatewayId}").interpolate({Partition:cdk().Stack.of(resource).partition,Region:cdk().Stack.of(resource).region,Account:cdk().Stack.of(resource).account,CarrierGatewayId:resource.carrierGatewayRef.carrierGatewayId})}attrCarrierGatewayId;attrOwnerId;attrState;tags;tagsRaw;vpcId;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?.vpcRef?.vpcId??cdk().ensureStringOrUndefined(props.vpcId,"vpcId","ec2.IVPCRef | string")}get carrierGatewayRef(){return{carrierGatewayId:this.ref}}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;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[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_ec2.CfnClientVpnAuthorizationRule",version:"2.233.0"};static CFN_RESOURCE_TYPE_NAME="AWS::EC2::ClientVpnAuthorizationRule";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}static isCfnClientVpnAuthorizationRule(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnClientVpnAuthorizationRule.CFN_RESOURCE_TYPE_NAME}attrId;accessGroupId;authorizeAllGroups;clientVpnEndpointId;description;targetNetworkCidr;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 clientVpnAuthorizationRuleRef(){return{clientVpnAuthorizationRuleId:this.ref}}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;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[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_ec2.CfnClientVpnEndpoint",version:"2.233.0"};static CFN_RESOURCE_TYPE_NAME="AWS::EC2::ClientVpnEndpoint";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}static isCfnClientVpnEndpoint(x){return cdk().CfnResource.isCfnResource(x)&&x.cfnResourceType===CfnClientVpnEndpoin