basic

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2023 License: Apache-2.0 Imports: 9 Imported by: 3

Documentation

Index

Constants

View Source
const (
	MaxReadWaitTime = 30 * time.Second
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BasicClient

type BasicClient interface {
	Get(path string, qp map[string]string) ([]byte, int, error)
	Post(path string, body interface{}, param map[string]string) ([]byte, error)

	GetTx(txHash string) (*tx.TxResult, error)
	PostTx(hexTx []byte, param map[string]string) ([]tx.TxCommitResult, error)
	WsGet(path string, constructMsg func([]byte) (interface{}, error), closeCh <-chan struct{}) (<-chan interface{}, error)
}

func NewClient

func NewClient(baseUrl string, apiKey string) BasicClient

type WSResponse

type WSResponse struct {
	Stream string
	Data   interface{}
}

Jump to

Keyboard shortcuts

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