Documentation ¶
Index ¶
- func CreateDefinition(channels []string, subtopics []string) twins.Definition
- func CreateMessage(attr twins.Attribute, recs []senml.Record) (*messaging.Message, error)
- func CreateSenML(n int, recs []senml.Record)
- func CreateTwin(channels []string, subtopics []string) twins.Twin
- func NewAuthNServiceClient(users map[string]string) mainflux.AuthNServiceClient
- func NewBroker(sub map[string]string) messaging.Publisher
- func NewService(tokens map[string]string) twins.Service
- func NewStateRepository() twins.StateRepository
- func NewTwinCache() twins.TwinCache
- func NewTwinRepository() twins.TwinRepository
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateDefinition ¶
func CreateDefinition(channels []string, subtopics []string) twins.Definition
CreateDefinition creates twin definition
func CreateMessage ¶
CreateMessage creates Mainflux message using SenML record array
func CreateSenML ¶
CreateSenML creates SenML record array
func CreateTwin ¶
CreateTwin creates twin
func NewAuthNServiceClient ¶
NewAuthNServiceClient creates mock of auth service.
func NewService ¶
NewService use mock dependencies to create real twins service
func NewStateRepository ¶
func NewStateRepository() twins.StateRepository
NewStateRepository creates in-memory twin repository.
func NewTwinRepository ¶
func NewTwinRepository() twins.TwinRepository
NewTwinRepository creates in-memory twin repository.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.