gusimplewhiteboard
wb_generic_whiteboard_object< object_type > Class Template Reference

#include <guWhiteboard_gugenericwhiteboardobject.h>

Inheritance diagram for wb_generic_whiteboard_object< object_type >:
Collaboration diagram for wb_generic_whiteboard_object< object_type >:

Public Member Functions

 wb_generic_whiteboard_object (gu_simple_whiteboard_descriptor *wbd, uint16_t toffs, bool want_atomic=true, bool do_notify_subscribers=true)
 designated constructor More...
 
 wb_generic_whiteboard_object (const object_type &value, uint16_t toffs, gu_simple_whiteboard_descriptor *wbd=NULLPTR, bool want_atomic=true)
 value conversion reference constructor More...
 
void init (uint16_t toffs, gu_simple_whiteboard_descriptor *wbd=NULLPTR, bool want_atomic=true, bool do_notify_subscribers=true)
 intialiser (called from constructors) This is specific to a custom whiteboard, this way the default singleton whiteboard is correct. More...
 
- Public Member Functions inherited from generic_whiteboard_object< object_type >
 generic_whiteboard_object (gu_simple_whiteboard_descriptor *wbd, uint16_t toffs, bool want_atomic=true, bool do_notify_subscribers=true)
 designated constructor More...
 
 generic_whiteboard_object (const generic_whiteboard_object< object_type > &source)
 copy constructor More...
 
 generic_whiteboard_object (const object_type &value, uint16_t toffs, gu_simple_whiteboard_descriptor *wbd=NULLPTR, bool want_atomic=true)
 value conversion reference constructor (needs to be overridden by subclasses to set toffs to be useful) More...
 
void init (uint16_t toffs, gu_simple_whiteboard_descriptor *wbd=NULLPTR, bool want_atomic=true, bool do_notify_subscribers=true)
 intialiser (called from constructors) More...
 
void set (const object_type &msg)
 designated setter for posting whiteboard messages More...
 
object_type get ()
 designated getter for getting a whiteboard message More...
 
object_type get_from (gu_simple_message *msg)
 access method to get data from an existing, low-level message More...
 
void post (const object_type &msg)
 post method (calls set()) More...
 
const object_type & operator<< (const object_type &value)
 shift left operator (calls set()) More...
 
generic_whiteboard_object< object_type > & operator>> (object_type &value)
 shift right operator (calls get()) More...
 
const object_type & operator= (const object_type &value)
 assignment operator (calls set()) More...
 
object_type operator= (object_type value)
 assignment copy operator (calls set()) More...
 
 operator object_type ()
 cast operator (calls get()) More...
 
object_type operator() ()
 empty function operator (calls get()) More...
 
void operator() (object_type value)
 function operator with object_type copy parameter (calls set()) More...
 
bool hasNewMessage ()
 
void set (const std::string &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 
void set (const std::vector< int > &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 
void set (const std::vector< bool > &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 
std::string get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
std::vector< int > get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
std::vector< bool > get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
std::string get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
std::vector< int > get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
std::vector< bool > get_from (gu_simple_message *msg)
 Generic object method for unwrapping data from the underlying whiteboard storage union. More...
 
void set (const std::string &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 
void set (const std::vector< int > &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 
void set (const std::vector< bool > &msg)
 Generic object method for setting data into a specific whiteboard type. More...
 

Additional Inherited Members

- Protected Attributes inherited from generic_whiteboard_object< object_type >
gu_simple_whiteboard_descriptor_wbd
 
uint16_t type_offset
 
bool atomic
 
bool notify_subscribers
 
uint16_t last_count = 0
 
bool isFirst = true
 

Detailed Description

template<class object_type>
class wb_generic_whiteboard_object< object_type >

Definition at line 19 of file guWhiteboard_gugenericwhiteboardobject.h.

Constructor & Destructor Documentation

◆ wb_generic_whiteboard_object() [1/2]

template<class object_type >
wb_generic_whiteboard_object< object_type >::wb_generic_whiteboard_object ( gu_simple_whiteboard_descriptor wbd,
uint16_t  toffs,
bool  want_atomic = true,
bool  do_notify_subscribers = true 
)
inline

designated constructor

Definition at line 25 of file guWhiteboard_gugenericwhiteboardobject.h.

References wb_generic_whiteboard_object< object_type >::init().

◆ wb_generic_whiteboard_object() [2/2]

template<class object_type >
wb_generic_whiteboard_object< object_type >::wb_generic_whiteboard_object ( const object_type &  value,
uint16_t  toffs,
gu_simple_whiteboard_descriptor wbd = NULLPTR,
bool  want_atomic = true 
)
inline

Member Function Documentation

◆ init()

template<class object_type >
void wb_generic_whiteboard_object< object_type >::init ( uint16_t  toffs,
gu_simple_whiteboard_descriptor wbd = NULLPTR,
bool  want_atomic = true,
bool  do_notify_subscribers = true 
)
inline

intialiser (called from constructors) This is specific to a custom whiteboard, this way the default singleton whiteboard is correct.

Definition at line 43 of file guWhiteboard_gugenericwhiteboardobject.h.

References get_guWhiteboard_singleton_whiteboard(), and generic_whiteboard_object< object_type >::init().

Referenced by wb_generic_whiteboard_object< object_type >::wb_generic_whiteboard_object().


The documentation for this class was generated from the following file: