| Fast DDS Version 3.3.0 Fast DDS

Loading...
Searching...
No Matches
CDRMessage_t Struct Referencefinal
eProsima Fast DDS API Reference » RTPS » Common Module.

Structure CDRMessage_t, contains a serialized message. More...

`#include <CDRMessage_t.hpp>`

## Public Member Functions

| CDRMessage_t ()
| ~CDRMessage_t ()
| CDRMessage_t (uint32_t size)
| Constructor with maximum size.
| CDRMessage_t (const SerializedPayload_t &payload)
| Constructor to wrap a serialized payload.
| CDRMessage_t (const CDRMessage_t &message)
| CDRMessage_t (CDRMessage_t &&message)
CDRMessage_t & | operator= (CDRMessage_t &&message)
void | init (octet *buffer_ptr, uint32_t size)
void | reserve (uint32_t size)

## Public Attributes

octet * | buffer
| Pointer to the buffer where the data is stored.
uint32_t | pos
| Read or write position.
uint32_t | max_size
| Max size of the message.
uint32_t | reserved_size
| Size allocated on buffer. May be higher than max_size.
uint32_t | length
| Current length of the message.
Endianness_t | msg_endian
| Endianness of the message.
bool | wraps

## Detailed Description

Structure CDRMessage_t, contains a serialized message.

## Constructor & Destructor Documentation

## ◆ CDRMessage_t() [1/5]

CDRMessage_t | ( |  | ) |

inline

## ◆ ~CDRMessage_t()

~CDRMessage_t | ( |  | ) |

inline

## ◆ CDRMessage_t() [2/5]

CDRMessage_t | ( | uint32_t | size | ) |

inline explicit

Constructor with maximum size.

Parameters

  size | Maximum size

## ◆ CDRMessage_t() [3/5]

CDRMessage_t | ( | const SerializedPayload_t & | payload | ) |

inline explicit

Constructor to wrap a serialized payload.

Parameters

  payload | Payload to wrap

## ◆ CDRMessage_t() [4/5]

CDRMessage_t | ( | const CDRMessage_t & | message | ) |

inline

## ◆ CDRMessage_t() [5/5]

CDRMessage_t | ( | CDRMessage_t && | message | ) |

inline

## Member Function Documentation

## ◆ init()

void init | ( | octet * | buffer_ptr,
|  | uint32_t | size )

inline

## ◆ operator=()

CDRMessage_t & operator= | ( | CDRMessage_t && | message | ) |

inline

## ◆ reserve()

void reserve | ( | uint32_t | size | ) |

inline

## Member Data Documentation

## ◆ buffer

octet* buffer

Pointer to the buffer where the data is stored.

## ◆ length

uint32_t length

Current length of the message.

## ◆ max_size

uint32_t max_size

Max size of the message.

## ◆ msg_endian

Endianness_t msg_endian

Endianness of the message.

## ◆ pos

uint32_t pos

Read or write position.

## ◆ reserved_size

uint32_t reserved_size

Size allocated on buffer. May be higher than max_size.

## ◆ wraps

bool wraps

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

- include/fastdds/rtps/common/CDRMessage_t.hpp