client

package
v0.0.0-...-ef390af Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

func NewClient

func NewClient(c *ethclient.Client) *Client

func (*Client) EstimateGas

func (c *Client) EstimateGas(ctx context.Context, msg ethereum.CallMsg) (uint64, error)

func (*Client) HeaderByNumber

func (c *Client) HeaderByNumber(ctx context.Context, number *big.Int) (*types.Header, error)

func (*Client) PendingNonceAt

func (c *Client) PendingNonceAt(ctx context.Context, account common.Address) (uint64, error)

func (*Client) SuggestGasPrice

func (c *Client) SuggestGasPrice(ctx context.Context) (*big.Int, error)

func (*Client) TransactionByHash

func (c *Client) TransactionByHash(ctx context.Context, hash common.Hash) (tx *types.Transaction, isPending bool, err error)

func (*Client) TransactionReceipt

func (c *Client) TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error)

type ETHClient

type ETHClient interface {
	HeaderByNumber(ctx context.Context, number *big.Int) (*types.Header, error)
	PendingNonceAt(ctx context.Context, account common.Address) (uint64, error)
	SuggestGasPrice(ctx context.Context) (*big.Int, error)
	TransactionByHash(ctx context.Context, hash common.Hash) (tx *types.Transaction, isPending bool, err error)
	TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error)
	EstimateGas(ctx context.Context, msg ethereum.CallMsg) (uint64, error)
}

Jump to

Keyboard shortcuts

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