util

package
v1.3.27 Latest Latest
Warning

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

Go to latest
Published: May 20, 2024 License: MIT Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BoundContract

type BoundContract struct {
	*bind.BoundContract
	// contains filtered or unexported fields
}

func BindContract

func BindContract(client *ethclient.Client, contract *Contract) (*BoundContract, error)

func (*BoundContract) ABI

func (contract *BoundContract) ABI() abi.ABI

func (*BoundContract) Address

func (contract *BoundContract) Address() common.Address

func (*BoundContract) Client

func (contract *BoundContract) Client() *ethclient.Client

func (*BoundContract) DeployContract

func (c *BoundContract) DeployContract(opts *bind.TransactOpts, params ...interface{}) (common.Address, *types.Transaction, error)

func (*BoundContract) SetAddress

func (contract *BoundContract) SetAddress(address common.Address)

func (*BoundContract) SetClient

func (contract *BoundContract) SetClient(client *ethclient.Client)

func (*BoundContract) SetTransact

func (contract *BoundContract) SetTransact(fn TransactFunc)

func (*BoundContract) Source

func (contract *BoundContract) Source() *Contract

func (*BoundContract) Transact

func (c *BoundContract) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

func (*BoundContract) Transfer

func (c *BoundContract) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

type Contract

type Contract struct {
	Name            string
	SourcePath      string
	CompilerVersion string
	Address         common.Address

	ABI []byte
	Bin string
}

type NonceCache

type NonceCache interface {
	Serialize(account common.Address, fn func() error) error
	Sync(account common.Address, syncFn func() (uint64, error))

	Set(account common.Address, nonce int64)
	Get(account common.Address) (nonce int64, loaded bool)
	Incr(account common.Address) int64
	Decr(account common.Address) int64
}

func NewNonceCache

func NewNonceCache() NonceCache

type TransactFunc

type TransactFunc func(opts *bind.TransactOpts, contract *common.Address, input []byte) (*types.Transaction, error)

Jump to

Keyboard shortcuts

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