"use strict";
var __extends = (this && this.__extends) || (function () {
    var extendStatics = function (d, b) {
        extendStatics = Object.setPrototypeOf ||
            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
            function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
        return extendStatics(d, b);
    };
    return function (d, b) {
        if (typeof b !== "function" && b !== null)
            throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
        extendStatics(d, b);
        function __() { this.constructor = d; }
        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
    };
})();
var __read = (this && this.__read) || function (o, n) {
    var m = typeof Symbol === "function" && o[Symbol.iterator];
    if (!m) return o;
    var i = m.call(o), r, ar = [], e;
    try {
        while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
    }
    catch (error) { e = { error: error }; }
    finally {
        try {
            if (r && !r.done && (m = i["return"])) m.call(i);
        }
        finally { if (e) throw e.error; }
    }
    return ar;
};
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
    if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
        if (ar || !(i in from)) {
            if (!ar) ar = Array.prototype.slice.call(from, 0, i);
            ar[i] = from[i];
        }
    }
    return to.concat(ar || Array.prototype.slice.call(from));
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.LinkableAnchorMock__factory = void 0;
/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
var ethers_1 = require("ethers");
var _abi = [
    {
        inputs: [
            {
                internalType: "address",
                name: "_handler",
                type: "address",
            },
            {
                internalType: "contract IAnchorVerifier",
                name: "_verifier",
                type: "address",
            },
            {
                internalType: "contract IHasher",
                name: "_hasher",
                type: "address",
            },
            {
                internalType: "uint32",
                name: "_merkleTreeHeight",
                type: "uint32",
            },
            {
                internalType: "uint8",
                name: "_maxEdges",
                type: "uint8",
            },
        ],
        stateMutability: "nonpayable",
        type: "constructor",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: false,
                internalType: "uint256",
                name: "chainID",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "uint256",
                name: "latestLeafIndex",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "uint256",
                name: "merkleRoot",
                type: "uint256",
            },
        ],
        name: "EdgeAddition",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: false,
                internalType: "uint256",
                name: "chainID",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "uint256",
                name: "latestLeafIndex",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "uint256",
                name: "merkleRoot",
                type: "uint256",
            },
        ],
        name: "EdgeUpdate",
        type: "event",
    },
    {
        anonymous: false,
        inputs: [
            {
                indexed: true,
                internalType: "uint256",
                name: "commitment",
                type: "uint256",
            },
            {
                indexed: false,
                internalType: "uint32",
                name: "leafIndex",
                type: "uint32",
            },
            {
                indexed: false,
                internalType: "uint256",
                name: "timestamp",
                type: "uint256",
            },
            {
                indexed: true,
                internalType: "uint256",
                name: "newMerkleRoot",
                type: "uint256",
            },
        ],
        name: "Insertion",
        type: "event",
    },
    {
        inputs: [],
        name: "EVM_CHAIN_ID_TYPE",
        outputs: [
            {
                internalType: "bytes2",
                name: "",
                type: "bytes2",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "FIELD_SIZE",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "ROOT_HISTORY_SIZE",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "ZERO_VALUE",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "commitments",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_maximumDepositAmount",
                type: "uint256",
            },
            {
                internalType: "uint32",
                name: "_nonce",
                type: "uint32",
            },
        ],
        name: "configureMaximumDepositLimit",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_minimalWithdrawalAmount",
                type: "uint256",
            },
            {
                internalType: "uint32",
                name: "_nonce",
                type: "uint32",
            },
        ],
        name: "configureMinimalWithdrawalLimit",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "currentNeighborRootIndex",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "currentRootIndex",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "edgeExistsForChain",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "edgeIndex",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "edgeList",
        outputs: [
            {
                internalType: "uint256",
                name: "chainID",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "root",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "latestLeafIndex",
                type: "uint256",
            },
            {
                internalType: "bytes32",
                name: "srcResourceID",
                type: "bytes32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "filledSubtrees",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getChainId",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getChainIdType",
        outputs: [
            {
                internalType: "uint48",
                name: "",
                type: "uint48",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getHasher",
        outputs: [
            {
                internalType: "contract IHasher",
                name: "",
                type: "address",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getLastRoot",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getLatestNeighborEdges",
        outputs: [
            {
                components: [
                    {
                        internalType: "uint256",
                        name: "chainID",
                        type: "uint256",
                    },
                    {
                        internalType: "uint256",
                        name: "root",
                        type: "uint256",
                    },
                    {
                        internalType: "uint256",
                        name: "latestLeafIndex",
                        type: "uint256",
                    },
                    {
                        internalType: "bytes32",
                        name: "srcResourceID",
                        type: "bytes32",
                    },
                ],
                internalType: "struct Edge[]",
                name: "",
                type: "tuple[]",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getLatestNeighborRoots",
        outputs: [
            {
                internalType: "uint256[]",
                name: "",
                type: "uint256[]",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getLevels",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getNextIndex",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "getProposalNonce",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint32",
                name: "index",
                type: "uint32",
            },
        ],
        name: "getZeroHash",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "handler",
        outputs: [
            {
                internalType: "address",
                name: "",
                type: "address",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_chainID",
                type: "uint256",
            },
        ],
        name: "hasEdge",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_left",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "_right",
                type: "uint256",
            },
        ],
        name: "hashLeftRight",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "hasher",
        outputs: [
            {
                internalType: "contract IHasher",
                name: "",
                type: "address",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "initialize",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [],
        name: "initialized",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "resourceID",
                type: "bytes32",
            },
        ],
        name: "isCorrectExecutionChain",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "resourceId",
                type: "bytes32",
            },
        ],
        name: "isCorrectExecutionContext",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_neighborChainID",
                type: "uint256",
            },
            {
                internalType: "uint256",
                name: "_root",
                type: "uint256",
            },
        ],
        name: "isKnownNeighborRoot",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_root",
                type: "uint256",
            },
        ],
        name: "isKnownRoot",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256[]",
                name: "_roots",
                type: "uint256[]",
            },
        ],
        name: "isValidRoots",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "levels",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "maxEdges",
        outputs: [
            {
                internalType: "uint8",
                name: "",
                type: "uint8",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        name: "neighborRoots",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "nextIndex",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "nullifierHashes",
        outputs: [
            {
                internalType: "bool",
                name: "",
                type: "bool",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [],
        name: "outerLevels",
        outputs: [
            {
                internalType: "uint32",
                name: "",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "bytes32",
                name: "_resourceId",
                type: "bytes32",
            },
        ],
        name: "parseChainIdFromResourceId",
        outputs: [
            {
                internalType: "uint64",
                name: "",
                type: "uint64",
            },
        ],
        stateMutability: "pure",
        type: "function",
    },
    {
        inputs: [],
        name: "proposalNonce",
        outputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "",
                type: "uint256",
            },
        ],
        name: "roots",
        outputs: [
            {
                internalType: "uint256",
                name: "root",
                type: "uint256",
            },
            {
                internalType: "uint32",
                name: "latestLeafindex",
                type: "uint32",
            },
        ],
        stateMutability: "view",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "address",
                name: "_handler",
                type: "address",
            },
            {
                internalType: "uint32",
                name: "_nonce",
                type: "uint32",
            },
        ],
        name: "setHandler",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "address",
                name: "_verifier",
                type: "address",
            },
            {
                internalType: "uint32",
                name: "_nonce",
                type: "uint32",
            },
        ],
        name: "setVerifier",
        outputs: [],
        stateMutability: "nonpayable",
        type: "function",
    },
    {
        inputs: [
            {
                internalType: "uint256",
                name: "_root",
                type: "uint256",
            },
            {
                internalType: "uint32",
                name: "_leafIndex",
                type: "uint32",
            },
            {
                internalType: "bytes32",
                name: "_srcResourceID",
                type: "bytes32",
            },
        ],
        name: "updateEdge",
        outputs: [],
        stateMutability: "payable",
        type: "function",
    },
];
var _bytecode = " ";
var isSuperArgs = function (xs) { return xs.length > 1; };
var LinkableAnchorMock__factory = exports.LinkableAnchorMock__factory = /** @class */ (function (_super) {
    __extends(LinkableAnchorMock__factory, _super);
    function LinkableAnchorMock__factory() {
        var args = [];
        for (var _i = 0; _i < arguments.length; _i++) {
            args[_i] = arguments[_i];
        }
        var _this = this;
        if (isSuperArgs(args)) {
            _this = _super.apply(this, __spreadArray([], __read(args), false)) || this;
        }
        else {
            _this = _super.call(this, _abi, _bytecode, args[0]) || this;
        }
        return _this;
    }
    LinkableAnchorMock__factory.prototype.deploy = function (_handler, _verifier, _hasher, _merkleTreeHeight, _maxEdges, overrides) {
        return _super.prototype.deploy.call(this, _handler, _verifier, _hasher, _merkleTreeHeight, _maxEdges, overrides || {});
    };
    LinkableAnchorMock__factory.prototype.getDeployTransaction = function (_handler, _verifier, _hasher, _merkleTreeHeight, _maxEdges, overrides) {
        return _super.prototype.getDeployTransaction.call(this, _handler, _verifier, _hasher, _merkleTreeHeight, _maxEdges, overrides || {});
    };
    LinkableAnchorMock__factory.prototype.attach = function (address) {
        return _super.prototype.attach.call(this, address);
    };
    LinkableAnchorMock__factory.prototype.connect = function (signer) {
        return _super.prototype.connect.call(this, signer);
    };
    LinkableAnchorMock__factory.createInterface = function () {
        return new ethers_1.utils.Interface(_abi);
    };
    LinkableAnchorMock__factory.connect = function (address, signerOrProvider) {
        return new ethers_1.Contract(address, _abi, signerOrProvider);
    };
    LinkableAnchorMock__factory.bytecode = _bytecode;
    LinkableAnchorMock__factory.abi = _abi;
    return LinkableAnchorMock__factory;
}(ethers_1.ContractFactory));
