live

package
v0.0.0-...-562e60d Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2023 License: MIT Imports: 11 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 {
	Match           message.Match // 比赛(外部接口获取的参数)
	LastCommentId   string        // (内部接口获取,用于比对直播数据最后一次消息的id)
	LastCommentTime string
	Th              *time.Ticker
	ThQueryMatch    *time.Ticker   // 另起一个ticker 更新比赛状态
	InterruptCh     chan os.Signal // 中断信号
	// contains filtered or unexported fields
}

func New

func New(match message.Match) *Client

func (Client) ColoredScore

func (c Client) ColoredScore() string

func (*Client) End

func (c *Client) End()

func (*Client) OnLiveMessage

func (c *Client) OnLiveMessage()

func (*Client) OnMatchUpdate

func (c *Client) OnMatchUpdate()

比赛状态更新

func (*Client) PrintLiveMsg

func (c *Client) PrintLiveMsg(msg message.LiveMsg)

格式化直播消息

func (*Client) Start

func (c *Client) Start()

Jump to

Keyboard shortcuts

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