"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.NetworkToNetworkInterconnect = void 0;
const pulumi = require("@pulumi/pulumi");
const inputs = require("../types/input");
const utilities = require("../utilities");
/**
 * The Network To Network Interconnect resource definition.
 *
 * Uses Azure REST API version 2023-06-15. In version 2.x of the Azure Native provider, it used API version 2023-02-01-preview.
 *
 * Other available API versions: 2023-02-01-preview. These can be accessed by generating a local SDK package using the CLI command `pulumi package add azure-native managednetworkfabric [ApiVersion]`. See the [version guide](../../../version-guide/#accessing-any-api-version-via-local-packages) for details.
 */
class NetworkToNetworkInterconnect extends pulumi.CustomResource {
    /**
     * Get an existing NetworkToNetworkInterconnect 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 opts Optional settings to control the behavior of the CustomResource.
     */
    static get(name, id, opts) {
        return new NetworkToNetworkInterconnect(name, undefined, { ...opts, id: id });
    }
    /**
     * Returns true if the given object is an instance of NetworkToNetworkInterconnect.  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'] === NetworkToNetworkInterconnect.__pulumiType;
    }
    /**
     * Create a NetworkToNetworkInterconnect resource with the given unique name, arguments, and options.
     *
     * @param name The _unique_ name of the resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param opts A bag of options that control this resource's behavior.
     */
    constructor(name, args, opts) {
        let resourceInputs = {};
        opts = opts || {};
        if (!opts.id) {
            if (args?.networkFabricName === undefined && !opts.urn) {
                throw new Error("Missing required property 'networkFabricName'");
            }
            if (args?.resourceGroupName === undefined && !opts.urn) {
                throw new Error("Missing required property 'resourceGroupName'");
            }
            if (args?.useOptionB === undefined && !opts.urn) {
                throw new Error("Missing required property 'useOptionB'");
            }
            resourceInputs["egressAclId"] = args?.egressAclId;
            resourceInputs["exportRoutePolicy"] = args?.exportRoutePolicy;
            resourceInputs["importRoutePolicy"] = args?.importRoutePolicy;
            resourceInputs["ingressAclId"] = args?.ingressAclId;
            resourceInputs["isManagementType"] = (args?.isManagementType) ?? "True";
            resourceInputs["layer2Configuration"] = args ? (args.layer2Configuration ? pulumi.output(args.layer2Configuration).apply(inputs.managednetworkfabric.layer2ConfigurationArgsProvideDefaults) : undefined) : undefined;
            resourceInputs["networkFabricName"] = args?.networkFabricName;
            resourceInputs["networkToNetworkInterconnectName"] = args?.networkToNetworkInterconnectName;
            resourceInputs["nniType"] = (args?.nniType) ?? "CE";
            resourceInputs["npbStaticRouteConfiguration"] = args ? (args.npbStaticRouteConfiguration ? pulumi.output(args.npbStaticRouteConfiguration).apply(inputs.managednetworkfabric.npbStaticRouteConfigurationArgsProvideDefaults) : undefined) : undefined;
            resourceInputs["optionBLayer3Configuration"] = args?.optionBLayer3Configuration;
            resourceInputs["resourceGroupName"] = args?.resourceGroupName;
            resourceInputs["useOptionB"] = args?.useOptionB;
            resourceInputs["administrativeState"] = undefined /*out*/;
            resourceInputs["azureApiVersion"] = undefined /*out*/;
            resourceInputs["configurationState"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["provisioningState"] = undefined /*out*/;
            resourceInputs["systemData"] = undefined /*out*/;
            resourceInputs["type"] = undefined /*out*/;
        }
        else {
            resourceInputs["administrativeState"] = undefined /*out*/;
            resourceInputs["azureApiVersion"] = undefined /*out*/;
            resourceInputs["configurationState"] = undefined /*out*/;
            resourceInputs["egressAclId"] = undefined /*out*/;
            resourceInputs["exportRoutePolicy"] = undefined /*out*/;
            resourceInputs["importRoutePolicy"] = undefined /*out*/;
            resourceInputs["ingressAclId"] = undefined /*out*/;
            resourceInputs["isManagementType"] = undefined /*out*/;
            resourceInputs["layer2Configuration"] = undefined /*out*/;
            resourceInputs["name"] = undefined /*out*/;
            resourceInputs["nniType"] = undefined /*out*/;
            resourceInputs["npbStaticRouteConfiguration"] = undefined /*out*/;
            resourceInputs["optionBLayer3Configuration"] = undefined /*out*/;
            resourceInputs["provisioningState"] = undefined /*out*/;
            resourceInputs["systemData"] = undefined /*out*/;
            resourceInputs["type"] = undefined /*out*/;
            resourceInputs["useOptionB"] = undefined /*out*/;
        }
        opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
        const aliasOpts = { aliases: [{ type: "azure-native:managednetworkfabric/v20230201preview:NetworkToNetworkInterconnect" }, { type: "azure-native:managednetworkfabric/v20230615:NetworkToNetworkInterconnect" }] };
        opts = pulumi.mergeOptions(opts, aliasOpts);
        super(NetworkToNetworkInterconnect.__pulumiType, name, resourceInputs, opts);
    }
}
exports.NetworkToNetworkInterconnect = NetworkToNetworkInterconnect;
/** @internal */
NetworkToNetworkInterconnect.__pulumiType = 'azure-native:managednetworkfabric:NetworkToNetworkInterconnect';
//# sourceMappingURL=data:application/json;base64, 