xronos-sdk 0.8.0
Xronos C++ SDK
Loading...
Searching...
No Matches
xronos::sdk::IsSerializer Concept Reference

Constraints for a serializer that can be used on ports. More...

#include <xronos/sdk/port.hh>

Concept definition

template<template <class> class S, class T>
concept IsSerializer = std::is_same_v<T, void> || (requires(T value) {
{ S<T>::serialize(value) } -> std::same_as<std::vector<std::byte>>;
} && requires(std::span<const std::byte> data) {
{ S<T>::deserialize(data) } -> std::same_as<T>;
})
Constraints for a serializer that can be used on ports.
Definition port.hh:46

Detailed Description

Constraints for a serializer that can be used on ports.