weth

package
v0.0.0-...-753e747 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 20, 2023 License: LGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const WETH_ABI = `` /* 2723-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type WETH

type WETH struct {
	// contains filtered or unexported fields
}

func NewWETH

func NewWETH(w3 *web3.Web3, contractAddress common.Address) (*WETH, error)

func (*WETH) Allowance

func (e *WETH) Allowance(owner, spender common.Address) (*big.Int, error)

func (*WETH) Approve

func (e *WETH) Approve(spender common.Address, limit, gasPrice, gasTipCap, gasFeeCap *big.Int) (common.Hash, error)

func (*WETH) BalanceOf

func (e *WETH) BalanceOf(owner common.Address) (*big.Int, error)

func (*WETH) Deposit

func (e *WETH) Deposit(amount, gasPrice, gasTipCap, gasFeeCap *big.Int) (common.Hash, error)

func (*WETH) EncodeABI

func (e *WETH) EncodeABI(methodName string, args ...interface{}) ([]byte, error)

func (*WETH) EstimateGasLimit

func (e *WETH) EstimateGasLimit(to common.Address, data []byte, gasPrice, wei *big.Int) (uint64, error)

func (*WETH) SetConfirmation

func (e *WETH) SetConfirmation(blockCount int)

func (*WETH) SetTxPollTimeout

func (e *WETH) SetTxPollTimeout(txPollTimeout int)

func (*WETH) SyncSendEIP1559Tx

func (e *WETH) SyncSendEIP1559Tx(
	gasTipCap *big.Int,
	gasFeeCap *big.Int,
	gasLimit uint64,
	to common.Address,
	data []byte,
	wei *big.Int,
) (*eTypes.Receipt, error)

func (*WETH) SyncSendRawTransactionForTx

func (e *WETH) SyncSendRawTransactionForTx(
	gasPrice *big.Int, gasLimit uint64, to common.Address, data []byte, wei *big.Int,
) (*eTypes.Receipt, error)

func (*WETH) Transfer

func (e *WETH) Transfer(to common.Address, amount, gasPrice, gasTipCap, gasFeeCap *big.Int) (common.Hash, error)

func (*WETH) WaitBlock

func (e *WETH) WaitBlock(blockCount uint64) error

func (*WETH) Withdraw

func (e *WETH) Withdraw(amount, gasPrice, gasTipCap, gasFeeCap *big.Int) (common.Hash, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL