Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • BaseContract
    • IWETH

Index

Constructors

constructor

  • new IWETH(addressOrName: string, contractInterface: ContractInterface, signerOrProvider?: Signer | Provider): IWETH
  • Parameters

    • addressOrName: string
    • contractInterface: ContractInterface
    • Optional signerOrProvider: Signer | Provider

    Returns IWETH

Properties

_deployedPromise

_deployedPromise: Promise<Contract>

_runningEvents

_runningEvents: {}

Type declaration

  • [eventTag: string]: RunningEvent

_wrappedEmits

_wrappedEmits: {}

Type declaration

  • [eventTag: string]: (...args: any[]) => void
      • (...args: any[]): void
      • Parameters

        • Rest ...args: any[]

        Returns void

Readonly address

address: string

callStatic

callStatic: { allowance: any; approve: any; balanceOf: any; deposit: any; totalSupply: any; transfer: any; transferFrom: any; withdraw: any }

Type declaration

  • allowance: function
    • allowance(owner: string, spender: string, overrides?: CallOverrides): Promise<BigNumber>
    • Returns the remaining number of tokens that spender will be allowed to spend on behalf of owner through {transferFrom}. This is zero by default. This value changes when {approve} or {transferFrom} are called.

      Parameters

      • owner: string
      • spender: string
      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • approve: function
    • approve(spender: string, amount: BigNumberish, overrides?: CallOverrides): Promise<boolean>
    • Sets amount as the allowance of spender over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.

      Parameters

      • spender: string
      • amount: BigNumberish
      • Optional overrides: CallOverrides

      Returns Promise<boolean>

  • balanceOf: function
    • balanceOf(account: string, overrides?: CallOverrides): Promise<BigNumber>
    • Returns the amount of tokens owned by account.

      Parameters

      • account: string
      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • deposit: function
    • deposit(overrides?: CallOverrides): Promise<void>
    • Parameters

      • Optional overrides: CallOverrides

      Returns Promise<void>

  • totalSupply: function
    • totalSupply(overrides?: CallOverrides): Promise<BigNumber>
    • Returns the amount of tokens in existence.

      Parameters

      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • transfer: function
    • transfer(recipient: string, amount: BigNumberish, overrides?: CallOverrides): Promise<boolean>
    • Moves amount tokens from the caller's account to recipient. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • recipient: string
      • amount: BigNumberish
      • Optional overrides: CallOverrides

      Returns Promise<boolean>

  • transferFrom: function
    • transferFrom(sender: string, recipient: string, amount: BigNumberish, overrides?: CallOverrides): Promise<boolean>
    • Moves amount tokens from sender to recipient using the allowance mechanism. amount is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • sender: string
      • recipient: string
      • amount: BigNumberish
      • Optional overrides: CallOverrides

      Returns Promise<boolean>

  • withdraw: function
    • withdraw(amount: BigNumberish, overrides?: CallOverrides): Promise<void>
    • Parameters

      • amount: BigNumberish
      • Optional overrides: CallOverrides

      Returns Promise<void>

Readonly deployTransaction

deployTransaction: TransactionResponse

estimateGas

estimateGas: { allowance: any; approve: any; balanceOf: any; deposit: any; totalSupply: any; transfer: any; transferFrom: any; withdraw: any }

