"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.CfnResourcePolicyPropsMixin = exports.CfnResourceDataSyncPropsMixin = exports.CfnPatchBaselinePropsMixin = exports.CfnParameterPropsMixin = exports.CfnMaintenanceWindowTaskPropsMixin = exports.CfnMaintenanceWindowTargetPropsMixin = exports.CfnMaintenanceWindowPropsMixin = exports.CfnDocumentPropsMixin = exports.CfnAssociationPropsMixin = 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-ssm"));
/**
 * The `AWS::SSM::Association` resource creates a State Manager association for your managed instances.
 *
 * A State Manager association defines the state that you want to maintain on your instances. For example, an association can specify that anti-virus software must be installed and running on your instances, or that certain ports must be closed. For static targets, the association specifies a schedule for when the configuration is reapplied. For dynamic targets, such as an Resource Groups or an AWS Auto Scaling Group, State Manager applies the configuration when new instances are added to the group. The association also specifies actions to take when applying the configuration. For example, an association for anti-virus software might run once a day. If the software is not installed, then State Manager installs it. If the software is installed, but the service is not running, then the association might instruct State Manager to start the service.
 *
 * @cloudformationResource AWS::SSM::Association
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-association.html
 */
class CfnAssociationPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnAssociationPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["applyOnlyAtCronInterval", "associationName", "automationTargetParameterName", "calendarNames", "complianceSeverity", "documentVersion", "instanceId", "maxConcurrency", "maxErrors", "name", "outputLocation", "parameters", "scheduleExpression", "scheduleOffset", "syncCompliance", "targets", "waitForSuccessTimeoutSeconds"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::Association`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnAssociationMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnAssociationPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnAssociationMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnAssociation.isCfnAssociation(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnAssociationPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnAssociationPropsMixin = CfnAssociationPropsMixin;
// @ts-ignore TS6133
function flattenCfnAssociationPropsMixinTargetProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        key: (!props.key ? undefined : props.key),
        values: (!props.values ? undefined : cdk.mapArrayInPlace(props.values, (item) => cdk.getRefProperty(item?.instanceRef, 'instanceId') ?? cdk.getRefProperty(item?.autoScalingGroupRef, 'autoScalingGroupName') ?? cdk.getRefProperty(item?.instanceRef, 'instanceId') ?? cdk.ensureStringOrUndefined(item, "values", "ec2.IInstanceRef | autoscaling.IAutoScalingGroupRef | string")))
    };
}
// @ts-ignore TS6133
function flattenCfnAssociationPropsMixinS3OutputLocationProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        outputS3BucketName: (!props.outputS3BucketName ? undefined : cdk.getRefProperty(props.outputS3BucketName?.bucketRef, 'bucketName') ?? cdk.ensureStringOrUndefined(props.outputS3BucketName, "outputS3BucketName", "s3.IBucketRef | string")),
        outputS3KeyPrefix: (!props.outputS3KeyPrefix ? undefined : props.outputS3KeyPrefix),
        outputS3Region: (!props.outputS3Region ? undefined : props.outputS3Region)
    };
}
// @ts-ignore TS6133
function flattenCfnAssociationPropsMixinInstanceAssociationOutputLocationProperty(props) {
    if (cdk.isResolvableObject(props))
        return props;
    return {
        s3Location: (!props.s3Location ? undefined : (!props.s3Location ? undefined : flattenCfnAssociationPropsMixinS3OutputLocationProperty(props.s3Location)))
    };
}
// @ts-ignore TS6133
function flattenCfnAssociationMixinProps(props) {
    const ret = {};
    if ((props.name !== undefined))
        ret.name = cdk.getRefProperty(props.name?.documentRef, 'documentName') ?? cdk.ensureStringOrUndefined(props.name, "name", "ssm.IDocumentRef | string");
    if ((props.outputLocation !== undefined))
        ret.outputLocation = flattenCfnAssociationPropsMixinInstanceAssociationOutputLocationProperty(props.outputLocation);
    if ((props.targets !== undefined))
        ret.targets = (cdk.isResolvableObject(props.targets) ? props.targets : cdk.mapArrayInPlace(props.targets, (item) => flattenCfnAssociationPropsMixinTargetProperty(item)));
    return ret;
}
/**
 * The `AWS::SSM::Document` resource creates a Systems Manager (SSM) document in AWS Systems Manager .
 *
 * This document defines the actions that Systems Manager performs on your AWS resources.
 *
 * > This resource does not support CloudFormation drift detection.
 *
 * @cloudformationResource AWS::SSM::Document
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-document.html
 */
class CfnDocumentPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnDocumentPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["attachments", "content", "documentFormat", "documentType", "name", "requires", "tags", "targetType", "updateMethod", "versionName"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::Document`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnDocumentMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnDocumentPropsMixin);
            }
            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.CfnDocument.isCfnDocument(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnDocumentPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnDocumentPropsMixin = CfnDocumentPropsMixin;
/**
 * The `AWS::SSM::MaintenanceWindow` resource represents general information about a maintenance window for AWS Systems Manager .
 *
 * Maintenance windows let you define a schedule for when to perform potentially disruptive actions on your instances, such as patching an operating system (OS), updating drivers, or installing software. Each maintenance window has a schedule, a duration, a set of registered targets, and a set of registered tasks.
 *
 * For more information, see [Systems Manager Maintenance Windows](https://docs.aws.amazon.com/systems-manager/latest/userguide/systems-manager-maintenance.html) in the *AWS Systems Manager User Guide* and [CreateMaintenanceWindow](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreateMaintenanceWindow.html) in the *AWS Systems Manager API Reference* .
 *
 * @cloudformationResource AWS::SSM::MaintenanceWindow
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-maintenancewindow.html
 */
class CfnMaintenanceWindowPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnMaintenanceWindowPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["allowUnassociatedTargets", "cutoff", "description", "duration", "endDate", "name", "schedule", "scheduleOffset", "scheduleTimezone", "startDate", "tags"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::MaintenanceWindow`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnMaintenanceWindowMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnMaintenanceWindowPropsMixin);
            }
            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.CfnMaintenanceWindow.isCfnMaintenanceWindow(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnMaintenanceWindowPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnMaintenanceWindowPropsMixin = CfnMaintenanceWindowPropsMixin;
/**
 * The `AWS::SSM::MaintenanceWindowTarget` resource registers a target with a maintenance window for AWS Systems Manager .
 *
 * For more information, see [RegisterTargetWithMaintenanceWindow](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_RegisterTargetWithMaintenanceWindow.html) in the *AWS Systems Manager API Reference* .
 *
 * @cloudformationResource AWS::SSM::MaintenanceWindowTarget
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-maintenancewindowtarget.html
 */
class CfnMaintenanceWindowTargetPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnMaintenanceWindowTargetPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["description", "name", "ownerInformation", "resourceType", "targets", "windowId"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::MaintenanceWindowTarget`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnMaintenanceWindowTargetMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnMaintenanceWindowTargetPropsMixin);
            }
            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.CfnMaintenanceWindowTarget.isCfnMaintenanceWindowTarget(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnMaintenanceWindowTargetPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnMaintenanceWindowTargetPropsMixin = CfnMaintenanceWindowTargetPropsMixin;
/**
 * The `AWS::SSM::MaintenanceWindowTask` resource defines information about a task for an AWS Systems Manager maintenance window.
 *
 * For more information, see [RegisterTaskWithMaintenanceWindow](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_RegisterTaskWithMaintenanceWindow.html) in the *AWS Systems Manager API Reference* .
 *
 * @cloudformationResource AWS::SSM::MaintenanceWindowTask
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-maintenancewindowtask.html
 */
class CfnMaintenanceWindowTaskPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnMaintenanceWindowTaskPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["cutoffBehavior", "description", "loggingInfo", "maxConcurrency", "maxErrors", "name", "priority", "serviceRoleArn", "targets", "taskArn", "taskInvocationParameters", "taskParameters", "taskType", "windowId"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::MaintenanceWindowTask`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnMaintenanceWindowTaskMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnMaintenanceWindowTaskPropsMixin);
            }
            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.CfnMaintenanceWindowTask.isCfnMaintenanceWindowTask(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnMaintenanceWindowTaskPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnMaintenanceWindowTaskPropsMixin = CfnMaintenanceWindowTaskPropsMixin;
/**
 * The `AWS::SSM::Parameter` resource creates an SSM parameter in AWS Systems Manager Parameter Store.
 *
 * > To create an SSM parameter, you must have the AWS Identity and Access Management ( IAM ) permissions `ssm:PutParameter` and `ssm:AddTagsToResource` . On stack creation, AWS CloudFormation adds the following three tags to the parameter: `aws:cloudformation:stack-name` , `aws:cloudformation:logical-id` , and `aws:cloudformation:stack-id` , in addition to any custom tags you specify.
 * >
 * > To add, update, or remove tags during stack update, you must have IAM permissions for both `ssm:AddTagsToResource` and `ssm:RemoveTagsFromResource` . For more information, see [Managing access using policies](https://docs.aws.amazon.com/systems-manager/latest/userguide/security-iam.html#security_iam_access-manage) in the *AWS Systems Manager User Guide* .
 *
 * For information about valid values for parameters, see [About requirements and constraints for parameter names](https://docs.aws.amazon.com/systems-manager/latest/userguide/sysman-paramstore-su-create.html#sysman-parameter-name-constraints) in the *AWS Systems Manager User Guide* and [PutParameter](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_PutParameter.html) in the *AWS Systems Manager API Reference* .
 *
 * @cloudformationResource AWS::SSM::Parameter
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-parameter.html
 */
class CfnParameterPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnParameterPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["allowedPattern", "dataType", "description", "name", "policies", "tags", "tier", "type", "value"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::Parameter`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnParameterMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnParameterPropsMixin);
            }
            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.CfnParameter.isCfnParameter(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnParameterPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnParameterPropsMixin = CfnParameterPropsMixin;
/**
 * The `AWS::SSM::PatchBaseline` resource defines the basic information for an AWS Systems Manager patch baseline.
 *
 * A patch baseline defines which patches are approved for installation on your instances.
 *
 * For more information, see [CreatePatchBaseline](https://docs.aws.amazon.com/systems-manager/latest/APIReference/API_CreatePatchBaseline.html) in the *AWS Systems Manager API Reference* .
 *
 * @cloudformationResource AWS::SSM::PatchBaseline
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-patchbaseline.html
 */
class CfnPatchBaselinePropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnPatchBaselinePropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["approvalRules", "approvedPatches", "approvedPatchesComplianceLevel", "approvedPatchesEnableNonSecurity", "availableSecurityUpdatesComplianceStatus", "defaultBaseline", "description", "globalFilters", "name", "operatingSystem", "patchGroups", "rejectedPatches", "rejectedPatchesAction", "sources", "tags"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::PatchBaseline`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnPatchBaselineMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnPatchBaselinePropsMixin);
            }
            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.CfnPatchBaseline.isCfnPatchBaseline(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnPatchBaselinePropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnPatchBaselinePropsMixin = CfnPatchBaselinePropsMixin;
/**
 * The `AWS::SSM::ResourceDataSync` resource creates, updates, or deletes a resource data sync for AWS Systems Manager .
 *
 * A resource data sync helps you view data from multiple sources in a single location. Systems Manager offers two types of resource data sync: `SyncToDestination` and `SyncFromSource` .
 *
 * You can configure Systems Manager Inventory to use the `SyncToDestination` type to synchronize Inventory data from multiple AWS Regions to a single Amazon S3 bucket.
 *
 * You can configure Systems Manager Explorer to use the `SyncFromSource` type to synchronize operational work items (OpsItems) and operational data (OpsData) from multiple AWS Regions . This type can synchronize OpsItems and OpsData from multiple AWS accounts and Regions or from an `EntireOrganization` by using AWS Organizations .
 *
 * A resource data sync is an asynchronous operation that returns immediately. After a successful initial sync is completed, the system continuously syncs data.
 *
 * By default, data is not encrypted in Amazon S3 . We strongly recommend that you enable encryption in Amazon S3 to ensure secure data storage. We also recommend that you secure access to the Amazon S3 bucket by creating a restrictive bucket policy.
 *
 * For more information, see [Configuring Inventory Collection](https://docs.aws.amazon.com/systems-manager/latest/userguide/sysman-inventory-configuring.html#sysman-inventory-datasync) and [Setting Up Systems Manager Explorer to Display Data from Multiple Accounts and Regions](https://docs.aws.amazon.com/systems-manager/latest/userguide/Explorer-resource-data-sync.html) in the *AWS Systems Manager User Guide* .
 *
 * > The following *Syntax* section shows all fields that are supported for a resource data sync. The *Examples* section below shows the recommended way to specify configurations for each sync type. Refer to the *Examples* section when you create your resource data sync.
 *
 * @cloudformationResource AWS::SSM::ResourceDataSync
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-resourcedatasync.html
 */
class CfnResourceDataSyncPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnResourceDataSyncPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["bucketName", "bucketPrefix", "bucketRegion", "kmsKeyArn", "s3Destination", "syncFormat", "syncName", "syncSource", "syncType"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::ResourceDataSync`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnResourceDataSyncMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnResourceDataSyncPropsMixin);
            }
            throw error;
        }
        this.props = {
            ...props,
            ...flattenCfnResourceDataSyncMixinProps(props)
        };
        this.strategy = (options.strategy ?? cdk.PropertyMergeStrategy.combine());
    }
    /**
     * Check if this mixin supports the given construct
     */
    supports(construct) {
        return (cdk.CfnResource.isCfnResource(construct) && service.CfnResourceDataSync.isCfnResourceDataSync(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnResourceDataSyncPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnResourceDataSyncPropsMixin = CfnResourceDataSyncPropsMixin;
// @ts-ignore TS6133
function flattenCfnResourceDataSyncMixinProps(props) {
    const ret = {};
    if ((props.bucketName !== undefined))
        ret.bucketName = cdk.getRefProperty(props.bucketName?.bucketRef, 'bucketName') ?? cdk.ensureStringOrUndefined(props.bucketName, "bucketName", "s3.IBucketRef | string");
    return ret;
}
/**
 * Creates or updates a Systems Manager resource policy.
 *
 * A resource policy helps you to define the IAM entity (for example, an AWS account ) that can manage your Systems Manager resources. Currently, `OpsItemGroup` is the only resource that supports Systems Manager resource policies. The resource policy for `OpsItemGroup` enables AWS accounts to view and interact with OpsCenter operational work items (OpsItems). OpsCenter is a tool in Systems Manager .
 *
 * @cloudformationResource AWS::SSM::ResourcePolicy
 * @mixin true
 * @stability external
 * @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-ssm-resourcepolicy.html
 */
class CfnResourcePolicyPropsMixin extends cdk.Mixin {
    static [JSII_RTTI_SYMBOL_1] = { fqn: "@aws-cdk/cfn-property-mixins.aws_ssm.CfnResourcePolicyPropsMixin", version: "2.258.1" };
    static CFN_PROPERTY_KEYS = ["policy", "resourceArn"];
    props;
    strategy;
    /**
     * Create a mixin to apply properties to `AWS::SSM::ResourcePolicy`.
     *
     * @param props L1 properties to apply
     * @param options Mixin options
     */
    constructor(props, options = {}) {
        super();
        try {
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_aws_ssm_CfnResourcePolicyMixinProps(props);
            jsiiDeprecationWarnings._aws_cdk_cfn_property_mixins_CfnPropertyMixinOptions(options);
        }
        catch (error) {
            if (process.env.JSII_DEBUG !== "1" && error.name === "DeprecationError") {
                Error.captureStackTrace(error, CfnResourcePolicyPropsMixin);
            }
            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.CfnResourcePolicy.isCfnResourcePolicy(construct));
    }
    /**
     * Apply the mixin properties to the construct
     */
    applyTo(construct) {
        if (this.supports(construct)) {
            this.strategy.apply(construct, this.props, CfnResourcePolicyPropsMixin.CFN_PROPERTY_KEYS);
        }
    }
}
exports.CfnResourcePolicyPropsMixin = CfnResourcePolicyPropsMixin;
