Documentation ¶
Index ¶
- Variables
- type Client
- func (c *Client) Balance(ctx context.Context, walletAddress any) (*big.Int, error)
- func (c *Client) EstimateGas(ctx context.Context, fromAddr, toAddr any, data []byte, ethValue *big.Int) (uint64, error)
- func (c *Client) EtherBalance(ctx context.Context, walletAddress any) (*decimal.Decimal, error)
- func (c *Client) GasPrice(ctx context.Context) (*big.Int, error)
- func (c *Client) Transfer(ctx context.Context, chainID int64, PrivateKey string, ToAddress string, ...) (*types.Transaction, error)
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Client ¶
func MustNewClient ¶
func (*Client) EstimateGas ¶
func (c *Client) EstimateGas(ctx context.Context, fromAddr, toAddr any, data []byte, ethValue *big.Int) (uint64, error)
EstimateGas get gas limit with call data fromAddress must not empty toAddr could be empty ethValue could be nil or zero, unit is wei
func (*Client) EtherBalance ¶
EtherBalance get current balance in eth
Click to show internal directories.
Click to hide internal directories.