"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.BillingAccountExclusion = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * ## Example Usage
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const my_exclusion = new gcp.logging.BillingAccountExclusion("my-exclusion", {
 *     name: "my-instance-debug-exclusion",
 *     billingAccount: "ABCDEF-012345-GHIJKL",
 *     description: "Exclude GCE instance debug logs",
 *     filter: "resource.type = gce_instance AND severity <= DEBUG",
 * });
 * ```
 *
 * ## Import
 *
 * Billing account logging exclusions can be imported using their URI, e.g.
 *
 * * `billingAccounts/{{billing_account}}/exclusions/{{name}}`
 *
 * When using the `pulumi import` command, billing account logging exclusions can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:logging/billingAccountExclusion:BillingAccountExclusion default billingAccounts/{{billing_account}}/exclusions/{{name}}
 * ```
 */
class BillingAccountExclusion extends pulumi.CustomResource {
    /**
     * Get an existing BillingAccountExclusion 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 BillingAccountExclusion(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of BillingAccountExclusion.  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'] === BillingAccountExclusion.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["billingAccount"] = state?.billingAccount;
            resourceInputs["description"] = state?.description;
            resourceInputs["disabled"] = state?.disabled;
            resourceInputs["filter"] = state?.filter;
            resourceInputs["name"] = state?.name;
        }
        else {
            const args = argsOrState;
            if (args?.billingAccount === undefined && !opts.urn) {
                throw new Error("Missing required property 'billingAccount'");
            }
            if (args?.filter === undefined && !opts.urn) {
                throw new Error("Missing required property 'filter'");
            }
            resourceInputs["billingAccount"] = args?.billingAccount;
            resourceInputs["description"] = args?.description;
            resourceInputs["disabled"] = args?.disabled;
            resourceInputs["filter"] = args?.filter;
            resourceInputs["name"] = args?.name;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(BillingAccountExclusion.__pulumiType, name, resourceInputs, opts);
    }
}
exports.BillingAccountExclusion = BillingAccountExclusion;
/** @internal */
BillingAccountExclusion.__pulumiType = 'gcp:logging/billingAccountExclusion:BillingAccountExclusion';
//# sourceMappingURL=billingAccountExclusion.js.map