Interface for a class that is supposed to expose its data to another modules. More...
#include <IMessagingSender.hpp>
Public Member Functions | |
virtual const char * | GetModuleName () const =0 |
Should return unique module's name. | |
void | SendBool (const char *varName, bool var) const |
Sends a bool. | |
void | SendInt (const char *varName, int var) const |
Sends an int. | |
void | SendDouble (const char *varName, double var) const |
Sends a double. | |
void | SendVECTOR3 (const char *varName, const VECTOR3 &var) const |
Sends a VECTOR3. | |
void | SendMATRIX3 (const char *varName, const MATRIX3 &var) const |
Sends a MATRIX3. | |
void | SendMATRIX4 (const char *varName, const MATRIX4 &var) const |
Sends a MATRIX4. | |
Interface for a class that is supposed to expose its data to another modules.
Make this a base class of one of your module's classes and implement the GetModuleName() method. For example:
Then create an object of this class on stack and use its public methods to send messages. It's required that you name the variable. For example:
The receiving module may then search for variables with the returned module name and variable name.