24 lines
404 B
Go
24 lines
404 B
Go
package iot
|
|
|
|
import "log"
|
|
import "udi/config"
|
|
import "udi/handlers/handler"
|
|
|
|
|
|
type IoTHandler struct {
|
|
handler.CommonHandler
|
|
}
|
|
|
|
func New(id string, config config.HandlerConfigT) handler.Handler {
|
|
t := &IoTHandler {
|
|
}
|
|
t.Id = id
|
|
return t
|
|
}
|
|
|
|
func (self *IoTHandler) Handle(message handler.MessageT) {
|
|
log.Printf("Handler IoT %d processing %s -> %s", self.Id, message.Topic, message.Payload)
|
|
}
|
|
|
|
|