event

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	//设备在离线状态事件
	DeviceOnline = EventCode("deviceOnline")
	//设备自动发现事件
	DeviceDiscover = EventCode("deviceDiscover")
	//设备开关机事件
	DeviceOnOff = EventCode("onOff")
	//添加设备
	DeviceAdded = EventCode("deviceAdded")
	//即将删除设备,在该事件中依旧可以查询设备信息
	DeviceDeleting = EventCode("deviceDeleting")
	//driver-box服务状态
	ServiceStatus = EventCode("serviceStatus")

	//即将执行ExportTo
	Exporting = EventCode("exporting")

	// DoExport 插件回调事件
	DoExport = EventCode("export")
)
View Source
const (
	//服务启动成功
	ServiceStatusHealthy = "healthy"
	//服务启动异常
	ServiceStatusError = "error"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Data

type Data struct {
	Code  EventCode   `json:"code"` //事件Code
	Value interface{} `json:"value"`
}

Data 设备事件模型

type EventCode

type EventCode string

todo 后续定义事件code采用 EventCode 类型

Jump to

Keyboard shortcuts

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