Type declaration

  • allowance: function
    • allowance(owner: string, spender: string, overrides?: CallOverrides): Promise<BigNumber>
    • Returns the remaining number of tokens that spender will be allowed to spend on behalf of owner through {transferFrom}. This is zero by default. This value changes when {approve} or {transferFrom} are called.

      Parameters

      • owner: string
      • spender: string
      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • approve: function
    • approve(spender: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<BigNumber>
    • Sets amount as the allowance of spender over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.

      Parameters

      • spender: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<BigNumber>

  • balanceOf: function
    • balanceOf(account: string, overrides?: CallOverrides): Promise<BigNumber>
    • Returns the amount of tokens owned by account.

      Parameters

      • account: string
      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • deposit: function
    • deposit(overrides?: PayableOverrides & { from?: string | Promise<string> }): Promise<BigNumber>
    • Parameters

      • Optional overrides: PayableOverrides & { from?: string | Promise<string> }

      Returns Promise<BigNumber>

  • totalSupply: function
    • totalSupply(overrides?: CallOverrides): Promise<BigNumber>
    • Returns the amount of tokens in existence.

      Parameters

      • Optional overrides: CallOverrides

      Returns Promise<BigNumber>

  • transfer: function
    • transfer(recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<BigNumber>
    • Moves amount tokens from the caller's account to recipient. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<BigNumber>

  • transferFrom: function
    • transferFrom(sender: string, recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<BigNumber>
    • Moves amount tokens from sender to recipient using the allowance mechanism. amount is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • sender: string
      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<BigNumber>

  • withdraw: function
    • withdraw(amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<BigNumber>
    • Parameters

      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<BigNumber>

filters

filters: { Approval: any; Transfer: any }

Type declaration

  • Approval: function
    • Approval(owner?: null | string, spender?: null | string, value?: null): TypedEventFilter<[string, string, BigNumber], { owner: string; spender: string; value: BigNumber }>
    • Parameters

      • Optional owner: null | string
      • Optional spender: null | string
      • Optional value: null

      Returns TypedEventFilter<[string, string, BigNumber], { owner: string; spender: string; value: BigNumber }>

  • Transfer: function
    • Transfer(from?: null | string, to?: null | string, value?: null): TypedEventFilter<[string, string, BigNumber], { from: string; to: string; value: BigNumber }>
    • Parameters

      • Optional from: null | string
      • Optional to: null | string
      • Optional value: null

      Returns TypedEventFilter<[string, string, BigNumber], { from: string; to: string; value: BigNumber }>

functions

functions: { allowance: any; approve: any; balanceOf: any; deposit: any; totalSupply: any; transfer: any; transferFrom: any; withdraw: any }

Type declaration

  • allowance: function
    • allowance(owner: string, spender: string, overrides?: CallOverrides): Promise<[BigNumber]>
    • Returns the remaining number of tokens that spender will be allowed to spend on behalf of owner through {transferFrom}. This is zero by default. This value changes when {approve} or {transferFrom} are called.

      Parameters

      • owner: string
      • spender: string
      • Optional overrides: CallOverrides

      Returns Promise<[BigNumber]>

  • approve: function
    • approve(spender: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
    • Sets amount as the allowance of spender over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.

      Parameters

      • spender: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<ContractTransaction>

  • balanceOf: function
    • balanceOf(account: string, overrides?: CallOverrides): Promise<[BigNumber]>
    • Returns the amount of tokens owned by account.

      Parameters

      • account: string
      • Optional overrides: CallOverrides

      Returns Promise<[BigNumber]>

  • deposit: function
    • deposit(overrides?: PayableOverrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
    • Parameters

      • Optional overrides: PayableOverrides & { from?: string | Promise<string> }

      Returns Promise<ContractTransaction>

  • totalSupply: function
    • totalSupply(overrides?: CallOverrides): Promise<[BigNumber]>
    • Returns the amount of tokens in existence.

      Parameters

      • Optional overrides: CallOverrides

      Returns Promise<[BigNumber]>

  • transfer: function
    • transfer(recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
    • Moves amount tokens from the caller's account to recipient. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<ContractTransaction>

  • transferFrom: function
    • transferFrom(sender: string, recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
    • Moves amount tokens from sender to recipient using the allowance mechanism. amount is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • sender: string
      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<ContractTransaction>

  • withdraw: function
    • withdraw(amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
    • Parameters

      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<ContractTransaction>

interface

interface: IWETHInterface

populateTransaction

populateTransaction: { allowance: any; approve: any; balanceOf: any; deposit: any; totalSupply: any; transfer: any; transferFrom: any; withdraw: any }

Type declaration

  • allowance: function
    • allowance(owner: string, spender: string, overrides?: CallOverrides): Promise<PopulatedTransaction>
    • Returns the remaining number of tokens that spender will be allowed to spend on behalf of owner through {transferFrom}. This is zero by default. This value changes when {approve} or {transferFrom} are called.

      Parameters

      • owner: string
      • spender: string
      • Optional overrides: CallOverrides

      Returns Promise<PopulatedTransaction>

  • approve: function
    • approve(spender: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<PopulatedTransaction>
    • Sets amount as the allowance of spender over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.

      Parameters

      • spender: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<PopulatedTransaction>

  • balanceOf: function
    • balanceOf(account: string, overrides?: CallOverrides): Promise<PopulatedTransaction>
    • Returns the amount of tokens owned by account.

      Parameters

      • account: string
      • Optional overrides: CallOverrides

      Returns Promise<PopulatedTransaction>

  • deposit: function
    • deposit(overrides?: PayableOverrides & { from?: string | Promise<string> }): Promise<PopulatedTransaction>
    • Parameters

      • Optional overrides: PayableOverrides & { from?: string | Promise<string> }

      Returns Promise<PopulatedTransaction>

  • totalSupply: function
    • totalSupply(overrides?: CallOverrides): Promise<PopulatedTransaction>
    • Returns the amount of tokens in existence.

      Parameters

      • Optional overrides: CallOverrides

      Returns Promise<PopulatedTransaction>

  • transfer: function
    • transfer(recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<PopulatedTransaction>
    • Moves amount tokens from the caller's account to recipient. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<PopulatedTransaction>

  • transferFrom: function
    • transferFrom(sender: string, recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<PopulatedTransaction>
    • Moves amount tokens from sender to recipient using the allowance mechanism. amount is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

      Parameters

      • sender: string
      • recipient: string
      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<PopulatedTransaction>

  • withdraw: function
    • withdraw(amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<PopulatedTransaction>
    • Parameters

      • amount: BigNumberish
      • Optional overrides: Overrides & { from?: string | Promise<string> }

      Returns Promise<PopulatedTransaction>

Readonly provider

provider: Provider

Readonly resolvedAddress

resolvedAddress: Promise<string>

Readonly signer

signer: Signer

Methods

_checkRunningEvents

  • _checkRunningEvents(runningEvent: RunningEvent): void
  • Parameters

    • runningEvent: RunningEvent

    Returns void

_deployed

  • _deployed(blockTag?: BlockTag): Promise<Contract>
  • Parameters

    • Optional blockTag: BlockTag

    Returns Promise<Contract>

_wrapEvent

  • _wrapEvent(runningEvent: RunningEvent, log: Log, listener: Listener): Event
  • Parameters

    • runningEvent: RunningEvent
    • log: Log
    • listener: Listener

    Returns Event

allowance

  • allowance(owner: string, spender: string, overrides?: CallOverrides): Promise<BigNumber>
  • Returns the remaining number of tokens that spender will be allowed to spend on behalf of owner through {transferFrom}. This is zero by default. This value changes when {approve} or {transferFrom} are called.

    Parameters

    • owner: string
    • spender: string
    • Optional overrides: CallOverrides

    Returns Promise<BigNumber>

approve

  • approve(spender: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
  • Sets amount as the allowance of spender over the caller's tokens. Returns a boolean value indicating whether the operation succeeded. IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 Emits an {Approval} event.

    Parameters

    • spender: string
    • amount: BigNumberish
    • Optional overrides: Overrides & { from?: string | Promise<string> }

    Returns Promise<ContractTransaction>

attach

  • attach(addressOrName: string): IWETH
  • Parameters

    • addressOrName: string

    Returns IWETH

balanceOf

  • balanceOf(account: string, overrides?: CallOverrides): Promise<BigNumber>
  • Returns the amount of tokens owned by account.

    Parameters

    • account: string
    • Optional overrides: CallOverrides

    Returns Promise<BigNumber>

connect

  • connect(signerOrProvider: string | Signer | Provider): IWETH
  • Parameters

    • signerOrProvider: string | Signer | Provider

    Returns IWETH

deployed

  • deployed(): Promise<IWETH>
  • Returns Promise<IWETH>

deposit

  • deposit(overrides?: PayableOverrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
  • Parameters

    • Optional overrides: PayableOverrides & { from?: string | Promise<string> }

    Returns Promise<ContractTransaction>

emit

  • emit(eventName: string | EventFilter, ...args: any[]): boolean
  • Parameters

    • eventName: string | EventFilter
    • Rest ...args: any[]

    Returns boolean

fallback

  • fallback(overrides?: TransactionRequest): Promise<TransactionResponse>
  • Parameters

    • Optional overrides: TransactionRequest

    Returns Promise<TransactionResponse>

listenerCount

  • listenerCount(eventName?: string | EventFilter): number
  • Parameters

    • Optional eventName: string | EventFilter

    Returns number

listeners

  • listeners<EventArgsArray, EventArgsObject>(eventFilter?: TypedEventFilter<EventArgsArray, EventArgsObject>): TypedListener<EventArgsArray, EventArgsObject>[]
  • listeners(eventName?: string): Listener[]
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • Optional eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>

    Returns TypedListener<EventArgsArray, EventArgsObject>[]

  • Parameters

    • Optional eventName: string

    Returns Listener[]

off

  • off<EventArgsArray, EventArgsObject>(eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>, listener: TypedListener<EventArgsArray, EventArgsObject>): IWETH
  • off(eventName: string, listener: Listener): IWETH
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
    • listener: TypedListener<EventArgsArray, EventArgsObject>

    Returns IWETH

  • Parameters

    • eventName: string
    • listener: Listener

    Returns IWETH

on

  • on<EventArgsArray, EventArgsObject>(eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>, listener: TypedListener<EventArgsArray, EventArgsObject>): IWETH
  • on(eventName: string, listener: Listener): IWETH
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
    • listener: TypedListener<EventArgsArray, EventArgsObject>

    Returns IWETH

  • Parameters

    • eventName: string
    • listener: Listener

    Returns IWETH

once

  • once<EventArgsArray, EventArgsObject>(eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>, listener: TypedListener<EventArgsArray, EventArgsObject>): IWETH
  • once(eventName: string, listener: Listener): IWETH
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
    • listener: TypedListener<EventArgsArray, EventArgsObject>

    Returns IWETH

  • Parameters

    • eventName: string
    • listener: Listener

    Returns IWETH

queryFilter

  • queryFilter<EventArgsArray, EventArgsObject>(event: TypedEventFilter<EventArgsArray, EventArgsObject>, fromBlockOrBlockhash?: string | number, toBlock?: string | number): Promise<TypedEvent<EventArgsArray & EventArgsObject>[]>
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • event: TypedEventFilter<EventArgsArray, EventArgsObject>
    • Optional fromBlockOrBlockhash: string | number
    • Optional toBlock: string | number

    Returns Promise<TypedEvent<EventArgsArray & EventArgsObject>[]>

removeAllListeners

  • removeAllListeners<EventArgsArray, EventArgsObject>(eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>): IWETH
  • removeAllListeners(eventName?: string): IWETH
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>

    Returns IWETH

  • Parameters

    • Optional eventName: string

    Returns IWETH

removeListener

  • removeListener<EventArgsArray, EventArgsObject>(eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>, listener: TypedListener<EventArgsArray, EventArgsObject>): IWETH
  • removeListener(eventName: string, listener: Listener): IWETH
  • Type parameters

    • EventArgsArray: any[]

    • EventArgsObject

    Parameters

    • eventFilter: TypedEventFilter<EventArgsArray, EventArgsObject>
    • listener: TypedListener<EventArgsArray, EventArgsObject>

    Returns IWETH

  • Parameters

    • eventName: string
    • listener: Listener

    Returns IWETH

totalSupply

  • totalSupply(overrides?: CallOverrides): Promise<BigNumber>
  • Returns the amount of tokens in existence.

    Parameters

    • Optional overrides: CallOverrides

    Returns Promise<BigNumber>

transfer

  • transfer(recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
  • Moves amount tokens from the caller's account to recipient. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

    Parameters

    • recipient: string
    • amount: BigNumberish
    • Optional overrides: Overrides & { from?: string | Promise<string> }

    Returns Promise<ContractTransaction>

transferFrom

  • transferFrom(sender: string, recipient: string, amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
  • Moves amount tokens from sender to recipient using the allowance mechanism. amount is then deducted from the caller's allowance. Returns a boolean value indicating whether the operation succeeded. Emits a {Transfer} event.

    Parameters

    • sender: string
    • recipient: string
    • amount: BigNumberish
    • Optional overrides: Overrides & { from?: string | Promise<string> }

    Returns Promise<ContractTransaction>

withdraw

  • withdraw(amount: BigNumberish, overrides?: Overrides & { from?: string | Promise<string> }): Promise<ContractTransaction>
  • Parameters

    • amount: BigNumberish
    • Optional overrides: Overrides & { from?: string | Promise<string> }

    Returns Promise<ContractTransaction>

Static getContractAddress

  • getContractAddress(transaction: { from: string; nonce: BigNumberish }): string
  • Parameters

    • transaction: { from: string; nonce: BigNumberish }
      • from: string
      • nonce: BigNumberish

    Returns string

Static getInterface

  • getInterface(contractInterface: ContractInterface): Interface
  • Parameters

    • contractInterface: ContractInterface

    Returns Interface

Static isIndexed

  • isIndexed(value: any): value is Indexed
  • Parameters

    • value: any

    Returns value is Indexed

Generated using TypeDoc