Documentation ¶
Index ¶
- Constants
- Variables
- type ChatClient
- func (c *ChatClient) Close() error
- func (c *ChatClient) JoinContext(ctx context.Context, channel string) error
- func (c *ChatClient) OnMessage(handler func(msg *Message) error)
- func (c *ChatClient) OpenContext(ctx context.Context, url string) error
- func (c *ChatClient) Send(channel, content string) error
- func (c *ChatClient) SendTimeout(channel, content string, timeout time.Duration) error
- type Message
Constants ¶
View Source
const ( // TagBadgeInfo ... TagBadgeInfo string = "badge-info" // TagBadges ... TagBadges string = "badges" // TagColor ... TagColor string = "color" // TagDisplayName ... TagDisplayName string = "display-name" // TagEmotes ... TagEmotes string = "emotes" // TagFlags ... TagFlags string = "flags" // TagSubscriber 1 if the user has a subscriber badge; otherwise, 0. // // [deprecated] use badges TagSubscriber string = "subscriber" )
Variables ¶
View Source
var ErrRateExceeded = errors.New("ratelimit exceeded")
Functions ¶
This section is empty.
Types ¶
type ChatClient ¶
type ChatClient struct { Nick string OnSend func(command string) OnReceived func(command string) OnError func(format string, args ...interface{}) // contains filtered or unexported fields }
ChatClient ...
func (*ChatClient) JoinContext ¶
func (c *ChatClient) JoinContext(ctx context.Context, channel string) error
func (*ChatClient) OnMessage ¶
func (c *ChatClient) OnMessage(handler func(msg *Message) error)
OnMessage ...
func (*ChatClient) OpenContext ¶
func (c *ChatClient) OpenContext(ctx context.Context, url string) error
OpenContext ...
func (*ChatClient) SendTimeout ¶
func (c *ChatClient) SendTimeout(channel, content string, timeout time.Duration) error
SendTimeout
Click to show internal directories.
Click to hide internal directories.