eth

package
v0.0.0-...-50e54af Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2021 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EthClient

type EthClient struct {
	EthClient  *ethclient.Client
	CurrencyId string
}

func (*EthClient) Close

func (e *EthClient) Close()

func (EthClient) GetBalanceByHeight

func (a EthClient) GetBalanceByHeight(ctx context.Context, account ethCommon.Address, height *big.Int) (*big.Int, error)

GetBalanceByHeight 获取用户余额

func (EthClient) GetDataByBlockHash

func (a EthClient) GetDataByBlockHash(ctx context.Context, hash ethCommon.Hash) (*types.Block, error)

GetDataByBlockHash 获取区块数据通过区块hash

func (EthClient) GetDataByBlockHeight

func (a EthClient) GetDataByBlockHeight(ctx context.Context, height *big.Int) (*types.Block, error)

GetDataByBlockHeight 获取块高数据通过块高

func (*EthClient) GetEtHAddrAndPrivateByNum

func (e *EthClient) GetEtHAddrAndPrivateByNum(ctx context.Context, num int) (resp []*entity.EntityAddressPrivate)

GetEtHAddrAndPrivateByNum 获取新创建帐号及私钥

func (EthClient) GetNewBlockHeight

func (a EthClient) GetNewBlockHeight(ctx context.Context) (uint64, error)

GetNewBlockHeight 获取最新块高

Jump to

Keyboard shortcuts

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