import { BinaryDecisionDiagram } from "@smithy/core/endpoints";
const s = "ref";
const a = -1, b = false, c = true, d = "isSet", e = "booleanEquals", f = "coalesce", g = "PartitionResult", h = "stringEquals", i = "getAttr", j = "https://signin.{Region}.{PartitionResult#dualStackDnsSuffix}", k = { [s]: "Endpoint" }, l = { "fn": i, "argv": [{ [s]: g }, "name"] }, m = { [s]: "Region" }, n = { [s]: g }, o = { "authSchemes": [{ "name": "sigv4", "signingName": "signin", "signingRegion": "{Region}" }] }, p = {}, q = [m];
const _data = {
    conditions: [
        [d, q],
        [e, [{ fn: f, argv: [{ [s]: "IsControlPlane" }, b] }, c]],
        [d, [k]],
        ["aws.partition", q, g],
        [e, [{ [s]: "UseFIPS" }, c]],
        [h, [l, "aws"]],
        [e, [{ fn: f, argv: [{ [s]: "IsOAuthEndpoint" }, b] }, c]],
        [e, [{ [s]: "UseDualStack" }, c]],
        [h, [l, "aws-cn"]],
        [h, [m, "us-gov-west-1"]],
        [h, [l, "aws-us-gov"]],
        [e, [{ fn: i, argv: [n, "supportsFIPS"] }, c]],
        [h, [l, "aws-iso"]],
        [h, [l, "aws-iso-b"]],
        [h, [l, "aws-iso-f"]],
        [h, [l, "aws-iso-e"]],
        [h, [l, "aws-eusc"]],
        [e, [{ fn: i, argv: [n, "supportsDualStack"] }, c]]
    ],
    results: [
        [a],
        ["https://signin.{Region}.api.aws", o],
        ["https://signin.{Region}.api.amazonwebservices.com.cn", o],
        [j, o],
        [a, "FIPS endpoints are not supported for OAuth operations. Disable FIPS or use a non-OAuth operation."],
        ["https://{Region}.oauth.signin.aws", o],
        ["https://{Region}.signin.aws.amazon.com", p],
        ["https://{Region}.signin.amazonaws.cn", p],
        ["https://{Region}.signin.amazonaws-us-gov.com", p],
        ["https://{Region}.signin.c2shome.ic.gov", p],
        ["https://{Region}.signin.sc2shome.sgov.gov", p],
        ["https://{Region}.signin.csphome.hci.ic.gov", p],
        ["https://{Region}.signin.csphome.adc-e.uk", p],
        ["https://{Region}.signin.amazonaws-eusc.eu", p],
        ["https://signin-fips.amazonaws-us-gov.com", p],
        ["https://{Region}.signin-fips.amazonaws-us-gov.com", p],
        ["https://{Region}.signin.{PartitionResult#dnsSuffix}", p],
        [a, "Invalid Configuration: FIPS and custom endpoint are not supported"],
        [a, "Invalid Configuration: Dualstack and custom endpoint are not supported"],
        [k, p],
        ["https://signin-fips.{Region}.{PartitionResult#dualStackDnsSuffix}", p],
        [a, "FIPS and DualStack are enabled, but this partition does not support one or both"],
        ["https://signin-fips.{Region}.{PartitionResult#dnsSuffix}", p],
        [a, "FIPS is enabled but this partition does not support FIPS"],
        [j, p],
        [a, "DualStack is enabled but this partition does not support DualStack"],
        ["https://signin.{Region}.{PartitionResult#dnsSuffix}", p],
        [a, "Invalid Configuration: Missing Region"]
    ]
};
const root = 2;
const r = 100_000_000;
const nodes = new Int32Array([
    -1, 1, -1,
    0, 6, 3,
    2, 36, 4,
    4, 5, r + 27,
    6, r + 4, r + 27,
    1, 29, 7,
    2, 36, 8,
    3, 9, 31,
    4, 22, 10,
    5, 19, 11,
    7, 21, 12,
    8, r + 7, 13,
    10, r + 8, 14,
    12, r + 9, 15,
    13, r + 10, 16,
    14, r + 11, 17,
    15, r + 12, 18,
    16, r + 13, r + 16,
    6, r + 5, 20,
    7, 21, r + 6,
    17, r + 24, r + 25,
    6, r + 4, 23,
    7, 27, 24,
    9, r + 14, 25,
    10, r + 15, 26,
    11, r + 22, r + 23,
    11, 28, r + 21,
    17, r + 20, r + 21,
    2, 35, 30,
    3, 39, 31,
    4, 32, r + 27,
    6, r + 4, 33,
    7, r + 27, 34,
    9, r + 14, r + 27,
    3, 39, 36,
    4, 38, 37,
    7, r + 18, r + 19,
    6, r + 4, r + 17,
    5, r + 1, 40,
    8, r + 2, r + 3,
]);
export const bdd = BinaryDecisionDiagram.from(nodes, root, _data.conditions, _data.results);
