/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
import {
  Contract,
  ContractFactory,
  ContractTransactionResponse,
  Interface,
} from "ethers";
import type { Signer, ContractDeployTransaction, ContractRunner } from "ethers";
import type { NonPayableOverrides } from "../../../common";
import type {
  CollateralManagerMock,
  CollateralManagerMockInterface,
} from "../../../contracts/mock/CollateralManagerMock";

const _abi = [
  {
    inputs: [
      {
        internalType: "address",
        name: "_borrowerAddress",
        type: "address",
      },
      {
        components: [
          {
            internalType: "enum CollateralType",
            name: "_collateralType",
            type: "uint8",
          },
          {
            internalType: "uint256",
            name: "_amount",
            type: "uint256",
          },
          {
            internalType: "uint256",
            name: "_tokenId",
            type: "uint256",
          },
          {
            internalType: "address",
            name: "_collateralAddress",
            type: "address",
          },
        ],
        internalType: "struct Collateral[]",
        name: "_collateralInfo",
        type: "tuple[]",
      },
    ],
    name: "checkBalances",
    outputs: [
      {
        internalType: "bool",
        name: "validated_",
        type: "bool",
      },
      {
        internalType: "bool[]",
        name: "checks_",
        type: "bool[]",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
      {
        components: [
          {
            internalType: "enum CollateralType",
            name: "_collateralType",
            type: "uint8",
          },
          {
            internalType: "uint256",
            name: "_amount",
            type: "uint256",
          },
          {
            internalType: "uint256",
            name: "_tokenId",
            type: "uint256",
          },
          {
            internalType: "address",
            name: "_collateralAddress",
            type: "address",
          },
        ],
        internalType: "struct Collateral[]",
        name: "_collateralInfo",
        type: "tuple[]",
      },
    ],
    name: "commitCollateral",
    outputs: [
      {
        internalType: "bool",
        name: "validation_",
        type: "bool",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
      {
        components: [
          {
            internalType: "enum CollateralType",
            name: "_collateralType",
            type: "uint8",
          },
          {
            internalType: "uint256",
            name: "_amount",
            type: "uint256",
          },
          {
            internalType: "uint256",
            name: "_tokenId",
            type: "uint256",
          },
          {
            internalType: "address",
            name: "_collateralAddress",
            type: "address",
          },
        ],
        internalType: "struct Collateral",
        name: "_collateralInfo",
        type: "tuple",
      },
    ],
    name: "commitCollateral",
    outputs: [
      {
        internalType: "bool",
        name: "validation_",
        type: "bool",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [],
    name: "committedCollateralValid",
    outputs: [
      {
        internalType: "bool",
        name: "",
        type: "bool",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "deployAndDeposit",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [],
    name: "deployAndDepositWasCalled",
    outputs: [
      {
        internalType: "bool",
        name: "",
        type: "bool",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "bool",
        name: "_validation",
        type: "bool",
      },
    ],
    name: "forceSetCommitCollateralValidation",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
      {
        internalType: "address",
        name: "collateralAssetAddress",
        type: "address",
      },
    ],
    name: "getCollateralAmount",
    outputs: [
      {
        internalType: "uint256",
        name: "_amount",
        type: "uint256",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "getCollateralInfo",
    outputs: [
      {
        components: [
          {
            internalType: "enum CollateralType",
            name: "_collateralType",
            type: "uint8",
          },
          {
            internalType: "uint256",
            name: "_amount",
            type: "uint256",
          },
          {
            internalType: "uint256",
            name: "_tokenId",
            type: "uint256",
          },
          {
            internalType: "address",
            name: "_collateralAddress",
            type: "address",
          },
        ],
        internalType: "struct Collateral[]",
        name: "collateral_",
        type: "tuple[]",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "getEscrow",
    outputs: [
      {
        internalType: "address",
        name: "",
        type: "address",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "lenderClaimCollateral",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
      {
        internalType: "address",
        name: "_liquidatorAddress",
        type: "address",
      },
    ],
    name: "liquidateCollateral",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "revalidateCollateral",
    outputs: [
      {
        internalType: "bool",
        name: "",
        type: "bool",
      },
    ],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [
      {
        internalType: "uint256",
        name: "_bidId",
        type: "uint256",
      },
    ],
    name: "withdraw",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
] as const;

const _bytecode =
  "0x60806040526000805460ff1916600117905534801561001d57600080fd5b506105718061002d6000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063857919de1161008c578063cd98536b11610066578063cd98536b146101fe578063d6c20fa814610223578063e7ae746a14610258578063f0472c491461026557600080fd5b8063857919de146101aa5780638de16116146101be578063934b5d13146101de57600080fd5b80632e1a7d4d116100c85780632e1a7d4d146101315780633db051ea146101445780637d19e59614610165578063853c488d1461019157600080fd5b80631532dc45146100ef5780631d0498481461011f5780632b201e3014610131575b600080fd5b61010a6100fd366004610316565b505060005460ff16919050565b60405190151581526020015b60405180910390f35b60005461010a90610100900460ff1681565b61014261013f366004610362565b50565b005b61014261015236600461037b565b6000805460ff1916911515919091179055565b610179610173366004610362565b50600090565b6040516001600160a01b039091168152602001610116565b61010a61019f3660046103a4565b505060005460ff1690565b61010a6101b8366004610362565b50600190565b6101426101cc366004610362565b506000805461ff001916610100179055565b6101f16101ec366004610362565b610277565b60405161011691906103dc565b61021561020c366004610483565b6101f492915050565b604051908152602001610116565b61024a6102313660046104af565b5050604080516000815260208101909152600192909150565b6040516101169291906104e9565b60005461010a9060ff1681565b610142610273366004610483565b5050565b604080516000808252602082019092526060916102c3565b60408051608081018252600080825260208083018290529282018190526060820152825260001990920191018161028f5790505b5092915050565b60008083601f8401126102dc57600080fd5b50813567ffffffffffffffff8111156102f457600080fd5b6020830191508360208260071b850101111561030f57600080fd5b9250929050565b60008060006040848603121561032b57600080fd5b83359250602084013567ffffffffffffffff81111561034957600080fd5b610355868287016102ca565b9497909650939450505050565b60006020828403121561037457600080fd5b5035919050565b60006020828403121561038d57600080fd5b8135801515811461039d57600080fd5b9392505050565b60008082840360a08112156103b857600080fd5b833592506080601f19820112156103ce57600080fd5b506020830190509250929050565b60208082528251828201819052600091906040908185019086840185805b8381101561045957825180516003811061042257634e487b7160e01b84526021600452602484fd5b8652808801518887015286810151878701526060908101516001600160a01b031690860152608090940193918601916001016103fa565b509298975050505050505050565b80356001600160a01b038116811461047e57600080fd5b919050565b6000806040838503121561049657600080fd5b823591506104a660208401610467565b90509250929050565b6000806000604084860312156104c457600080fd5b6104cd84610467565b9250602084013567ffffffffffffffff81111561034957600080fd5b60006040820184151583526020604081850152818551808452606086019150828701935060005b8181101561052e578451151583529383019391830191600101610510565b509097965050505050505056fea26469706673582212205cd56892982c7292e98bc33382b54f7cc13b62e0dc6880fd7593a7665216375b64736f6c63430008090033";

type CollateralManagerMockConstructorParams =
  | [signer?: Signer]
  | ConstructorParameters<typeof ContractFactory>;

const isSuperArgs = (
  xs: CollateralManagerMockConstructorParams
): xs is ConstructorParameters<typeof ContractFactory> => xs.length > 1;

export class CollateralManagerMock__factory extends ContractFactory {
  constructor(...args: CollateralManagerMockConstructorParams) {
    if (isSuperArgs(args)) {
      super(...args);
    } else {
      super(_abi, _bytecode, args[0]);
    }
  }

  override getDeployTransaction(
    overrides?: NonPayableOverrides & { from?: string }
  ): Promise<ContractDeployTransaction> {
    return super.getDeployTransaction(overrides || {});
  }
  override deploy(overrides?: NonPayableOverrides & { from?: string }) {
    return super.deploy(overrides || {}) as Promise<
      CollateralManagerMock & {
        deploymentTransaction(): ContractTransactionResponse;
      }
    >;
  }
  override connect(
    runner: ContractRunner | null
  ): CollateralManagerMock__factory {
    return super.connect(runner) as CollateralManagerMock__factory;
  }

  static readonly bytecode = _bytecode;
  static readonly abi = _abi;
  static createInterface(): CollateralManagerMockInterface {
    return new Interface(_abi) as CollateralManagerMockInterface;
  }
  static connect(
    address: string,
    runner?: ContractRunner | null
  ): CollateralManagerMock {
    return new Contract(
      address,
      _abi,
      runner
    ) as unknown as CollateralManagerMock;
  }
}
