ethers#BaseContract TypeScript Examples

The following examples show how to use ethers#BaseContract. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: deploymentUtils.ts    From gateway-sol with GNU General Public License v3.0 6 votes vote down vote up
setupGetExistingDeployment =
    (hre: HardhatRuntimeEnvironment) =>
    async <T extends BaseContract>(name: string): Promise<T | null> => {
        const { deployments, getNamedAccounts, ethers, network } = hre;
        const { getOrNull } = deployments;

        if (network.name === "hardhat") {
            return null;
        }

        const { deployer } = await getNamedAccounts();
        const result = await getOrNull(name);

        return result ? await ethers.getContractAt<T>(name, result.address, deployer) : result;
    }
Example #2
Source File: CrossDomainEnabled.d.ts    From nova with GNU Affero General Public License v3.0 5 votes vote down vote up
export class CrossDomainEnabled extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: CrossDomainEnabledInterface;

  functions: {
    CROSS_DOMAIN_MESSENGER(overrides?: CallOverrides): Promise<[string]>;
  };

  CROSS_DOMAIN_MESSENGER(overrides?: CallOverrides): Promise<string>;

  callStatic: {
    CROSS_DOMAIN_MESSENGER(overrides?: CallOverrides): Promise<string>;
  };

  filters: {};

  estimateGas: {
    CROSS_DOMAIN_MESSENGER(overrides?: CallOverrides): Promise<BigNumber>;
  };

  populateTransaction: {
    CROSS_DOMAIN_MESSENGER(
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;
  };
}
Example #3
Source File: Eip2612.d.ts    From limit-orders-lib with GNU General Public License v3.0 5 votes vote down vote up
export class Eip2612 extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: Eip2612Interface;

  functions: {
    nonces(owner: string, overrides?: CallOverrides): Promise<[BigNumber]>;

    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>;
  };

  nonces(owner: string, overrides?: CallOverrides): Promise<BigNumber>;

  DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<string>;

  callStatic: {
    nonces(owner: string, overrides?: CallOverrides): Promise<BigNumber>;

    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<string>;
  };

  filters: {};

  estimateGas: {
    nonces(owner: string, overrides?: CallOverrides): Promise<BigNumber>;

    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<BigNumber>;
  };

  populateTransaction: {
    nonces(
      owner: string,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<PopulatedTransaction>;
  };
}
Example #4
Source File: deploymentUtils.ts    From gateway-sol with GNU General Public License v3.0 5 votes vote down vote up
getContractAt =
    (hre: HardhatRuntimeEnvironment) =>
    async <T extends BaseContract>(name: string, address: string) => {
        const { getNamedAccounts, ethers } = hre;
        const { deployer } = await getNamedAccounts();
        return await ethers.getContractAt<T>(name, address, deployer);
    }
