mqttserver

package
v0.0.0-...-5d1b788 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2017 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MqttServer

func MqttServer(s MqttSettings)

MqttServer connects to an MQTT Broker and handels all incoming and outcoming messages

Types

type MqttSettings

type MqttSettings struct {
	Transport  string
	BrokerURL  string
	BrokerPort int
	ClientID   string
	Topics     []string
}

MqttSettings contains the Settings for the MQTT Server

type Task

type Task struct {
	BaseTopic string
	Data      []byte
	ResultCh  chan<- ToWireMsg
	ErrorCh   chan<- ToWireMsg
}

Task contains the details of the task

func (*Task) Run

func (task *Task) Run()

Run executes a task

func (*Task) RunTest

func (task *Task) RunTest(testQueue []test.TestcaseI) error

RunTest runs all tests in testQueue which implement the TestcaseI Interface

type ToWireMsg

type ToWireMsg struct {
	Topic string
	Data  []byte
}

ToWireMsg contains the topic and data to be send to the MQTT Broker

Jump to

Keyboard shortcuts

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