![]() |
Roboid Control for C++
|
Message providing generic information about a Thing.
#include <ThingMsg.h>
Public Member Functions | |
ThingMsg (unsigned char networkId, Thing *thing) | |
Create a message for sending. | |
ThingMsg (const char *buffer) | |
Create a message for receiving. | |
virtual | ~ThingMsg () |
Destructor for the message. | |
virtual unsigned char | Serialize (char *buffer) override |
Serialize the message into a byte array for sending. | |
Public Attributes | |
unsigned char | networkId |
The network ID of the thing. | |
unsigned char | thingId |
The ID of the thing. | |
unsigned char | thingType |
The Thing.Type of the thing. | |
unsigned char | parentId |
The parent of the thing in the hierarachy. This is null for root Things. | |
Static Public Attributes | |
static const unsigned char | id = 0x80 |
The message ID. | |
static const unsigned char | length = 5 |
The length of the message. | |
Passer::RoboidControl::ThingMsg::ThingMsg | ( | unsigned char | networkId, |
Thing * | thing | ||
) |
Create a message for sending.
networkId | The network ID of the thing |
thing | The thing |
Passer::RoboidControl::ThingMsg::ThingMsg | ( | const char * | buffer | ) |
Create a message for receiving.
buffer | The byte array to parse |
|
overridevirtual |
Serialize the message into a byte array for sending.
buffer | The buffer to serilize into |
Reimplemented from Passer::RoboidControl::IMessage.