Safe DDS
eprosima::safedds::serialization::RepresentationHeader Struct Reference

RTPS SerializedPayloadHeader equivalent. More...

#include <RepresentationHeader.hpp>

Public Member Functions

void init_as_parameter_list () noexcept
 Initialize RepresentationHeader as a parameter list with machine endianness.
 
void init_as_cdr () noexcept
 Initialize RepresentationHeader as a cdr payload list with machine endianness.
 
bool check_native_endianness () const noexcept
 Check a validated encapsulation_kind_ with machine endianness. More...
 
bool payload_is_parameter_list () const noexcept
 Check if encapsulation_kind_ indicates a parameter list payload. More...
 
bool payload_is_cdr () const noexcept
 Check if encapsulation_kind_ indicates a plain CDR payload. More...
 
bool is_valid () const noexcept
 Check if given RepresentationHeader is valid. More...
 

Public Attributes

memory::container::Array< uint8_t, ENCAPSULATION_KIND_SIZE > encapsulation_kind_
 Kind of next message to be deserialized.
 
memory::container::Array< uint8_t, ENCAPSULATION_OPTIONS_SIZE > encapsulation_options_
 Encapsulation options.
 

Detailed Description

RTPS SerializedPayloadHeader equivalent.

Member Function Documentation

◆ check_native_endianness()

bool eprosima::safedds::serialization::RepresentationHeader::check_native_endianness ( ) const
noexcept

Check a validated encapsulation_kind_ with machine endianness.

Returns
true if match, false otherwise.

◆ is_valid()

bool eprosima::safedds::serialization::RepresentationHeader::is_valid ( ) const
noexcept

Check if given RepresentationHeader is valid.

Returns
true if valid, false otherwise.

◆ payload_is_cdr()

bool eprosima::safedds::serialization::RepresentationHeader::payload_is_cdr ( ) const
noexcept

Check if encapsulation_kind_ indicates a plain CDR payload.

Returns
true if payload is encoded using CDR, false otherwise.

◆ payload_is_parameter_list()

bool eprosima::safedds::serialization::RepresentationHeader::payload_is_parameter_list ( ) const
noexcept

Check if encapsulation_kind_ indicates a parameter list payload.

Returns
true if payload is a parameter list, false otherwise.

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