UNPKG

@lubyou/pulumi-fortios

Version:

A Pulumi package for creating and managing fortios cloud resources.

79 lines 4.41 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.FirewallObjectService = void 0; const pulumi = require("@pulumi/pulumi"); const utilities = require("./utilities"); class FirewallObjectService extends pulumi.CustomResource { /** * Get an existing FirewallObjectService 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 FirewallObjectService(name, state, Object.assign(Object.assign({}, opts), { id: id })); } /** * Returns true if the given object is an instance of FirewallObjectService. 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'] === FirewallObjectService.__pulumiType; } constructor(name, argsOrState, opts) { let resourceInputs = {}; opts = opts || {}; if (opts.id) { const state = argsOrState; resourceInputs["category"] = state ? state.category : undefined; resourceInputs["comment"] = state ? state.comment : undefined; resourceInputs["fqdn"] = state ? state.fqdn : undefined; resourceInputs["icmpcode"] = state ? state.icmpcode : undefined; resourceInputs["icmptype"] = state ? state.icmptype : undefined; resourceInputs["iprange"] = state ? state.iprange : undefined; resourceInputs["name"] = state ? state.name : undefined; resourceInputs["protocol"] = state ? state.protocol : undefined; resourceInputs["protocolNumber"] = state ? state.protocolNumber : undefined; resourceInputs["sctpPortrange"] = state ? state.sctpPortrange : undefined; resourceInputs["sessionTtl"] = state ? state.sessionTtl : undefined; resourceInputs["tcpPortrange"] = state ? state.tcpPortrange : undefined; resourceInputs["udpPortrange"] = state ? state.udpPortrange : undefined; } else { const args = argsOrState; if ((!args || args.category === undefined) && !opts.urn) { throw new Error("Missing required property 'category'"); } if ((!args || args.protocol === undefined) && !opts.urn) { throw new Error("Missing required property 'protocol'"); } resourceInputs["category"] = args ? args.category : undefined; resourceInputs["comment"] = args ? args.comment : undefined; resourceInputs["fqdn"] = args ? args.fqdn : undefined; resourceInputs["icmpcode"] = args ? args.icmpcode : undefined; resourceInputs["icmptype"] = args ? args.icmptype : undefined; resourceInputs["iprange"] = args ? args.iprange : undefined; resourceInputs["name"] = args ? args.name : undefined; resourceInputs["protocol"] = args ? args.protocol : undefined; resourceInputs["protocolNumber"] = args ? args.protocolNumber : undefined; resourceInputs["sctpPortrange"] = args ? args.sctpPortrange : undefined; resourceInputs["sessionTtl"] = args ? args.sessionTtl : undefined; resourceInputs["tcpPortrange"] = args ? args.tcpPortrange : undefined; resourceInputs["udpPortrange"] = args ? args.udpPortrange : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(FirewallObjectService.__pulumiType, name, resourceInputs, opts); } } exports.FirewallObjectService = FirewallObjectService; /** @internal */ FirewallObjectService.__pulumiType = 'fortios:index/firewallObjectService:FirewallObjectService'; //# sourceMappingURL=firewallObjectService.js.map