MCPcopy Create free account
hub / github.com/OpenImageDebugger/OpenImageDebugger / MessageBlock

Class MessageBlock

src/ipc/message_exchange.h:96–103  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

94}
95
96struct MessageBlock {
97 [[nodiscard]] virtual std::size_t size() const noexcept = 0;
98 // Returns raw byte data - using std::byte* for semantic clarity that this
99 // is raw byte storage, not numeric data. Conversion to uint8_t*/char* is
100 // done at API boundaries (Qt, OpenGL, etc.)
101 [[nodiscard]] virtual const std::byte* data() const noexcept = 0;
102 virtual ~MessageBlock() noexcept;
103};
104
105template <typename Primitive> struct PrimitiveBlock final : MessageBlock {
106 explicit PrimitiveBlock(Primitive value) : data_{value} {}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected