broker

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateClientID

func GenerateClientID(n int) string

Types

type Client

type Client struct {
	BrokerAddress string
	Handler       mqtt.MessageHandler
	MqttClient    mqtt.Client
	OnFrame       FrameHandler
	Recipient     string
}

func (*Client) Connect

func (client *Client) Connect() error

func (*Client) Disconnect

func (client *Client) Disconnect()

func (*Client) Send

func (client *Client) Send(frame *protocol.Frame, recipient string) error

type FrameHandler

type FrameHandler func(client *Client, frame *protocol.Frame)

Jump to

Keyboard shortcuts

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