"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.DomainMapping = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
 * A domain serving an App Engine application.
 *
 * To get more information about DomainMapping, see:
 *
 * * [API documentation](https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1/apps.domainMappings)
 * * How-to Guides
 *     * [Official Documentation](https://cloud.google.com/appengine/docs/standard/python/mapping-custom-domains)
 *
 * ## Example Usage
 *
 * ### App Engine Domain Mapping Basic
 *
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 *
 * const domainMapping = new gcp.appengine.DomainMapping("domain_mapping", {
 *     domainName: "verified-domain.com",
 *     sslSettings: {
 *         sslManagementType: "AUTOMATIC",
 *     },
 * });
 * ```
 *
 * ## Import
 *
 * DomainMapping can be imported using any of these accepted formats:
 *
 * * `apps/{{project}}/domainMappings/{{domain_name}}`
 *
 * * `{{project}}/{{domain_name}}`
 *
 * * `{{domain_name}}`
 *
 * When using the `pulumi import` command, DomainMapping can be imported using one of the formats above. For example:
 *
 * ```sh
 * $ pulumi import gcp:appengine/domainMapping:DomainMapping default apps/{{project}}/domainMappings/{{domain_name}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:appengine/domainMapping:DomainMapping default {{project}}/{{domain_name}}
 * ```
 *
 * ```sh
 * $ pulumi import gcp:appengine/domainMapping:DomainMapping default {{domain_name}}
 * ```
 */
class DomainMapping extends pulumi.CustomResource {
    /**
     * Get an existing DomainMapping 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 DomainMapping(name, state, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of DomainMapping.  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'] === DomainMapping.__pulumiType;
    }
    constructor(name, argsOrState, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (opts.id) {
            const state = argsOrState;
            resourceInputs["domainName"] = state?.domainName;
            resourceInputs["name"] = state?.name;
            resourceInputs["overrideStrategy"] = state?.overrideStrategy;
            resourceInputs["project"] = state?.project;
            resourceInputs["resourceRecords"] = state?.resourceRecords;
            resourceInputs["sslSettings"] = state?.sslSettings;
        }
        else {
            const args = argsOrState;
            if (args?.domainName === undefined && !opts.urn) {
                throw new Error("Missing required property 'domainName'");
            }
            resourceInputs["domainName"] = args?.domainName;
            resourceInputs["overrideStrategy"] = args?.overrideStrategy;
            resourceInputs["project"] = args?.project;
            resourceInputs["sslSettings"] = args?.sslSettings;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["resourceRecords"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        super(DomainMapping.__pulumiType, name, resourceInputs, opts);
    }
}
exports.DomainMapping = DomainMapping;
/** @internal */
DomainMapping.__pulumiType = 'gcp:appengine/domainMapping:DomainMapping';
//# sourceMappingURL=domainMapping.js.map