Versions in this module Expand all Collapse all v1 v1.0.2 Sep 27, 2023 v1.0.1 May 23, 2023 Changes in this version + type Config struct + CA []byte + Cert tls.Certificate + ClientID string + MTLS bool + Password string + SkipTLSVer bool + URL string + Username string + type GMqtt struct + func New(cfg Config) *GMqtt + func (g *GMqtt) Close() + func (g *GMqtt) ConnectToBroker() (mqtt.Client, error) + func (g *GMqtt) GetConnEvent() (bool, error) + func (g *GMqtt) Group(prefix string, groups ...func(group *RouterGroup)) *RouterGroup + func (g *GMqtt) Run() + func (g *GMqtt) Start() error + func (g *GMqtt) Subscribe() + type HandlerFunc = func(r *Request) + type Request struct + Client mqtt.Client + Message mqtt.Message + func (r *Request) GetRouterString(key string, def ...interface{}) string + func (r *Request) GetRouterValue(key string, def ...interface{}) interface{} + func (r *Request) GetRouterVar(key string, def ...interface{}) *gvar.Var + type Router struct + Domain string + Method string + Priority int + RegNames []string + RegRule string + Uri string + type RouterGroup struct + func (g *RouterGroup) Clone() *RouterGroup + func (g *RouterGroup) GET(pattern string, object HandlerFunc) *RouterGroup + func (g *RouterGroup) Group(prefix string, groups ...func(group *RouterGroup)) *RouterGroup