"use strict";
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.StackSetConstraint = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * Resource Type definition for AWS::ServiceCatalog::StackSetConstraint
 */
class StackSetConstraint extends pulumi.CustomResource {
    /**
     * Get an existing StackSetConstraint resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, opts) {
        return new StackSetConstraint(name, undefined, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of StackSetConstraint.  This is designed to work even
     * when multiple copies of the Pulumi SDK have been loaded into the same process.
     */
    static isInstance(obj) {
        if (obj === undefined || obj === null) {
            return false;
        }
        return obj['__pulumiType'] === StackSetConstraint.__pulumiType;
    }
    /**
     * Create a StackSetConstraint resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name, args, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (!opts.id) {
            if (args?.accountList === undefined && !opts.urn) {
                throw new Error("Missing required property 'accountList'");
            }
            if (args?.adminRole === undefined && !opts.urn) {
                throw new Error("Missing required property 'adminRole'");
            }
            if (args?.description === undefined && !opts.urn) {
                throw new Error("Missing required property 'description'");
            }
            if (args?.executionRole === undefined && !opts.urn) {
                throw new Error("Missing required property 'executionRole'");
            }
            if (args?.portfolioId === undefined && !opts.urn) {
                throw new Error("Missing required property 'portfolioId'");
            }
            if (args?.productId === undefined && !opts.urn) {
                throw new Error("Missing required property 'productId'");
            }
            if (args?.regionList === undefined && !opts.urn) {
                throw new Error("Missing required property 'regionList'");
            }
            if (args?.stackInstanceControl === undefined && !opts.urn) {
                throw new Error("Missing required property 'stackInstanceControl'");
            }
            resourceInputs["acceptLanguage"] = args?.acceptLanguage;
            resourceInputs["accountList"] = args?.accountList;
            resourceInputs["adminRole"] = args?.adminRole;
            resourceInputs["description"] = args?.description;
            resourceInputs["executionRole"] = args?.executionRole;
            resourceInputs["portfolioId"] = args?.portfolioId;
            resourceInputs["productId"] = args?.productId;
            resourceInputs["regionList"] = args?.regionList;
            resourceInputs["stackInstanceControl"] = args?.stackInstanceControl;
            resourceInputs["awsId"] = undefined /*out*/;
        }
        else {
            resourceInputs["acceptLanguage"] = undefined /*out*/;
            resourceInputs["accountList"] = undefined /*out*/;
            resourceInputs["adminRole"] = undefined /*out*/;
            resourceInputs["awsId"] = undefined /*out*/;
            resourceInputs["description"] = undefined /*out*/;
            resourceInputs["executionRole"] = undefined /*out*/;
            resourceInputs["portfolioId"] = undefined /*out*/;
            resourceInputs["productId"] = undefined /*out*/;
            resourceInputs["regionList"] = undefined /*out*/;
            resourceInputs["stackInstanceControl"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const replaceOnChanges = { replaceOnChanges: ["portfolioId", "productId"] };
        opts = pulumi.mergeOptions(opts, replaceOnChanges);
        super(StackSetConstraint.__pulumiType, name, resourceInputs, opts);
    }
}
exports.StackSetConstraint = StackSetConstraint;
/** @internal */
StackSetConstraint.__pulumiType = 'aws-native:servicecatalog:StackSetConstraint';
//# sourceMappingURL=stackSetConstraint.js.map