Documentation
¶
Index ¶
- Variables
- func GetObservedDesiredValue() string
- func SetObservedDesiredValue(Value string)
- type DevPanel
- func (d *DevPanel) DealDeviceTwinGet(deviceID string, twinName string) (interface{}, error)
- func (d *DevPanel) DevInit(deviceList []*dmiapi.Device, deviceModelList []*dmiapi.DeviceModel) error
- func (d *DevPanel) DevStart()
- func (d *DevPanel) GetDevice(deviceID string) (interface{}, error)
- func (d *DevPanel) GetModel(modelID string) (common.DeviceModel, error)
- func (d *DevPanel) GetTwinResult(deviceID string, twinName string) (string, string, error)
- func (d *DevPanel) RemoveDevice(deviceID string) error
- func (d *DevPanel) RemoveModel(modelID string)
- func (d *DevPanel) UpdateDev(model *common.DeviceModel, device *common.DeviceInstance)
- func (d *DevPanel) UpdateDevTwins(deviceID string, twins []common.Twin) error
- func (d *DevPanel) UpdateModel(model *common.DeviceModel)
- type TwinData
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrEmptyData = errors.New("device or device model list is empty")
Functions ¶
func GetObservedDesiredValue ¶
func GetObservedDesiredValue() string
func SetObservedDesiredValue ¶
func SetObservedDesiredValue(Value string)
Types ¶
type DevPanel ¶
type DevPanel struct {
// contains filtered or unexported fields
}
func (*DevPanel) DealDeviceTwinGet ¶
DealDeviceTwinGet get device's twin data
func (*DevPanel) DevInit ¶
func (d *DevPanel) DevInit(deviceList []*dmiapi.Device, deviceModelList []*dmiapi.DeviceModel) error
DevInit initialize the device
func (*DevPanel) GetModel ¶
func (d *DevPanel) GetModel(modelID string) (common.DeviceModel, error)
GetModel if the model exists, return device model
func (*DevPanel) GetTwinResult ¶
GetTwinResult Get twin's value and data type
func (*DevPanel) RemoveDevice ¶
RemoveDevice remove device instance
func (*DevPanel) RemoveModel ¶
RemoveModel remove device model
func (*DevPanel) UpdateDev ¶
func (d *DevPanel) UpdateDev(model *common.DeviceModel, device *common.DeviceInstance)
UpdateDev stop old device, then update and start new device
func (*DevPanel) UpdateDevTwins ¶
UpdateDevTwins update device's twins
func (*DevPanel) UpdateModel ¶
func (d *DevPanel) UpdateModel(model *common.DeviceModel)
UpdateModel update device model
type TwinData ¶
type TwinData struct { DeviceName string DeviceNamespace string Client *driver.CustomizedClient Name string Type string ObservedDesired common.TwinProperty VisitorConfig *driver.VisitorConfig Topic string Results interface{} CollectCycle time.Duration ReportToCloud bool }
func (*TwinData) GetPayLoad ¶
func (*TwinData) PushToEdgeCore ¶
func (td *TwinData) PushToEdgeCore()
func (*TwinData) SetObservedDesiredValue ¶
func (td *TwinData) SetObservedDesiredValue()
Click to show internal directories.
Click to hide internal directories.