/* 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 { Cloner, ClonerInterface } from "../../../contracts/test/Cloner";

const _abi = [
  {
    inputs: [
      {
        internalType: "address",
        name: "_addr",
        type: "address",
      },
    ],
    stateMutability: "nonpayable",
    type: "constructor",
  },
  {
    inputs: [],
    name: "clone",
    outputs: [
      {
        internalType: "address",
        name: "",
        type: "address",
      },
    ],
    stateMutability: "view",
    type: "function",
  },
];

const _bytecode =
  "0x608060405234801561001057600080fd5b5060405161018838038061018883398101604081905261002f916100c8565b806001600160a01b03166309ed46076040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561006a57600080fd5b505af115801561007e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906100a291906100c8565b600080546001600160a01b0319166001600160a01b0392909216919091179055506100f8565b6000602082840312156100da57600080fd5b81516001600160a01b03811681146100f157600080fd5b9392505050565b6082806101066000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c806309ed460714602d575b600080fd5b600054604c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390f3fea164736f6c6343000809000a";

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

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

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

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

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