CommRaT 2.0.0
C++20 Real-Time Messaging Framework
Loading...
Searching...
No Matches
commrat::MessageSchema< PayloadT, Registry > Struct Template Reference

Complete schema for a CommRaT message type. More...

#include <commrat/introspection/message_schema.hpp>

Classes

struct  CommRaTMetadata
 CommRaT-specific metadata (compile-time constants) More...
 

Public Attributes

CommRaTMetadata commrat
 
sertial::StructLayout< TimsMessage< PayloadT > > layout
 

Detailed Description

template<typename PayloadT, typename Registry>
struct commrat::MessageSchema< PayloadT, Registry >

Complete schema for a CommRaT message type.

Combines compile-time CommRaT metadata (message IDs, registry info) with SeRTial's structural layout (fields, types, sizes, offsets). This structure is rfl-reflectable and can be exported to JSON/YAML/etc.

Template Parameters
PayloadTThe user payload type
RegistryThe CommRaT registry containing this message

Usage:

// Access CommRaT metadata
constexpr uint32_t id = Schema{}.commrat.message_id;
// Access SeRTial layout
constexpr size_t size = Schema{}.layout.base_packed_size;
// Export to JSON
auto json = rfl::json::write(Schema{});
Complete schema for a CommRaT message type.

Definition at line 51 of file message_schema.hpp.

Member Data Documentation

◆ commrat

template<typename PayloadT , typename Registry >
CommRaTMetadata commrat::MessageSchema< PayloadT, Registry >::commrat

Definition at line 69 of file message_schema.hpp.

◆ layout

template<typename PayloadT , typename Registry >
sertial::StructLayout<TimsMessage<PayloadT> > commrat::MessageSchema< PayloadT, Registry >::layout

Definition at line 70 of file message_schema.hpp.


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