raft 0.1.0
Loading...
Searching...
No Matches
raft::enhanced::typed::Serializable Concept Reference

Concept requiring that a type T can be serialized and deserialized with error type E. More...

#include <typed_server.hpp>

Concept definition

template<typename T, typename E>
concept raft::enhanced::typed::Serializable = requires(T obj, const std::vector<std::byte>& bytes) {
{ serialize(obj) } -> std::same_as<std::vector<std::byte>>;
{ deserialize<T>(bytes) } -> std::same_as<tl::expected<T, E>>;
}
Concept requiring that a type T can be serialized and deserialized with error type E.
Definition typed_server.hpp:24

Detailed Description

Concept requiring that a type T can be serialized and deserialized with error type E.