model

package
v0.0.0-...-f6ab580 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2023 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action uint8

Action список команд для исполнительного устройства

const (
	Empty Action = iota
	SwitchON
	SwitchOFF
	Toggle
)

func NewAction

func NewAction(s string) (Action, error)

NewAction создает новый action из строки

func (Action) String

func (t Action) String() string

type ActionEvent

type ActionEvent struct {
	DeviceID string `json:"device_id"`
	Action   Action `json:"action"`
}

ActionEvent payload для события действия

type NotifyEvent

type NotifyEvent struct {
	Text string `json:"text"`
}

NotifyEvent payload для события уведомления

Jump to

Keyboard shortcuts

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