@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
100 lines • 5.01 kB
JavaScript
;
// *** 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.CloudFormationType = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Manages a version of a CloudFormation Type.
*
* ## Import
*
* Using `pulumi import`, import `aws_cloudformation_type` using the type version Amazon Resource Name (ARN). For example:
*
* ```sh
* $ pulumi import aws:cloudformation/cloudFormationType:CloudFormationType example arn:aws:cloudformation:us-east-1:123456789012:type/resource/ExampleCompany-ExampleService-ExampleType/1
* ```
*/
class CloudFormationType extends pulumi.CustomResource {
/**
* Get an existing CloudFormationType 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 state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name, id, state, opts) {
return new CloudFormationType(name, state, { ...opts, id: id });
}
/**
* Returns true if the given object is an instance of CloudFormationType. 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'] === CloudFormationType.__pulumiType;
}
constructor(name, argsOrState, opts) {
let resourceInputs = {};
opts = opts || {};
if (opts.id) {
const state = argsOrState;
resourceInputs["arn"] = state?.arn;
resourceInputs["defaultVersionId"] = state?.defaultVersionId;
resourceInputs["deprecatedStatus"] = state?.deprecatedStatus;
resourceInputs["description"] = state?.description;
resourceInputs["documentationUrl"] = state?.documentationUrl;
resourceInputs["executionRoleArn"] = state?.executionRoleArn;
resourceInputs["isDefaultVersion"] = state?.isDefaultVersion;
resourceInputs["loggingConfig"] = state?.loggingConfig;
resourceInputs["provisioningType"] = state?.provisioningType;
resourceInputs["region"] = state?.region;
resourceInputs["schema"] = state?.schema;
resourceInputs["schemaHandlerPackage"] = state?.schemaHandlerPackage;
resourceInputs["sourceUrl"] = state?.sourceUrl;
resourceInputs["type"] = state?.type;
resourceInputs["typeArn"] = state?.typeArn;
resourceInputs["typeName"] = state?.typeName;
resourceInputs["versionId"] = state?.versionId;
resourceInputs["visibility"] = state?.visibility;
}
else {
const args = argsOrState;
if (args?.schemaHandlerPackage === undefined && !opts.urn) {
throw new Error("Missing required property 'schemaHandlerPackage'");
}
if (args?.typeName === undefined && !opts.urn) {
throw new Error("Missing required property 'typeName'");
}
resourceInputs["executionRoleArn"] = args?.executionRoleArn;
resourceInputs["loggingConfig"] = args?.loggingConfig;
resourceInputs["region"] = args?.region;
resourceInputs["schemaHandlerPackage"] = args?.schemaHandlerPackage;
resourceInputs["type"] = args?.type;
resourceInputs["typeName"] = args?.typeName;
resourceInputs["arn"] = undefined /*out*/;
resourceInputs["defaultVersionId"] = undefined /*out*/;
resourceInputs["deprecatedStatus"] = undefined /*out*/;
resourceInputs["description"] = undefined /*out*/;
resourceInputs["documentationUrl"] = undefined /*out*/;
resourceInputs["isDefaultVersion"] = undefined /*out*/;
resourceInputs["provisioningType"] = undefined /*out*/;
resourceInputs["schema"] = undefined /*out*/;
resourceInputs["sourceUrl"] = undefined /*out*/;
resourceInputs["typeArn"] = undefined /*out*/;
resourceInputs["versionId"] = undefined /*out*/;
resourceInputs["visibility"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(CloudFormationType.__pulumiType, name, resourceInputs, opts);
}
}
exports.CloudFormationType = CloudFormationType;
/** @internal */
CloudFormationType.__pulumiType = 'aws:cloudformation/cloudFormationType:CloudFormationType';
//# sourceMappingURL=cloudFormationType.js.map