mqtt_client

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DestroyMqttClient

func DestroyMqttClient(c *MqttClient)

Types

type MqttClient

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

func NewMqttClient

func NewMqttClient(opts *MqttClientOptions) (*MqttClient, error)

func (*MqttClient) Connect

func (c *MqttClient) Connect() error

func (*MqttClient) Disconnect

func (c *MqttClient) Disconnect()

func (*MqttClient) GetRouter

func (c *MqttClient) GetRouter(group string, handlers []router.Handler) *router.Router

func (*MqttClient) Response

func (c *MqttClient) Response(item *router.Item, responseIdentifier string, data []byte) error

type MqttClientOptions

type MqttClientOptions struct {
	UserName              string
	Password              string
	Address               string
	ClientID              string
	KeepAliveSec          int64
	PingTimeoutSec        int64
	WriteTimeoutSec       int64
	SubscribeRoutineCount int
	SubscribeBufferSize   int
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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