Example #5
Source File: ERC165.d.ts    From shoyu with MIT License 5 votes vote down vote up
export class ERC165 extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: ERC165Interface;

  functions: {
    supportsInterface(
      interfaceId: BytesLike,
      overrides?: CallOverrides
    ): Promise<[boolean]>;
  };

  supportsInterface(
    interfaceId: BytesLike,
    overrides?: CallOverrides
  ): Promise<boolean>;

  callStatic: {
    supportsInterface(
      interfaceId: BytesLike,
      overrides?: CallOverrides
    ): Promise<boolean>;
  };

  filters: {};

  estimateGas: {
    supportsInterface(
      interfaceId: BytesLike,
      overrides?: CallOverrides
    ): Promise<BigNumber>;
  };

  populateTransaction: {
    supportsInterface(
      interfaceId: BytesLike,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;
  };
}
Example #6
Source File: Auth.d.ts    From nova with GNU Affero General Public License v3.0 4 votes vote down vote up
export class Auth extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: AuthInterface;

  functions: {
    authority(overrides?: CallOverrides): Promise<[string]>;

    owner(overrides?: CallOverrides): Promise<[string]>;

    setAuthority(
      newAuthority: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    setOwner(
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;
  };

  authority(overrides?: CallOverrides): Promise<string>;

  owner(overrides?: CallOverrides): Promise<string>;

  setAuthority(
    newAuthority: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  setOwner(
    newOwner: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  callStatic: {
    authority(overrides?: CallOverrides): Promise<string>;

    owner(overrides?: CallOverrides): Promise<string>;

    setAuthority(
      newAuthority: string,
      overrides?: CallOverrides
    ): Promise<void>;

    setOwner(newOwner: string, overrides?: CallOverrides): Promise<void>;
  };

  filters: {
    AuthorityUpdated(
      authority?: string | null
    ): TypedEventFilter<[string], { authority: string }>;

    OwnerUpdated(
      owner?: string | null
    ): TypedEventFilter<[string], { owner: string }>;
  };

  estimateGas: {
    authority(overrides?: CallOverrides): Promise<BigNumber>;

    owner(overrides?: CallOverrides): Promise<BigNumber>;

    setAuthority(
      newAuthority: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    setOwner(
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;
  };

  populateTransaction: {
    authority(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    owner(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    setAuthority(
      newAuthority: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    setOwner(
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;
  };
}
Example #7
Source File: Admin.d.ts    From hypervisor with The Unlicense 4 votes vote down vote up
export class Admin extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: AdminInterface;

  functions: {
    addBaseLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    addLimitLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    admin(overrides?: CallOverrides): Promise<[string]>;

    advisor(overrides?: CallOverrides): Promise<[string]>;

    appendList(
      _hypervisor: string,
      listed: string[],
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    pendingFees(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    pullLiquidity(
      _hypervisor: string,
      shares: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    rebalance(
      _hypervisor: string,
      _baseLower: BigNumberish,
      _baseUpper: BigNumberish,
      _limitLower: BigNumberish,
      _limitUpper: BigNumberish,
      _feeRecipient: string,
      swapQuantity: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    removeListed(
      _hypervisor: string,
      listed: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    rescueERC20(
      token: string,
      recipient: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    setDepositMax(
      _hypervisor: string,
      _deposit0Max: BigNumberish,
      _deposit1Max: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    setMaxTotalSupply(
      _hypervisor: string,
      _maxTotalSupply: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    toggleWhitelist(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    transferAdmin(
      newAdmin: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    transferAdvisor(
      newAdvisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    transferHypervisorOwner(
      _hypervisor: string,
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;
  };

  addBaseLiquidity(
    _hypervisor: string,
    amount0: BigNumberish,
    amount1: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  addLimitLiquidity(
    _hypervisor: string,
    amount0: BigNumberish,
    amount1: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  admin(overrides?: CallOverrides): Promise<string>;

  advisor(overrides?: CallOverrides): Promise<string>;

  appendList(
    _hypervisor: string,
    listed: string[],
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  pendingFees(
    _hypervisor: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  pullLiquidity(
    _hypervisor: string,
    shares: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  rebalance(
    _hypervisor: string,
    _baseLower: BigNumberish,
    _baseUpper: BigNumberish,
    _limitLower: BigNumberish,
    _limitUpper: BigNumberish,
    _feeRecipient: string,
    swapQuantity: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  removeListed(
    _hypervisor: string,
    listed: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  rescueERC20(
    token: string,
    recipient: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  setDepositMax(
    _hypervisor: string,
    _deposit0Max: BigNumberish,
    _deposit1Max: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  setMaxTotalSupply(
    _hypervisor: string,
    _maxTotalSupply: BigNumberish,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  toggleWhitelist(
    _hypervisor: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  transferAdmin(
    newAdmin: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  transferAdvisor(
    newAdvisor: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  transferHypervisorOwner(
    _hypervisor: string,
    newOwner: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  callStatic: {
    addBaseLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: CallOverrides
    ): Promise<void>;

    addLimitLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: CallOverrides
    ): Promise<void>;

    admin(overrides?: CallOverrides): Promise<string>;

    advisor(overrides?: CallOverrides): Promise<string>;

    appendList(
      _hypervisor: string,
      listed: string[],
      overrides?: CallOverrides
    ): Promise<void>;

    pendingFees(
      _hypervisor: string,
      overrides?: CallOverrides
    ): Promise<[BigNumber, BigNumber] & { fees0: BigNumber; fees1: BigNumber }>;

    pullLiquidity(
      _hypervisor: string,
      shares: BigNumberish,
      overrides?: CallOverrides
    ): Promise<
      [BigNumber, BigNumber, BigNumber, BigNumber] & {
        base0: BigNumber;
        base1: BigNumber;
        limit0: BigNumber;
        limit1: BigNumber;
      }
    >;

    rebalance(
      _hypervisor: string,
      _baseLower: BigNumberish,
      _baseUpper: BigNumberish,
      _limitLower: BigNumberish,
      _limitUpper: BigNumberish,
      _feeRecipient: string,
      swapQuantity: BigNumberish,
      overrides?: CallOverrides
    ): Promise<void>;

    removeListed(
      _hypervisor: string,
      listed: string,
      overrides?: CallOverrides
    ): Promise<void>;

    rescueERC20(
      token: string,
      recipient: string,
      overrides?: CallOverrides
    ): Promise<void>;

    setDepositMax(
      _hypervisor: string,
      _deposit0Max: BigNumberish,
      _deposit1Max: BigNumberish,
      overrides?: CallOverrides
    ): Promise<void>;

    setMaxTotalSupply(
      _hypervisor: string,
      _maxTotalSupply: BigNumberish,
      overrides?: CallOverrides
    ): Promise<void>;

    toggleWhitelist(
      _hypervisor: string,
      overrides?: CallOverrides
    ): Promise<void>;

    transferAdmin(newAdmin: string, overrides?: CallOverrides): Promise<void>;

    transferAdvisor(
      newAdvisor: string,
      overrides?: CallOverrides
    ): Promise<void>;

    transferHypervisorOwner(
      _hypervisor: string,
      newOwner: string,
      overrides?: CallOverrides
    ): Promise<void>;
  };

  filters: {};

  estimateGas: {
    addBaseLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    addLimitLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    admin(overrides?: CallOverrides): Promise<BigNumber>;

    advisor(overrides?: CallOverrides): Promise<BigNumber>;

    appendList(
      _hypervisor: string,
      listed: string[],
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    pendingFees(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    pullLiquidity(
      _hypervisor: string,
      shares: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    rebalance(
      _hypervisor: string,
      _baseLower: BigNumberish,
      _baseUpper: BigNumberish,
      _limitLower: BigNumberish,
      _limitUpper: BigNumberish,
      _feeRecipient: string,
      swapQuantity: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    removeListed(
      _hypervisor: string,
      listed: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    rescueERC20(
      token: string,
      recipient: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    setDepositMax(
      _hypervisor: string,
      _deposit0Max: BigNumberish,
      _deposit1Max: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    setMaxTotalSupply(
      _hypervisor: string,
      _maxTotalSupply: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    toggleWhitelist(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    transferAdmin(
      newAdmin: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    transferAdvisor(
      newAdvisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    transferHypervisorOwner(
      _hypervisor: string,
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;
  };

  populateTransaction: {
    addBaseLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    addLimitLiquidity(
      _hypervisor: string,
      amount0: BigNumberish,
      amount1: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    admin(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    advisor(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    appendList(
      _hypervisor: string,
      listed: string[],
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    pendingFees(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    pullLiquidity(
      _hypervisor: string,
      shares: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    rebalance(
      _hypervisor: string,
      _baseLower: BigNumberish,
      _baseUpper: BigNumberish,
      _limitLower: BigNumberish,
      _limitUpper: BigNumberish,
      _feeRecipient: string,
      swapQuantity: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    removeListed(
      _hypervisor: string,
      listed: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    rescueERC20(
      token: string,
      recipient: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    setDepositMax(
      _hypervisor: string,
      _deposit0Max: BigNumberish,
      _deposit1Max: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    setMaxTotalSupply(
      _hypervisor: string,
      _maxTotalSupply: BigNumberish,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    toggleWhitelist(
      _hypervisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    transferAdmin(
      newAdmin: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    transferAdvisor(
      newAdvisor: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    transferHypervisorOwner(
      _hypervisor: string,
      newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;
  };
}
Example #8
Source File: ArgentWalletDetector.d.ts    From limit-orders-lib with GNU General Public License v3.0 4 votes vote down vote up
export class ArgentWalletDetector extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: ArgentWalletDetectorInterface;

  functions: {
    acceptedCodes(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

    acceptedImplementations(
      arg0: string,
      overrides?: CallOverrides
    ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

    addCode(
      _code: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    addCodeAndImplementationFromWallet(
      _argentWallet: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    addImplementation(
      _impl: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    changeOwner(
      _newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    getCodes(overrides?: CallOverrides): Promise<[string[]]>;

    getImplementations(overrides?: CallOverrides): Promise<[string[]]>;

    isArgentWallet(
      _wallet: string,
      overrides?: CallOverrides
    ): Promise<[boolean]>;

    owner(overrides?: CallOverrides): Promise<[string]>;
  };

  acceptedCodes(
    arg0: BytesLike,
    overrides?: CallOverrides
  ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

  acceptedImplementations(
    arg0: string,
    overrides?: CallOverrides
  ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

  addCode(
    _code: BytesLike,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  addCodeAndImplementationFromWallet(
    _argentWallet: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  addImplementation(
    _impl: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  changeOwner(
    _newOwner: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  getCodes(overrides?: CallOverrides): Promise<string[]>;

  getImplementations(overrides?: CallOverrides): Promise<string[]>;

  isArgentWallet(_wallet: string, overrides?: CallOverrides): Promise<boolean>;

  owner(overrides?: CallOverrides): Promise<string>;

  callStatic: {
    acceptedCodes(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

    acceptedImplementations(
      arg0: string,
      overrides?: CallOverrides
    ): Promise<[boolean, BigNumber] & { exists: boolean; index: BigNumber }>;

    addCode(_code: BytesLike, overrides?: CallOverrides): Promise<void>;

    addCodeAndImplementationFromWallet(
      _argentWallet: string,
      overrides?: CallOverrides
    ): Promise<void>;

    addImplementation(_impl: string, overrides?: CallOverrides): Promise<void>;

    changeOwner(_newOwner: string, overrides?: CallOverrides): Promise<void>;

    getCodes(overrides?: CallOverrides): Promise<string[]>;

    getImplementations(overrides?: CallOverrides): Promise<string[]>;

    isArgentWallet(
      _wallet: string,
      overrides?: CallOverrides
    ): Promise<boolean>;

    owner(overrides?: CallOverrides): Promise<string>;
  };

  filters: {
    CodeAdded(
      code?: BytesLike | null
    ): TypedEventFilter<[string], { code: string }>;

    ImplementationAdded(
      implementation?: string | null
    ): TypedEventFilter<[string], { implementation: string }>;

    OwnerChanged(
      _newOwner?: string | null
    ): TypedEventFilter<[string], { _newOwner: string }>;
  };

  estimateGas: {
    acceptedCodes(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    acceptedImplementations(
      arg0: string,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    addCode(
      _code: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    addCodeAndImplementationFromWallet(
      _argentWallet: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    addImplementation(
      _impl: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    changeOwner(
      _newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    getCodes(overrides?: CallOverrides): Promise<BigNumber>;

    getImplementations(overrides?: CallOverrides): Promise<BigNumber>;

    isArgentWallet(
      _wallet: string,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    owner(overrides?: CallOverrides): Promise<BigNumber>;
  };

  populateTransaction: {
    acceptedCodes(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    acceptedImplementations(
      arg0: string,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    addCode(
      _code: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    addCodeAndImplementationFromWallet(
      _argentWallet: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    addImplementation(
      _impl: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    changeOwner(
      _newOwner: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    getCodes(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    getImplementations(
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    isArgentWallet(
      _wallet: string,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    owner(overrides?: CallOverrides): Promise<PopulatedTransaction>;
  };
}
Example #9
Source File: BaseExchange.d.ts    From shoyu with MIT License 4 votes vote down vote up
export class BaseExchange extends BaseContract {
  connect(signerOrProvider: Signer | Provider | string): this;
  attach(addressOrName: string): this;
  deployed(): Promise<this>;

  listeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): Array<TypedListener<EventArgsArray, EventArgsObject>>;
  off<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  on<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  once<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeListener<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>,
    listener: TypedListener<EventArgsArray, EventArgsObject>
  ): this;
  removeAllListeners<EventArgsArray extends Array<any>, EventArgsObject>(
    eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
  ): this;

  listeners(eventName?: string): Array<Listener>;
  off(eventName: string, listener: Listener): this;
  on(eventName: string, listener: Listener): this;
  once(eventName: string, listener: Listener): this;
  removeListener(eventName: string, listener: Listener): this;
  removeAllListeners(eventName?: string): this;

  queryFilter<EventArgsArray extends Array<any>, EventArgsObject>(
    event: TypedEventFilter<EventArgsArray, EventArgsObject>,
    fromBlockOrBlockhash?: string | number | undefined,
    toBlock?: string | number | undefined
  ): Promise<Array<TypedEvent<EventArgsArray & EventArgsObject>>>;

  interface: BaseExchangeInterface;

  functions: {
    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<[string]>;

    amountFilled(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<[BigNumber]>;

    approvedBidHash(
      proxy: string,
      askHash: BytesLike,
      bidder: string,
      overrides?: CallOverrides
    ): Promise<[string] & { bidHash: string }>;

    bestBid(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<
      [string, BigNumber, BigNumber, string, string, BigNumber] & {
        bidder: string;
        amount: BigNumber;
        price: BigNumber;
        recipient: string;
        referrer: string;
        timestamp: BigNumber;
      }
    >;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),uint256,uint256,address,address)"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidAmount: BigNumberish,
      bidPrice: BigNumberish,
      bidRecipient: string,
      bidReferrer: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),(bytes32,address,uint256,uint256,address,address,uint8,bytes32,bytes32))"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidOrder: {
        askHash: BytesLike;
        signer: string;
        amount: BigNumberish;
        price: BigNumberish;
        recipient: string;
        referrer: string;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    canTrade(token: string, overrides?: CallOverrides): Promise<[boolean]>;

    cancel(
      order: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    claim(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;

    factory(overrides?: CallOverrides): Promise<[string]>;

    isCancelledOrClaimed(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<[boolean]>;

    updateApprovedBidHash(
      askHash: BytesLike,
      bidder: string,
      bidHash: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<ContractTransaction>;
  };

  DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<string>;

  amountFilled(arg0: BytesLike, overrides?: CallOverrides): Promise<BigNumber>;

  approvedBidHash(
    proxy: string,
    askHash: BytesLike,
    bidder: string,
    overrides?: CallOverrides
  ): Promise<string>;

  bestBid(
    arg0: BytesLike,
    overrides?: CallOverrides
  ): Promise<
    [string, BigNumber, BigNumber, string, string, BigNumber] & {
      bidder: string;
      amount: BigNumber;
      price: BigNumber;
      recipient: string;
      referrer: string;
      timestamp: BigNumber;
    }
  >;

  "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),uint256,uint256,address,address)"(
    askOrder: {
      signer: string;
      proxy: string;
      token: string;
      tokenId: BigNumberish;
      amount: BigNumberish;
      strategy: string;
      currency: string;
      recipient: string;
      deadline: BigNumberish;
      params: BytesLike;
      v: BigNumberish;
      r: BytesLike;
      s: BytesLike;
    },
    bidAmount: BigNumberish,
    bidPrice: BigNumberish,
    bidRecipient: string,
    bidReferrer: string,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),(bytes32,address,uint256,uint256,address,address,uint8,bytes32,bytes32))"(
    askOrder: {
      signer: string;
      proxy: string;
      token: string;
      tokenId: BigNumberish;
      amount: BigNumberish;
      strategy: string;
      currency: string;
      recipient: string;
      deadline: BigNumberish;
      params: BytesLike;
      v: BigNumberish;
      r: BytesLike;
      s: BytesLike;
    },
    bidOrder: {
      askHash: BytesLike;
      signer: string;
      amount: BigNumberish;
      price: BigNumberish;
      recipient: string;
      referrer: string;
      v: BigNumberish;
      r: BytesLike;
      s: BytesLike;
    },
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  canTrade(token: string, overrides?: CallOverrides): Promise<boolean>;

  cancel(
    order: {
      signer: string;
      proxy: string;
      token: string;
      tokenId: BigNumberish;
      amount: BigNumberish;
      strategy: string;
      currency: string;
      recipient: string;
      deadline: BigNumberish;
      params: BytesLike;
      v: BigNumberish;
      r: BytesLike;
      s: BytesLike;
    },
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  claim(
    askOrder: {
      signer: string;
      proxy: string;
      token: string;
      tokenId: BigNumberish;
      amount: BigNumberish;
      strategy: string;
      currency: string;
      recipient: string;
      deadline: BigNumberish;
      params: BytesLike;
      v: BigNumberish;
      r: BytesLike;
      s: BytesLike;
    },
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  factory(overrides?: CallOverrides): Promise<string>;

  isCancelledOrClaimed(
    arg0: BytesLike,
    overrides?: CallOverrides
  ): Promise<boolean>;

  updateApprovedBidHash(
    askHash: BytesLike,
    bidder: string,
    bidHash: BytesLike,
    overrides?: Overrides & { from?: string | Promise<string> }
  ): Promise<ContractTransaction>;

  callStatic: {
    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<string>;

    amountFilled(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    approvedBidHash(
      proxy: string,
      askHash: BytesLike,
      bidder: string,
      overrides?: CallOverrides
    ): Promise<string>;

    bestBid(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<
      [string, BigNumber, BigNumber, string, string, BigNumber] & {
        bidder: string;
        amount: BigNumber;
        price: BigNumber;
        recipient: string;
        referrer: string;
        timestamp: BigNumber;
      }
    >;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),uint256,uint256,address,address)"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidAmount: BigNumberish,
      bidPrice: BigNumberish,
      bidRecipient: string,
      bidReferrer: string,
      overrides?: CallOverrides
    ): Promise<boolean>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),(bytes32,address,uint256,uint256,address,address,uint8,bytes32,bytes32))"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidOrder: {
        askHash: BytesLike;
        signer: string;
        amount: BigNumberish;
        price: BigNumberish;
        recipient: string;
        referrer: string;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: CallOverrides
    ): Promise<boolean>;

    canTrade(token: string, overrides?: CallOverrides): Promise<boolean>;

    cancel(
      order: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: CallOverrides
    ): Promise<void>;

    claim(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: CallOverrides
    ): Promise<void>;

    factory(overrides?: CallOverrides): Promise<string>;

    isCancelledOrClaimed(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<boolean>;

    updateApprovedBidHash(
      askHash: BytesLike,
      bidder: string,
      bidHash: BytesLike,
      overrides?: CallOverrides
    ): Promise<void>;
  };

  filters: {
    Bid(
      hash?: BytesLike | null,
      bidder?: null,
      amount?: null,
      price?: null,
      recipient?: null,
      referrer?: null
    ): TypedEventFilter<
      [string, string, BigNumber, BigNumber, string, string],
      {
        hash: string;
        bidder: string;
        amount: BigNumber;
        price: BigNumber;
        recipient: string;
        referrer: string;
      }
    >;

    Cancel(
      hash?: BytesLike | null
    ): TypedEventFilter<[string], { hash: string }>;

    Claim(
      hash?: BytesLike | null,
      bidder?: null,
      amount?: null,
      price?: null,
      recipient?: null,
      referrer?: null
    ): TypedEventFilter<
      [string, string, BigNumber, BigNumber, string, string],
      {
        hash: string;
        bidder: string;
        amount: BigNumber;
        price: BigNumber;
        recipient: string;
        referrer: string;
      }
    >;

    UpdateApprovedBidHash(
      proxy?: string | null,
      askHash?: BytesLike | null,
      bidder?: string | null,
      bidHash?: null
    ): TypedEventFilter<
      [string, string, string, string],
      { proxy: string; askHash: string; bidder: string; bidHash: string }
    >;
  };

  estimateGas: {
    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<BigNumber>;

    amountFilled(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    approvedBidHash(
      proxy: string,
      askHash: BytesLike,
      bidder: string,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    bestBid(arg0: BytesLike, overrides?: CallOverrides): Promise<BigNumber>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),uint256,uint256,address,address)"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidAmount: BigNumberish,
      bidPrice: BigNumberish,
      bidRecipient: string,
      bidReferrer: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),(bytes32,address,uint256,uint256,address,address,uint8,bytes32,bytes32))"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidOrder: {
        askHash: BytesLike;
        signer: string;
        amount: BigNumberish;
        price: BigNumberish;
        recipient: string;
        referrer: string;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    canTrade(token: string, overrides?: CallOverrides): Promise<BigNumber>;

    cancel(
      order: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    claim(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;

    factory(overrides?: CallOverrides): Promise<BigNumber>;

    isCancelledOrClaimed(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<BigNumber>;

    updateApprovedBidHash(
      askHash: BytesLike,
      bidder: string,
      bidHash: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<BigNumber>;
  };

  populateTransaction: {
    DOMAIN_SEPARATOR(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    amountFilled(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    approvedBidHash(
      proxy: string,
      askHash: BytesLike,
      bidder: string,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    bestBid(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),uint256,uint256,address,address)"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidAmount: BigNumberish,
      bidPrice: BigNumberish,
      bidRecipient: string,
      bidReferrer: string,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    "bid((address,address,address,uint256,uint256,address,address,address,uint256,bytes,uint8,bytes32,bytes32),(bytes32,address,uint256,uint256,address,address,uint8,bytes32,bytes32))"(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      bidOrder: {
        askHash: BytesLike;
        signer: string;
        amount: BigNumberish;
        price: BigNumberish;
        recipient: string;
        referrer: string;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    canTrade(
      token: string,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    cancel(
      order: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    claim(
      askOrder: {
        signer: string;
        proxy: string;
        token: string;
        tokenId: BigNumberish;
        amount: BigNumberish;
        strategy: string;
        currency: string;
        recipient: string;
        deadline: BigNumberish;
        params: BytesLike;
        v: BigNumberish;
        r: BytesLike;
        s: BytesLike;
      },
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;

    factory(overrides?: CallOverrides): Promise<PopulatedTransaction>;

    isCancelledOrClaimed(
      arg0: BytesLike,
      overrides?: CallOverrides
    ): Promise<PopulatedTransaction>;

    updateApprovedBidHash(
      askHash: BytesLike,
      bidder: string,
      bidHash: BytesLike,
      overrides?: Overrides & { from?: string | Promise<string> }
    ): Promise<PopulatedTransaction>;
  };
}