RTI transport  Version 1.0ae [build 00]
NDDS_Transport_Message_t Struct Reference

Structure used to store a message received from a Transport Plugin. More...

Data Fields

NDDS_Transport_Buffer_t buffer
 Actual structure where message is stored.
 
void * loaned_buffer_param
 Storage that can be used by the Transport Plugin if the memory passed in buffer was loaned and additional information is required to return the buffer back to the plugin.
 

Detailed Description

Structure used to store a message received from a Transport Plugin.

A Transport Plugin must fill in this structure when it wants to pass a message that it received to the NDDS core in the receive_rEA() call. The buffer member will contain the actual data. The loaned_buffer_param member should be set to indicate whether or not the memory stored in the buffer member was loaned by the plugin and should be returned when NDDS is finished processing the message.

See Also
The Optional "Loaned-Buffer" Mechanism for additional information about buffer loaning by the Transport Plugin.

Field Documentation

NDDS_Transport_Buffer_t NDDS_Transport_Message_t::buffer

Actual structure where message is stored.

The buffer structure has 2 fields, length and pointer. receive_rEA() should set the value of length to the length of the data stored in the memory pointed to by pointer.

RTI_INT32 length;
char *pointer;
}

When the NDDS_Transport_Message_t structure is passed into the receive_rEA() call, the buffer will not be valid. The receive_rEA() call should set the pointer to point at valid memory, either to the memory of the buffer that was passed into receive_rEA() or to internal memory of the transport that is being loaned to the NDDS core for storing the message.

See Also
NDDS_Transport_Buffer_t NDDS_Transport_Recv_Fcn_rEA
void* NDDS_Transport_Message_t::loaned_buffer_param

Storage that can be used by the Transport Plugin if the memory passed in buffer was loaned and additional information is required to return the buffer back to the plugin.

If the Transport Plugin does not loan a buffer to the NDDS core to store a message, then receive_rEA() should set the value of loan_buffer_param to -1. This will let the NDDS core know that the buffer does not need to be returned to the plugin.

If the buffer is loaned, then the loaned_buffer_param should be set to something other than -1. Normally it will be set to store a handle to some additional information need by the Transport Plugin to return the loaned buffer when return_loaned_buffer_rEA() is called.

See Also
NDDS_Transport_Return_Loaned_Buffer_Fcn_rEA

RTI transport Version 1.0ae [build 00] Copyright © Wed Aug 29 2012 Real-Time Innovations, Inc