接口结构
2018-05-25 13:56:54 0 举报
物联网MQTT协议转发数据代码逻辑
作者其他创作
大纲/内容
IoDeliverData
+ CreateDeliverBase(nType:int):DeliverWayBase
IoGroup
- m_listItems:list- m_nItemCount- m_nCycleTpye:int
RESTFulDeliver
DeliverWayBase
mosquittopp
- m_mosq:struct mosquitto *
MQTTDeliver
- m_strUrl : string- m_strUserName : string- m_strPassword : string- m_strTopic : string- m_bIsConnect : bool- m_bIsInitLib : bool
- ConnectBroker():bool- DisConnectBroker():void- PublishMessage(pGroup:Grpup):bool- PublishMessage(pItem:Item):bool+ SetTopic(strTopic:string) : void
DataTransfer
- m_pDeliverData:DeliverDataBase*-m_pDeliverWay:DeliverWayBase*
+ GetSupportProtocols() : string+ SetSelectProtocol(strProtocol:string) : void+ ConfigCloudPlatform() : bool+ Init() : bool+ Start() : bool+ Stop() : bool
Group
+ virtual AddItem(pItem:Item*):bool+ virtual GetItem(nIndex:int):Item*+ virtual GetItemCount():int+ virtual SetDeliverCycle(nCycle:int):void
DeliverDataBase
+ virtual CreateDeliverBase(nType:int):DeliverWayBase
1:n
IoItem
- m_strItemNage : string- m_strDeviceID : string- m_dData : double
Item
+virtual GetItemName():string+virtual GetDeviceID():string+virtual GetItemData(dData:double&):void+ virtual GetCycleType():int
0 条评论
下一页