emlabcpp
modern opinionated embedded C++ library
|
handler< T > should be used to execute actual serialization and deserealization of protocol definition. More...
#include <handler.h>
Public Types | |
using | def = converter_for< T, E > |
using | value_type = typename def::value_type |
using | message_type = message< max_size > |
Static Public Member Functions | |
static message_type | serialize (value_type const &val) |
static std::variant< value_type, error_record > | extract (view< std::byte const * > const &msg) |
Static Public Attributes | |
static constexpr std::size_t | max_size = def::max_size |
handler< T > should be used to execute actual serialization and deserealization of protocol definition.
It provides serialize/extract methods that should be used by the user. You may want to have this class (With the include) to be present in separate .cpp file, as the compile time can be quite heavy.
using emlabcpp::protocol::handler< T, E >::def = converter_for< T, E > |
using emlabcpp::protocol::handler< T, E >::message_type = message< max_size > |
using emlabcpp::protocol::handler< T, E >::value_type = typename def::value_type |
|
inlinestatic |
|
inlinestatic |
|
staticconstexpr |