/* Autogenerated file. Do not edit manually. */
/* tslint:disable */
/* eslint-disable */
import { Signer, utils, Contract, ContractFactory, Overrides } from "ethers";
import type { Provider, TransactionRequest } from "@ethersproject/providers";
import type { PromiseOrValue } from "../../../common";
import type {
  FlashLoaner,
  FlashLoanerInterface,
} from "../../../contracts/test/FlashLoaner";

const _abi = [
  {
    inputs: [
      {
        internalType: "address",
        name: "_token",
        type: "address",
      },
    ],
    stateMutability: "nonpayable",
    type: "constructor",
  },
  {
    inputs: [
      {
        internalType: "address",
        name: "add1",
        type: "address",
      },
      {
        internalType: "address",
        name: "add2",
        type: "address",
      },
      {
        internalType: "uint256",
        name: "val1",
        type: "uint256",
      },
      {
        internalType: "uint256",
        name: "val2",
        type: "uint256",
      },
    ],
    name: "flashLoan",
    outputs: [],
    stateMutability: "nonpayable",
    type: "function",
  },
  {
    inputs: [],
    name: "token",
    outputs: [
      {
        internalType: "address",
        name: "",
        type: "address",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
];

const _bytecode =
  "0x608060405234801561001057600080fd5b5060405161033d38038061033d83398101604081905261002f91610054565b600080546001600160a01b0319166001600160a01b0392909216919091179055610084565b60006020828403121561006657600080fd5b81516001600160a01b038116811461007d57600080fd5b9392505050565b6102aa806100936000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c8063c9c3f2ad1461003b578063fc0c546a14610050575b600080fd5b61004e610049366004610232565b610099565b005b6000546100709073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f35b6000546040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8681166004830152858116602483015260448201859052909116906323b872dd90606401602060405180830381600087803b15801561011557600080fd5b505af1158015610129573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061014d9190610274565b506000546040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152868116602483015260448201849052909116906323b872dd90606401602060405180830381600087803b1580156101ca57600080fd5b505af11580156101de573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906102029190610274565b5050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461022d57600080fd5b919050565b6000806000806080858703121561024857600080fd5b61025185610209565b935061025f60208601610209565b93969395505050506040820135916060013590565b60006020828403121561028657600080fd5b8151801515811461029657600080fd5b939250505056fea164736f6c6343000809000a";

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

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

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

  override deploy(
    _token: PromiseOrValue<string>,
    overrides?: Overrides & { from?: PromiseOrValue<string> }
  ): Promise<FlashLoaner> {
    return super.deploy(_token, overrides || {}) as Promise<FlashLoaner>;
  }
  override getDeployTransaction(
    _token: PromiseOrValue<string>,
    overrides?: Overrides & { from?: PromiseOrValue<string> }
  ): TransactionRequest {
    return super.getDeployTransaction(_token, overrides || {});
  }
  override attach(address: string): FlashLoaner {
    return super.attach(address) as FlashLoaner;
  }
  override connect(signer: Signer): FlashLoaner__factory {
    return super.connect(signer) as FlashLoaner__factory;
  }

  static readonly bytecode = _bytecode;
  static readonly abi = _abi;
  static createInterface(): FlashLoanerInterface {
    return new utils.Interface(_abi) as FlashLoanerInterface;
  }
  static connect(
    address: string,
    signerOrProvider: Signer | Provider
  ): FlashLoaner {
    return new Contract(address, _abi, signerOrProvider) as FlashLoaner;
  }
}
