Documentation
¶
Index ¶
- Constants
- Variables
- func LoadSt()
- func NewCoAPInEndSource(e typex.RuleX) typex.XSource
- func NewGenericIothubSource(e typex.RuleX) typex.XSource
- func NewGrpcInEndSource(e typex.RuleX) typex.XSource
- func NewHttpInEndSource(e typex.RuleX) typex.XSource
- func NewIThingsSource(e typex.RuleX) typex.XSource
- func NewMqttInEndSource(e typex.RuleX) typex.XSource
- func NewNatsSource(e typex.RuleX) typex.XSource
- func NewTencentIothubSource(e typex.RuleX) typex.XSource
- func NewUdpInEndSource(e typex.RuleX) typex.XSource
- type RulexRpcServer
- type TopologyDevice
- type TopologyDownMsg
- type TopologyPayload
Constants ¶
View Source
const ( // 属性下发称之为控制指令 METHOD_CONTROL string = "control" METHOD_CONTROL_REPLY string = "control_reply" // 属性下发称之为控制指令[这是为了兼容一些其他平台,实际上和上面功能完全一一样] METHOD_PROPERTY string = "property" METHOD_PROPERTY_REPLY string = "property_reply" // 动作请求 METHOD_ACTION string = "action" METHOD_ACTION_REPLY string = "action_reply" )
{ "method":"${method}_reply", "requestId":"20a4ccfd-d308", "code": 0, "status":"some message" }
Variables ¶
View Source
var SM typex.SourceRegistry = core.NewSourceTypeManager()
Functions ¶
Types ¶
type RulexRpcServer ¶
type RulexRpcServer struct { rulexrpc.UnimplementedRulexRpcServer // contains filtered or unexported fields }
type TopologyDevice ¶
type TopologyDevice struct { ProductID string `json:"productID"` DeviceName string `json:"deviceName"` }
* * 下发拓扑结构 *
{ "method":"describesubDevices", "clientToken":"3160be0b-6d4f-e6fa-d614-8fb422c0d16c", "timestamp":1681625336600, "status":"成功", "payload":{ "devices":[ { "productID":"268dGhSTdOE", "deviceName":"RULEX-大屏1" } ] } }
func (TopologyDevice) OfflineTopic ¶
func (tt TopologyDevice) OfflineTopic() string
$gateway/status/${productid}/${devicename}
func (TopologyDevice) OnlineTopic ¶
func (tt TopologyDevice) OnlineTopic() string
$gateway/status/${productid}/${devicename}
func (TopologyDevice) ReportTopic ¶
func (tt TopologyDevice) ReportTopic() string
$thing/up/property/{ProductID}/{DeviceName}
type TopologyDownMsg ¶
type TopologyDownMsg struct { Method string `json:"method"` ClientToken string `json:"clientToken"` Timestamp int64 `json:"timestamp"` Status string `json:"status"` Payload TopologyPayload `json:"payload"` }
type TopologyPayload ¶
type TopologyPayload struct {
Devices []TopologyDevice `json:"devices"`
}
Click to show internal directories.
Click to hide internal directories.