ADD: added new basic messages and added the parentID as an part of the identifier
This commit is contained in:
@@ -37,6 +37,8 @@ namespace WHISPER
|
||||
private:
|
||||
/// device ID
|
||||
std::uint32_t ownID_;
|
||||
/// device ID
|
||||
std::uint32_t parentID_;
|
||||
/// device Type
|
||||
SourceType ownDeviceType_;
|
||||
|
||||
@@ -61,7 +63,7 @@ namespace WHISPER
|
||||
|
||||
|
||||
public:
|
||||
whispercomm(std::uint32_t id, SourceType owndevicetype):ownID_(id),ownDeviceType_(owndevicetype)
|
||||
whispercomm(std::uint32_t parentid,std::uint32_t id, SourceType owndevicetype):parentID_(parentid),ownID_(id),ownDeviceType_(owndevicetype)
|
||||
{};
|
||||
void connect(std::shared_ptr<threadSafeQueue<WHISPER::Message>> receiver);
|
||||
void publish(std::string msg,std::string topic);
|
||||
@@ -70,6 +72,7 @@ namespace WHISPER
|
||||
void unsubscribe(std::string topic);
|
||||
|
||||
std::uint32_t getOwnID();
|
||||
std::uint32_t getParentID();
|
||||
SourceType getOwnDeviceType();
|
||||
|
||||
protected:
|
||||
|
||||
Reference in New Issue
Block a user