Mark3 Realtime Kernel
Mark3::Message Class Reference

the Message class. This object provides threadsafe message-based IPC services based on exchange of objects containing a data pointer and minimal application-defined metadata. Messages are to be allocated/produced by the sender, and deallocated/consumed by the receiver. More...

#include <message.h>

Inheritance diagram for Mark3::Message:
Mark3::TypedLinkListNode< Message > Mark3::LinkListNode

Public Member Functions

void * operator new (size_t sz, void *pv)
 
void Init ()
 Init Initialize the data and code in the message. More...
 
void SetData (void *pvData_)
 SetData Set the data pointer for the message before transmission. More...
 
void * GetData ()
 GetData Get the data pointer stored in the message upon receipt. More...
 
void SetCode (uint16_t u16Code_)
 SetCode Set the code in the message before transmission. More...
 
uint16_t GetCode ()
 GetCode Return the code set in the message upon receipt. More...
 

Private Attributes

void * m_pvData
 Pointer to the message data. More...
 
uint16_t m_u16Code
 Message code, providing context for the message. More...
 

Additional Inherited Members

Detailed Description

the Message class. This object provides threadsafe message-based IPC services based on exchange of objects containing a data pointer and minimal application-defined metadata. Messages are to be allocated/produced by the sender, and deallocated/consumed by the receiver.

Examples:
lab8_messages/main.cpp.

Definition at line 97 of file message.h.

Member Function Documentation

◆ GetCode()

uint16_t Mark3::Message::GetCode ( )
inline

GetCode Return the code set in the message upon receipt.

Returns
user code set in the object

Definition at line 139 of file message.h.

◆ GetData()

void* Mark3::Message::GetData ( )
inline

GetData Get the data pointer stored in the message upon receipt.

Returns
Pointer to the data set in the message object

Definition at line 125 of file message.h.

◆ Init()

void Mark3::Message::Init ( void  )
inline

Init Initialize the data and code in the message.

Definition at line 105 of file message.h.

◆ operator new()

void* Mark3::Message::operator new ( size_t  sz,
void *  pv 
)
inline

Definition at line 100 of file message.h.

◆ SetCode()

void Mark3::Message::SetCode ( uint16_t  u16Code_)
inline

SetCode Set the code in the message before transmission.

Parameters
u16Code_Data code to set in the object
Examples:
lab8_messages/main.cpp.

Definition at line 132 of file message.h.

◆ SetData()

void Mark3::Message::SetData ( void *  pvData_)
inline

SetData Set the data pointer for the message before transmission.

Parameters
pvData_Pointer to the data object to send in the message

Definition at line 118 of file message.h.

Member Data Documentation

◆ m_pvData

void* Mark3::Message::m_pvData
private

Pointer to the message data.

Definition at line 143 of file message.h.

◆ m_u16Code

uint16_t Mark3::Message::m_u16Code
private

Message code, providing context for the message.

Definition at line 146 of file message.h.


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