"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
    var ownKeys = function(o) {
        ownKeys = Object.getOwnPropertyNames || function (o) {
            var ar = [];
            for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
            return ar;
        };
        return ownKeys(o);
    };
    return function (mod) {
        if (mod && mod.__esModule) return mod;
        var result = {};
        if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
        __setModuleDefault(result, mod);
        return result;
    };
})();
Object.defineProperty(exports, "__esModule", { value: true });
exports.CfnCapacityProviderPropsMixin = exports.CfnVersionPropsMixin = exports.CfnUrlPropsMixin = exports.CfnPermissionPropsMixin = exports.CfnLayerVersionPermissionPropsMixin = exports.CfnLayerVersionPropsMixin = exports.CfnFunctionPropsMixin = exports.CfnEventSourceMappingPropsMixin = exports.CfnEventInvokeConfigPropsMixin = exports.CfnCodeSigningConfigPropsMixin = exports.CfnAliasPropsMixin = void 0;
const jsiiDeprecationWarnings = require("../../../.warnings.jsii.js");
const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
/* eslint-disable @stylistic/max-len, eol-last */
const cdk = __importStar(require("aws-cdk-lib/core"));
const service = __importStar(require("aws-cdk-lib/aws-lambda"));
/**
 * The `AWS::Lambda::Alias` resource creates an [alias](https://docs.aws.amazon.com/lambda/latest/dg/configuration-aliases.html) for a Lambda function version. Use aliases to provide clients with a function identifier that you can update to invoke a different version.
 *
 * You can also map an alias to split invocation requests between two versions. Use the `RoutingConfig` parameter to specify a second version and the percentage of invocation requests that it receives.
 *
 * @cloudformationResource AWS::Lambda::Alias
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-alias.html
 */
class CfnAliasPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnAliasPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["description", "functionName", "functionVersion", "name", "provisionedConcurrencyConfig", "routingConfig"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::Alias`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnAliasMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnAliasPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnAliasMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnAlias.isCfnAlias(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnAliasPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnAliasPropsMixin = CfnAliasPropsMixin;
// @ts-ignore TS6133
function flattenCfnAliasMixinProps(props) {
    const ret = {};
    if ((props.functionName !== undefined))
        ret.functionName = cdk.getRefProperty(props.functionName?.functionRef, 'functionName') ?? cdk.ensureStringOrUndefined(props.functionName, "functionName", "lambda.IFunctionRef | string");
    if ((props.functionVersion !== undefined))
        ret.functionVersion = props.functionVersion;
    return ret;
}
/**
 * Details about a [Code signing configuration](https://docs.aws.amazon.com/lambda/latest/dg/configuration-codesigning.html) .
 *
 * @cloudformationResource AWS::Lambda::CodeSigningConfig
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-codesigningconfig.html
 */
class CfnCodeSigningConfigPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnCodeSigningConfigPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["allowedPublishers", "codeSigningPolicies", "description", "tags"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::CodeSigningConfig`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnCodeSigningConfigMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnCodeSigningConfigPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnCodeSigningConfigMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnCodeSigningConfig.isCfnCodeSigningConfig(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnCodeSigningConfigPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnCodeSigningConfigPropsMixin = CfnCodeSigningConfigPropsMixin;
// @ts-ignore TS6133
function flattenCfnCodeSigningConfigPropsMixinAllowedPublishersProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        signingProfileVersionArns: (!props.signingProfileVersionArns ? undefined : cdk.mapArrayInPlace(props.signingProfileVersionArns, (item) => cdk.getRefProperty(item?.signingProfileRef, 'signingProfileArn') ?? cdk.ensureStringOrUndefined(item, "signingProfileVersionArns", "signer.ISigningProfileRef | string")))
    };
}
// @ts-ignore TS6133
function flattenCfnCodeSigningConfigMixinProps(props) {
    const ret = {};
    if ((props.allowedPublishers !== undefined))
        ret.allowedPublishers = flattenCfnCodeSigningConfigPropsMixinAllowedPublishersProperty(props.allowedPublishers);
    return ret;
}
/**
 * The `AWS::Lambda::EventInvokeConfig` resource configures options for [asynchronous invocation](https://docs.aws.amazon.com/lambda/latest/dg/invocation-async.html) on a version or an alias.
 *
 * By default, Lambda retries an asynchronous invocation twice if the function returns an error. It retains events in a queue for up to six hours. When an event fails all processing attempts or stays in the asynchronous invocation queue for too long, Lambda discards it.
 *
 * @cloudformationResource AWS::Lambda::EventInvokeConfig
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventinvokeconfig.html
 */
class CfnEventInvokeConfigPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnEventInvokeConfigPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["destinationConfig", "functionName", "maximumEventAgeInSeconds", "maximumRetryAttempts", "qualifier"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::EventInvokeConfig`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnEventInvokeConfigMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnEventInvokeConfigPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnEventInvokeConfigMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnEventInvokeConfig.isCfnEventInvokeConfig(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnEventInvokeConfigPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnEventInvokeConfigPropsMixin = CfnEventInvokeConfigPropsMixin;
// @ts-ignore TS6133
function flattenCfnEventInvokeConfigPropsMixinOnSuccessProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        destination: (!props.destination ? undefined : cdk.getRefProperty(props.destination?.eventBusRef, 'eventBusArn') ?? cdk.getRefProperty(props.destination?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.destination?.topicRef, 'topicArn') ?? cdk.ensureStringOrUndefined(props.destination, "destination", "events.IEventBusRef | sqs.IQueueRef | sns.ITopicRef | string"))
    };
}
// @ts-ignore TS6133
function flattenCfnEventInvokeConfigPropsMixinOnFailureProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        destination: (!props.destination ? undefined : cdk.getRefProperty(props.destination?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.destination?.functionRef, 'functionArn') ?? cdk.getRefProperty(props.destination?.topicRef, 'topicArn') ?? cdk.ensureStringOrUndefined(props.destination, "destination", "sqs.IQueueRef | lambda.IFunctionRef | sns.ITopicRef | string"))
    };
}
// @ts-ignore TS6133
function flattenCfnEventInvokeConfigPropsMixinDestinationConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        onFailure: (!props.onFailure ? undefined : (!props.onFailure ? undefined : flattenCfnEventInvokeConfigPropsMixinOnFailureProperty(props.onFailure))),
        onSuccess: (!props.onSuccess ? undefined : (!props.onSuccess ? undefined : flattenCfnEventInvokeConfigPropsMixinOnSuccessProperty(props.onSuccess)))
    };
}
// @ts-ignore TS6133
function flattenCfnEventInvokeConfigMixinProps(props) {
    const ret = {};
    if ((props.destinationConfig !== undefined))
        ret.destinationConfig = flattenCfnEventInvokeConfigPropsMixinDestinationConfigProperty(props.destinationConfig);
    if ((props.functionName !== undefined))
        ret.functionName = cdk.getRefProperty(props.functionName?.functionRef, 'functionName') ?? cdk.ensureStringOrUndefined(props.functionName, "functionName", "lambda.IFunctionRef | string");
    if ((props.qualifier !== undefined))
        ret.qualifier = props.qualifier;
    return ret;
}
/**
 * The `AWS::Lambda::EventSourceMapping` resource creates a mapping between an event source and an AWS Lambda function.
 *
 * Lambda reads items from the event source and triggers the function.
 *
 * For details about each event source type, see the following topics. In particular, each of the topics describes the required and optional parameters for the specific event source.
 *
 * - [Configuring a Dynamo DB stream as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-ddb.html#services-dynamodb-eventsourcemapping)
 * - [Configuring a Kinesis stream as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-kinesis.html#services-kinesis-eventsourcemapping)
 * - [Configuring an SQS queue as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html#events-sqs-eventsource)
 * - [Configuring an MQ broker as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-mq.html#services-mq-eventsourcemapping)
 * - [Configuring MSK as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html)
 * - [Configuring Self-Managed Apache Kafka as an event source](https://docs.aws.amazon.com/lambda/latest/dg/kafka-smaa.html)
 * - [Configuring Amazon DocumentDB as an event source](https://docs.aws.amazon.com/lambda/latest/dg/with-documentdb.html)
 *
 * @cloudformationResource AWS::Lambda::EventSourceMapping
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-eventsourcemapping.html
 */
class CfnEventSourceMappingPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnEventSourceMappingPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["amazonManagedKafkaEventSourceConfig", "batchSize", "bisectBatchOnFunctionError", "destinationConfig", "documentDbEventSourceConfig", "enabled", "eventSourceArn", "filterCriteria", "functionName", "functionResponseTypes", "kmsKeyArn", "loggingConfig", "maximumBatchingWindowInSeconds", "maximumRecordAgeInSeconds", "maximumRetryAttempts", "metricsConfig", "parallelizationFactor", "provisionedPollerConfig", "queues", "scalingConfig", "selfManagedEventSource", "selfManagedKafkaEventSourceConfig", "sourceAccessConfigurations", "startingPosition", "startingPositionTimestamp", "tags", "topics", "tumblingWindowInSeconds"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::EventSourceMapping`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnEventSourceMappingMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnEventSourceMappingPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnEventSourceMappingMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnEventSourceMapping.isCfnEventSourceMapping(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnEventSourceMappingPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnEventSourceMappingPropsMixin = CfnEventSourceMappingPropsMixin;
// @ts-ignore TS6133
function flattenCfnEventSourceMappingPropsMixinOnFailureProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        destination: (!props.destination ? undefined : cdk.getRefProperty(props.destination?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.destination?.topicRef, 'topicArn') ?? cdk.ensureStringOrUndefined(props.destination, "destination", "sqs.IQueueRef | sns.ITopicRef | string"))
    };
}
// @ts-ignore TS6133
function flattenCfnEventSourceMappingPropsMixinDestinationConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        onFailure: (!props.onFailure ? undefined : (!props.onFailure ? undefined : flattenCfnEventSourceMappingPropsMixinOnFailureProperty(props.onFailure)))
    };
}
// @ts-ignore TS6133
function flattenCfnEventSourceMappingMixinProps(props) {
    const ret = {};
    if ((props.destinationConfig !== undefined))
        ret.destinationConfig = flattenCfnEventSourceMappingPropsMixinDestinationConfigProperty(props.destinationConfig);
    if ((props.eventSourceArn !== undefined))
        ret.eventSourceArn = cdk.getRefProperty(props.eventSourceArn?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.eventSourceArn?.streamRef, 'streamArn') ?? cdk.getRefProperty(props.eventSourceArn?.clusterRef, 'clusterArn') ?? cdk.ensureStringOrUndefined(props.eventSourceArn, "eventSourceArn", "sqs.IQueueRef | kinesis.IStreamRef | msk.IClusterRef | string");
    if ((props.functionName !== undefined))
        ret.functionName = cdk.getRefProperty(props.functionName?.functionRef, 'functionArn') ?? cdk.getRefProperty(props.functionName?.versionRef, 'functionArn') ?? cdk.getRefProperty(props.functionName?.functionRef, 'functionName') ?? cdk.ensureStringOrUndefined(props.functionName, "functionName", "lambda.IFunctionRef | lambda.IVersionRef | string");
    return ret;
}
/**
 * The `AWS::Lambda::Function` resource creates a Lambda function.
 *
 * To create a function, you need a [deployment package](https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-package.html) and an [execution role](https://docs.aws.amazon.com/lambda/latest/dg/lambda-intro-execution-role.html) . The deployment package is a .zip file archive or container image that contains your function code. The execution role grants the function permission to use AWS services, such as Amazon CloudWatch Logs for log streaming and AWS X-Ray for request tracing.
 *
 * You set the package type to `Image` if the deployment package is a [container image](https://docs.aws.amazon.com/lambda/latest/dg/lambda-images.html) . For these functions, include the URI of the container image in the Amazon ECR registry in the [`ImageUri` property of the `Code` property](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-function-code.html#cfn-lambda-function-code-imageuri) . You do not need to specify the handler and runtime properties.
 *
 * You set the package type to `Zip` if the deployment package is a [.zip file archive](https://docs.aws.amazon.com/lambda/latest/dg/gettingstarted-package.html#gettingstarted-package-zip) . For these functions, specify the Amazon S3 location of your .zip file in the `Code` property. Alternatively, for Node.js and Python functions, you can define your function inline in the [`ZipFile` property of the `Code` property](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-lambda-function-code.html#cfn-lambda-function-code-zipfile) . In both cases, you must also specify the handler and runtime properties.
 *
 * You can use [code signing](https://docs.aws.amazon.com/lambda/latest/dg/configuration-codesigning.html) if your deployment package is a .zip file archive. To enable code signing for this function, specify the ARN of a code-signing configuration. When a user attempts to deploy a code package with `UpdateFunctionCode` , Lambda checks that the code package has a valid signature from a trusted publisher. The code-signing configuration includes a set of signing profiles, which define the trusted publishers for this function.
 *
 * When you update a `AWS::Lambda::Function` resource, CloudFormation calls the [UpdateFunctionConfiguration](https://docs.aws.amazon.com/lambda/latest/api/API_UpdateFunctionConfiguration.html) and [UpdateFunctionCode](https://docs.aws.amazon.com/lambda/latest/api/API_UpdateFunctionCode.html) Lambda APIs under the hood. Because these calls happen sequentially, and invocations can happen between these calls, your function may encounter errors in the time between the calls. For example, if you remove an environment variable, and the code that references that environment variable in the same CloudFormation update, you may see invocation errors related to a missing environment variable. To work around this, you can invoke your function against a version or alias by default, rather than the `$LATEST` version.
 *
 * Note that you configure [provisioned concurrency](https://docs.aws.amazon.com/lambda/latest/dg/provisioned-concurrency.html) on a `AWS::Lambda::Version` or a `AWS::Lambda::Alias` .
 *
 * For a complete introduction to Lambda functions, see [What is Lambda?](https://docs.aws.amazon.com/lambda/latest/dg/lambda-welcome.html) in the *Lambda developer guide.*
 *
 * @cloudformationResource AWS::Lambda::Function
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-function.html
 */
class CfnFunctionPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnFunctionPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["architectures", "capacityProviderConfig", "code", "codeSigningConfigArn", "deadLetterConfig", "description", "durableConfig", "environment", "ephemeralStorage", "fileSystemConfigs", "functionName", "functionScalingConfig", "handler", "imageConfig", "kmsKeyArn", "layers", "loggingConfig", "memorySize", "packageType", "publishToLatestPublished", "recursiveLoop", "reservedConcurrentExecutions", "role", "runtime", "runtimeManagementConfig", "snapStart", "tags", "tenancyConfig", "timeout", "tracingConfig", "vpcConfig"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::Function`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnFunctionMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnFunctionPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnFunctionMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnFunction.isCfnFunction(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnFunctionPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnFunctionPropsMixin = CfnFunctionPropsMixin;
// @ts-ignore TS6133
function flattenCfnFunctionPropsMixinVpcConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        ipv6AllowedForDualStack: (!props.ipv6AllowedForDualStack ? undefined : props.ipv6AllowedForDualStack),
        securityGroupIds: (!props.securityGroupIds ? undefined : cdk.mapArrayInPlace(props.securityGroupIds, (item) => cdk.getRefProperty(item?.securityGroupRef, 'securityGroupId') ?? cdk.ensureStringOrUndefined(item, "securityGroupIds", "ec2.ISecurityGroupRef | string"))),
        subnetIds: (!props.subnetIds ? undefined : cdk.mapArrayInPlace(props.subnetIds, (item) => cdk.getRefProperty(item?.subnetRef, 'subnetId') ?? cdk.ensureStringOrUndefined(item, "subnetIds", "ec2.ISubnetRef | string")))
    };
}
// @ts-ignore TS6133
function flattenCfnFunctionPropsMixinDeadLetterConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        targetArn: (!props.targetArn ? undefined : cdk.getRefProperty(props.targetArn?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.targetArn?.topicRef, 'topicArn') ?? cdk.ensureStringOrUndefined(props.targetArn, "targetArn", "sqs.IQueueRef | sns.ITopicRef | string"))
    };
}
// @ts-ignore TS6133
function flattenCfnFunctionPropsMixinCodeProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        imageUri: (!props.imageUri ? undefined : props.imageUri),
        s3Bucket: (!props.s3Bucket ? undefined : cdk.getRefProperty(props.s3Bucket?.bucketRef, 'bucketName') ?? cdk.ensureStringOrUndefined(props.s3Bucket, "s3Bucket", "s3.IBucketRef | string")),
        s3Key: (!props.s3Key ? undefined : props.s3Key),
        s3ObjectStorageMode: (!props.s3ObjectStorageMode ? undefined : props.s3ObjectStorageMode),
        s3ObjectVersion: (!props.s3ObjectVersion ? undefined : props.s3ObjectVersion),
        sourceKmsKeyArn: (!props.sourceKmsKeyArn ? undefined : props.sourceKmsKeyArn),
        zipFile: (!props.zipFile ? undefined : props.zipFile)
    };
}
// @ts-ignore TS6133
function flattenCfnFunctionPropsMixinFileSystemConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        arn: (!props.arn ? undefined : cdk.getRefProperty(props.arn?.accessPointRef, 'accessPointArn') ?? cdk.ensureStringOrUndefined(props.arn, "arn", "efs.IAccessPointRef | string")),
        localMountPath: (!props.localMountPath ? undefined : props.localMountPath)
    };
}
// @ts-ignore TS6133
function flattenCfnFunctionPropsMixinLoggingConfigProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        applicationLogLevel: (!props.applicationLogLevel ? undefined : props.applicationLogLevel),
        logFormat: (!props.logFormat ? undefined : props.logFormat),
        logGroup: (!props.logGroup ? undefined : cdk.getRefProperty(props.logGroup?.logGroupRef, 'logGroupName') ?? cdk.ensureStringOrUndefined(props.logGroup, "logGroup", "logs.ILogGroupRef | string")),
        systemLogLevel: (!props.systemLogLevel ? undefined : props.systemLogLevel)
    };
}
// @ts-ignore TS6133
function flattenCfnFunctionMixinProps(props) {
    const ret = {};
    if ((props.code !== undefined))
        ret.code = flattenCfnFunctionPropsMixinCodeProperty(props.code);
    if ((props.codeSigningConfigArn !== undefined))
        ret.codeSigningConfigArn = cdk.getRefProperty(props.codeSigningConfigArn?.codeSigningConfigRef, 'codeSigningConfigArn') ?? cdk.ensureStringOrUndefined(props.codeSigningConfigArn, "codeSigningConfigArn", "lambda.ICodeSigningConfigRef | string");
    if ((props.deadLetterConfig !== undefined))
        ret.deadLetterConfig = flattenCfnFunctionPropsMixinDeadLetterConfigProperty(props.deadLetterConfig);
    if ((props.fileSystemConfigs !== undefined))
        ret.fileSystemConfigs = (cdk.isResolvableObject(props.fileSystemConfigs) ? props.fileSystemConfigs : cdk.mapArrayInPlace(props.fileSystemConfigs, (item) => flattenCfnFunctionPropsMixinFileSystemConfigProperty(item)));
    if ((props.kmsKeyArn !== undefined))
        ret.kmsKeyArn = cdk.getRefProperty(props.kmsKeyArn?.keyRef, 'keyArn') ?? cdk.ensureStringOrUndefined(props.kmsKeyArn, "kmsKeyArn", "kms.IKeyRef | string");
    if ((props.layers !== undefined))
        ret.layers = cdk.mapArrayInPlace(props.layers, (item) => cdk.getRefProperty(item?.layerVersionRef, 'layerVersionArn') ?? cdk.ensureStringOrUndefined(item, "layers", "lambda.ILayerVersionRef | string"));
    if ((props.loggingConfig !== undefined))
        ret.loggingConfig = flattenCfnFunctionPropsMixinLoggingConfigProperty(props.loggingConfig);
    if ((props.role !== undefined))
        ret.role = cdk.getRefProperty(props.role?.roleRef, 'roleArn') ?? cdk.ensureStringOrUndefined(props.role, "role", "iam.IRoleRef | string");
    if ((props.vpcConfig !== undefined))
        ret.vpcConfig = flattenCfnFunctionPropsMixinVpcConfigProperty(props.vpcConfig);
    return ret;
}
/**
 * The `AWS::Lambda::LayerVersion` resource creates a [Lambda layer](https://docs.aws.amazon.com/lambda/latest/dg/configuration-layers.html) from a ZIP archive.
 *
 * @cloudformationResource AWS::Lambda::LayerVersion
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-layerversion.html
 */
class CfnLayerVersionPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnLayerVersionPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["compatibleArchitectures", "compatibleRuntimes", "content", "description", "layerName", "licenseInfo"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::LayerVersion`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnLayerVersionMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnLayerVersionPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnLayerVersionMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnLayerVersion.isCfnLayerVersion(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnLayerVersionPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnLayerVersionPropsMixin = CfnLayerVersionPropsMixin;
// @ts-ignore TS6133
function flattenCfnLayerVersionPropsMixinContentProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        s3Bucket: (!props.s3Bucket ? undefined : cdk.getRefProperty(props.s3Bucket?.bucketRef, 'bucketName') ?? cdk.ensureStringOrUndefined(props.s3Bucket, "s3Bucket", "s3.IBucketRef | string")),
        s3Key: (!props.s3Key ? undefined : props.s3Key),
        s3ObjectVersion: (!props.s3ObjectVersion ? undefined : props.s3ObjectVersion)
    };
}
// @ts-ignore TS6133
function flattenCfnLayerVersionMixinProps(props) {
    const ret = {};
    if ((props.content !== undefined))
        ret.content = flattenCfnLayerVersionPropsMixinContentProperty(props.content);
    return ret;
}
/**
 * The `AWS::Lambda::LayerVersionPermission` resource adds permissions to the resource-based policy of a version of an [Lambda layer](https://docs.aws.amazon.com/lambda/latest/dg/configuration-layers.html) . Use this action to grant layer usage permission to other accounts. You can grant permission to a single account, all AWS accounts, or all accounts in an organization.
 *
 * > Since the release of the [UpdateReplacePolicy](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-updatereplacepolicy.html) both `UpdateReplacePolicy` and `DeletionPolicy` are required to protect your Resources/LayerPermissions from deletion.
 *
 * @cloudformationResource AWS::Lambda::LayerVersionPermission
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-layerversionpermission.html
 */
class CfnLayerVersionPermissionPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnLayerVersionPermissionPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["action", "layerVersionArn", "organizationId", "principal"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::LayerVersionPermission`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnLayerVersionPermissionMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnLayerVersionPermissionPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnLayerVersionPermissionMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnLayerVersionPermission.isCfnLayerVersionPermission(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnLayerVersionPermissionPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnLayerVersionPermissionPropsMixin = CfnLayerVersionPermissionPropsMixin;
// @ts-ignore TS6133
function flattenCfnLayerVersionPermissionMixinProps(props) {
    const ret = {};
    if ((props.layerVersionArn !== undefined))
        ret.layerVersionArn = cdk.getRefProperty(props.layerVersionArn?.layerVersionRef, 'layerVersionArn') ?? cdk.ensureStringOrUndefined(props.layerVersionArn, "layerVersionArn", "lambda.ILayerVersionRef | string");
    return ret;
}
/**
 * The `AWS::Lambda::Permission` resource grants an AWS service or another account permission to use a function.
 *
 * You can apply the policy at the function level, or specify a qualifier to restrict access to a single version or alias. If you use a qualifier, the invoker must use the full Amazon Resource Name (ARN) of that version or alias to invoke the function.
 *
 * To grant permission to another account, specify the account ID as the `Principal` . To grant permission to an organization defined in AWS Organizations , specify the organization ID as the `PrincipalOrgID` . For AWS services, the principal is a domain-style identifier defined by the service, like `s3.amazonaws.com` or `sns.amazonaws.com` . For AWS services, you can also specify the ARN of the associated resource as the `SourceArn` . If you grant permission to a service principal without specifying the source, other accounts could potentially configure resources in their account to invoke your Lambda function.
 *
 * If your function has a function URL, you can specify the `FunctionUrlAuthType` parameter. This adds a condition to your permission that only applies when your function URL's `AuthType` matches the specified `FunctionUrlAuthType` . For more information about the `AuthType` parameter, see [Control access to Lambda function URLs](https://docs.aws.amazon.com/lambda/latest/dg/urls-auth.html) .
 *
 * This resource adds a statement to a resource-based permission policy for the function. For more information about function policies, see [Lambda Function Policies](https://docs.aws.amazon.com/lambda/latest/dg/access-control-resource-based.html) .
 *
 * @cloudformationResource AWS::Lambda::Permission
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-permission.html
 */
class CfnPermissionPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnPermissionPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["action", "eventSourceToken", "functionName", "functionUrlAuthType", "invokedViaFunctionUrl", "principal", "principalOrgId", "sourceAccount", "sourceArn"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::Permission`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnPermissionMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnPermissionPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnPermissionMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnPermission.isCfnPermission(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnPermissionPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnPermissionPropsMixin = CfnPermissionPropsMixin;
// @ts-ignore TS6133
function flattenCfnPermissionMixinProps(props) {
    const ret = {};
    if ((props.functionName !== undefined))
        ret.functionName = cdk.getRefProperty(props.functionName?.functionRef, 'functionArn') ?? cdk.getRefProperty(props.functionName?.versionRef, 'functionArn') ?? cdk.getRefProperty(props.functionName?.functionRef, 'functionName') ?? cdk.ensureStringOrUndefined(props.functionName, "functionName", "lambda.IFunctionRef | lambda.IVersionRef | string");
    if ((props.principal !== undefined))
        ret.principal = cdk.getRefProperty(props.principal?.roleRef, 'roleArn') ?? cdk.getRefProperty(props.principal?.userRef, 'userArn') ?? cdk.ensureStringOrUndefined(props.principal, "principal", "iam.IRoleRef | iam.IUserRef | string");
    if ((props.sourceArn !== undefined))
        ret.sourceArn = cdk.getRefProperty(props.sourceArn?.ruleRef, 'ruleArn') ?? cdk.getRefProperty(props.sourceArn?.bucketRef, 'bucketArn') ?? cdk.getRefProperty(props.sourceArn?.queueRef, 'queueArn') ?? cdk.getRefProperty(props.sourceArn?.topicRef, 'topicArn') ?? cdk.getRefProperty(props.sourceArn?.topicRuleRef, 'topicRuleArn') ?? cdk.getRefProperty(props.sourceArn?.logGroupRef, 'logGroupArn') ?? cdk.getRefProperty(props.sourceArn?.userPoolRef, 'userPoolArn') ?? cdk.getRefProperty(props.sourceArn?.functionRef, 'functionArn') ?? cdk.getRefProperty(props.sourceArn?.deliveryStreamRef, 'deliveryStreamArn') ?? cdk.getRefProperty(props.sourceArn?.roleRef, 'roleArn') ?? cdk.ensureStringOrUndefined(props.sourceArn, "sourceArn", "events.IRuleRef | s3.IBucketRef | sqs.IQueueRef | sns.ITopicRef | iot.ITopicRuleRef | logs.ILogGroupRef | cognito.IUserPoolRef | lambda.IFunctionRef | kinesisfirehose.IDeliveryStreamRef | iam.IRoleRef | string");
    return ret;
}
/**
 * The `AWS::Lambda::Url` resource creates a function URL with the specified configuration parameters.
 *
 * A [function URL](https://docs.aws.amazon.com/lambda/latest/dg/lambda-urls.html) is a dedicated HTTP(S) endpoint that you can use to invoke your function.
 *
 * @cloudformationResource AWS::Lambda::Url
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-url.html
 */
class CfnUrlPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnUrlPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["authType", "cors", "invokeMode", "qualifier", "targetFunctionArn"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::Url`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnUrlMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnUrlPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnUrlMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnUrl.isCfnUrl(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnUrlPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnUrlPropsMixin = CfnUrlPropsMixin;
// @ts-ignore TS6133
function flattenCfnUrlMixinProps(props) {
    const ret = {};
    if ((props.targetFunctionArn !== undefined))
        ret.targetFunctionArn = cdk.getRefProperty(props.targetFunctionArn?.functionRef, 'functionArn') ?? cdk.ensureStringOrUndefined(props.targetFunctionArn, "targetFunctionArn", "lambda.IFunctionRef | string");
    return ret;
}
/**
 * The `AWS::Lambda::Version` resource creates a [version](https://docs.aws.amazon.com/lambda/latest/dg/versioning-aliases.html) from the current code and configuration of a function. Use versions to create a snapshot of your function code and configuration that doesn't change.
 *
 * @cloudformationResource AWS::Lambda::Version
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-version.html
 */
class CfnVersionPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnVersionPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["codeSha256", "description", "functionName", "functionScalingConfig", "provisionedConcurrencyConfig", "runtimePolicy"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::Version`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnVersionMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnVersionPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnVersionMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnVersion.isCfnVersion(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnVersionPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnVersionPropsMixin = CfnVersionPropsMixin;
// @ts-ignore TS6133
function flattenCfnVersionMixinProps(props) {
    const ret = {};
    if ((props.functionName !== undefined))
        ret.functionName = cdk.getRefProperty(props.functionName?.functionRef, 'functionArn') ?? cdk.getRefProperty(props.functionName?.functionRef, 'functionName') ?? cdk.ensureStringOrUndefined(props.functionName, "functionName", "lambda.IFunctionRef | string");
    return ret;
}
/**
 * Creates a capacity provider that manages compute resources for Lambda functions.
 *
 * @cloudformationResource AWS::Lambda::CapacityProvider
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-lambda-capacityprovider.html
 */
class CfnCapacityProviderPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_lambda.CfnCapacityProviderPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["capacityProviderName", "capacityProviderScalingConfig", "instanceRequirements", "kmsKeyArn", "permissionsConfig", "propagateTags", "tags", "vpcConfig"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::Lambda::CapacityProvider`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_lambda_CfnCapacityProviderMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnCapacityProviderPropsMixin);
            }
            throw error;
        }
        this.props = props;
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnCapacityProvider.isCfnCapacityProvider(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnCapacityProviderPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnCapacityProviderPropsMixin = CfnCapacityProviderPropsMixin;
