conditionalevents

package
v0.0.10 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2024 License: Apache-2.0 Imports: 18 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Devices

type Devices interface {
	GetDeviceInfosOfGroup(groupId string) (devices []model.Device, deviceTypeIds []string, err error, code int)
	GetDeviceInfosOfDevices(deviceIds []string) (devices []model.Device, deviceTypeIds []string, err error, code int)
	GetDeviceTypeSelectables(criteria []model.FilterCriteria) (result []model.DeviceTypeSelectable, err error, code int)
	GetService(serviceId string) (result models.Service, err error, code int)
}

type Events

type Events struct {
	// contains filtered or unexported fields
}

func New

func New(ctx context.Context, config config.Config, devices interfaces.Devices, imports interfaces.Imports, m *metrics.Metrics) (result *Events, err error)

func (*Events) CheckEvent

func (this *Events) CheckEvent(token string, id string) int

func (*Events) Deploy

func (this *Events) Deploy(owner string, deployment deploymentmodel.Deployment) error

func (*Events) GetEventStates

func (this *Events) GetEventStates(token string, ids []string) (states map[string]bool, err error, code int)

func (*Events) Remove

func (this *Events) Remove(owner string, deploymentId string) error

func (*Events) UpdateDeviceGroup

func (this *Events) UpdateDeviceGroup(owner string, group model.DeviceGroup) error

type Transformer

type Transformer struct {
	// contains filtered or unexported fields
}

func NewTransformer

func NewTransformer(devices Devices, imports interfaces.Imports) *Transformer

func (*Transformer) Transform

func (this *Transformer) Transform(owner string, deployment deploymentmodel.Deployment) (result []model.EventDesc, err error)

func (*Transformer) TransformElement

func (this *Transformer) TransformElement(owner string, deploymentId string, element deploymentmodel.Element) (result []model.EventDesc, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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