okex

package
v0.0.0-...-f37401a Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2018 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client ...

func NewClient

func NewClient(config *config.Config) *Client

NewClient 创建一个新的client

func (*Client) Login

func (c *Client) Login(username, password string) (string, error)

Login okex登录 @returns token, error token 用于后续的websocket登录

type WSSClient

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

WSSClient 提供okex API调用的客户端

func NewWSSClient

func NewWSSClient(config *config.Config) *WSSClient

NewWSSClient 创建一个新的Websocket client

func (*WSSClient) Close

func (c *WSSClient) Close()

Close 向服务端发起关闭操作

func (*WSSClient) QuerySpot

func (c *WSSClient) QuerySpot() (<-chan []byte, error)

QuerySpot 负责订阅现货行情数据

func (*WSSClient) SetLogger

func (c *WSSClient) SetLogger(logger core.Logger)

SetLogger 设置日志器

Jump to

Keyboard shortcuts

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