web3

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2023 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsJsonArray

func IsJsonArray(raw []byte) bool

Types

type Client

type Client struct {
	Provider string
	Id       int64
}

func (*Client) Call

func (c *Client) Call(method string, params string, out any) error

type EthGetLogsRequestParams

type EthGetLogsRequestParams struct {
	Address   string
	Topics    []string
	FromBlock string
	ToBlock   string
}

func ParseEthGetLogsRequestParams

func ParseEthGetLogsRequestParams(req *rpc.JsonRpcMessage) (*EthGetLogsRequestParams, *rpc.JsonRpcMessage)

type Web3

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

func NewWeb3Client

func NewWeb3Client(url string) (*Web3, error)

func (*Web3) Cli

func (w3 *Web3) Cli() *ethclient.Client

func (*Web3) SetHeaders added in v1.0.4

func (w3 *Web3) SetHeaders(headers map[string]string)

func (*Web3) Url added in v1.0.2

func (w3 *Web3) Url() string

Jump to

Keyboard shortcuts

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