Documentation
¶
Index ¶
- Constants
- func EmptyPublisher(ctx context.Context, topic string, payload []byte) error
- type Interface
- func (i *Interface) Connected(ctx context.Context, publisher Publisher) error
- func (i *Interface) Disconnected()
- func (i *Interface) IncomingMessage(ctx context.Context, topic string, payload []byte) error
- func (i *Interface) IncomingMessageDevices(ctx context.Context, topic []string, payload []byte) error
- func (i *Interface) IncomingMessageDevicesWith(ctx context.Context, topic []string, payload []byte, d da.Device) error
- func (i *Interface) IncomingMessageDevicesWithCapabilities(ctx context.Context, topic []string, payload []byte, d da.Device) error
- func (i *Interface) Start()
- func (i *Interface) Stop()
- type Publisher
Constants ¶
View Source
const DefaultMqttOutputLayer string = "mqtt"
View Source
const MaximumServiceUpdateTime = 1 * time.Second
View Source
const UnknownDevice = mqttError("unknown device")
View Source
const UnknownOutputLayer = mqttError("output layer requested could not be found")
View Source
const UnknownTopic = mqttError("unknown topic")
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Interface ¶
type Interface struct { Publisher Publisher DeviceOrganiser *state.DeviceOrganiser GatewayMux state.GatewayMapper EventSubscriber state.EventSubscriber OutputStack layers.OutputStack DeviceInvoker invoker.Invoker Logger logwrap.Logger PublishStateOnConnect bool PublishAggregatedState bool PublishIndividualState bool // contains filtered or unexported fields }
func (*Interface) Disconnected ¶
func (i *Interface) Disconnected()
func (*Interface) IncomingMessage ¶
func (*Interface) IncomingMessageDevices ¶
func (*Interface) IncomingMessageDevicesWith ¶
func (*Interface) IncomingMessageDevicesWithCapabilities ¶
Click to show internal directories.
Click to hide internal directories.