basic

package
v1.2.9 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

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 added in v1.0.1

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