UNPKG

@pulumiverse/dynatrace

Version:

A Pulumi package for creating and managing Dynatrace cloud resources.

81 lines 4.23 kB
"use strict"; // *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** // *** Do not edit by hand unless you're certain you know what you are doing! *** Object.defineProperty(exports, "__esModule", { value: true }); exports.GenericRelationships = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); class GenericRelationships extends pulumi.CustomResource { /** * Get an existing GenericRelationships 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 GenericRelationships(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of GenericRelationships. 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'] === GenericRelationships.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["createdBy"] = state ? state.createdBy : undefined; resourceInputs["enabled"] = state ? state.enabled : undefined; resourceInputs["fromRole"] = state ? state.fromRole : undefined; resourceInputs["fromType"] = state ? state.fromType : undefined; resourceInputs["sources"] = state ? state.sources : undefined; resourceInputs["toRole"] = state ? state.toRole : undefined; resourceInputs["toType"] = state ? state.toType : undefined; resourceInputs["typeOfRelation"] = state ? state.typeOfRelation : undefined; } else { const args = argsOrState; if ((!args || args.createdBy === undefined) && !opts.urn) { throw new Error("Missing required property 'createdBy'"); } if ((!args || args.enabled === undefined) && !opts.urn) { throw new Error("Missing required property 'enabled'"); } if ((!args || args.fromType === undefined) && !opts.urn) { throw new Error("Missing required property 'fromType'"); } if ((!args || args.sources === undefined) && !opts.urn) { throw new Error("Missing required property 'sources'"); } if ((!args || args.toType === undefined) && !opts.urn) { throw new Error("Missing required property 'toType'"); } if ((!args || args.typeOfRelation === undefined) && !opts.urn) { throw new Error("Missing required property 'typeOfRelation'"); } resourceInputs["createdBy"] = args ? args.createdBy : undefined; resourceInputs["enabled"] = args ? args.enabled : undefined; resourceInputs["fromRole"] = args ? args.fromRole : undefined; resourceInputs["fromType"] = args ? args.fromType : undefined; resourceInputs["sources"] = args ? args.sources : undefined; resourceInputs["toRole"] = args ? args.toRole : undefined; resourceInputs["toType"] = args ? args.toType : undefined; resourceInputs["typeOfRelation"] = args ? args.typeOfRelation : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(GenericRelationships.__pulumiType, name, resourceInputs, opts); } } exports.GenericRelationships = GenericRelationships; /** @internal */ GenericRelationships.__pulumiType = 'dynatrace:index/genericRelationships:GenericRelationships'; //# sourceMappingURL=genericRelationships.js.map