EII Message Bus C Reference
|
#include <msg_envelope.hpp>
Public Member Functions | |
MsgEnvelope (content_type_t ct) | |
MsgEnvelope (msg_envelope_t *msgenv) | |
void | put_integer (const std::string key, int64_t value) |
void | put_float (const std::string key, double value) |
void | put_string (const std::string key, const std::string value) |
void | put_bool (const std::string key, bool value) |
void | put_array (const std::string key, MsgEnvelopeList *value) |
template<typename T > | |
void | put_vector (const std::string key, std::vector< T > const &value) |
void | put_object (const std::string key, MsgEnvelopeObject *value) |
void | put_blob (char *value, size_t size) |
void | remove (const std::string key) |
int64_t | get_int (const std::string key) |
double | get_float (const std::string key) |
const char * | get_string (const std::string key) |
bool | get_bool (const std::string key) |
char * | get_blob (const std::string key) |
MsgEnvelopeObject * | get_object (const std::string key) |
MsgEnvelopeList * | get_array (const std::string key) |
MsgEnvelopeElement * | get_msg_envelope_element (const std::string key) |
msg_envelope_t * | get_msg_envelope () |
~MsgEnvelope () | |
MsgEnvelope class
eii::msgbus::MsgEnvelope::MsgEnvelope | ( | content_type_t | ct | ) |
Constructor
eii::msgbus::MsgEnvelope::MsgEnvelope | ( | msg_envelope_t * | msgenv | ) |
Constructor
eii::msgbus::MsgEnvelope::~MsgEnvelope | ( | ) |
Destructor
MsgEnvelopeList* eii::msgbus::MsgEnvelope::get_array | ( | const std::string | key | ) |
To fetch a MsgEnvelopeList
value associated with the key provided
char* eii::msgbus::MsgEnvelope::get_blob | ( | const std::string | key | ) |
To fetch blob from MsgEnvelope
bool eii::msgbus::MsgEnvelope::get_bool | ( | const std::string | key | ) |
To fetch a boolean value associated with the key provided
double eii::msgbus::MsgEnvelope::get_float | ( | const std::string | key | ) |
To fetch a float value associated with the key provided
int64_t eii::msgbus::MsgEnvelope::get_int | ( | const std::string | key | ) |
To fetch an integer value associated with the key provided
msg_envelope_t* eii::msgbus::MsgEnvelope::get_msg_envelope | ( | ) |
Getter to retrieve the underlying msg_envelope_t
structure
msg_envelope_t
- returns the msg_envelope_t
struct MsgEnvelopeElement* eii::msgbus::MsgEnvelope::get_msg_envelope_element | ( | const std::string | key | ) |
To fetch a MsgEnvelopeElement
value associated with the key provided
MsgEnvelopeObject* eii::msgbus::MsgEnvelope::get_object | ( | const std::string | key | ) |
To fetch a MsgEnvelopeObject
value associated with the key provided
const char* eii::msgbus::MsgEnvelope::get_string | ( | const std::string | key | ) |
To fetch a string associated with the key provided
void eii::msgbus::MsgEnvelope::put_array | ( | const std::string | key, |
MsgEnvelopeList * | value | ||
) |
Add a MsgEnvelopeList
to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_blob | ( | char * | value, |
size_t | size | ||
) |
Add a new blob to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_bool | ( | const std::string | key, |
bool | value | ||
) |
Add a new boolean value to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_float | ( | const std::string | key, |
double | value | ||
) |
Add a new floating value to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_integer | ( | const std::string | key, |
int64_t | value | ||
) |
Add a new integer value to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_object | ( | const std::string | key, |
MsgEnvelopeObject * | value | ||
) |
Add a new nested MsgEnvelopeObject
to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::put_string | ( | const std::string | key, |
const std::string | value | ||
) |
Add a new string value to the MsgEnvelope
object.
|
inline |
Add a vector as an array to the MsgEnvelope
object. Note: The supported types for the vector are integer, float & bool only. Add a MsgEnvelopeList
to the MsgEnvelope
object.
void eii::msgbus::MsgEnvelope::remove | ( | const std::string | key | ) |
To remove value associated with the key provided