#include <Bytes.hpp>
|
char const *const | bytes |
|
const std::size_t | size |
|
Definition at line 12 of file Bytes.hpp.
◆ Bytes()
mutils::Bytes::Bytes |
( |
decltype(bytes) |
b, |
|
|
decltype(size) |
s |
|
) |
| |
|
inline |
◆ bytes_size()
std::size_t mutils::Bytes::bytes_size |
( |
| ) |
const |
|
inlinevirtual |
the size of the marshalled representation of this object.
useful when allocating arrays in which to store this object.
NOTE: it is recommended that users not call this directly, and prefer to use mutils::bytes_size(T,v) instead.
Implements mutils::ByteRepresentable.
Definition at line 26 of file Bytes.hpp.
◆ ensure_registered()
◆ from_bytes()
template<typename T , typename V >
static std::unique_ptr<Bytes> mutils::Bytes::from_bytes |
( |
T * |
, |
|
|
V * |
|
|
) |
| |
|
inlinestatic |
◆ from_bytes_noalloc()
◆ post_object()
void mutils::Bytes::post_object |
( |
const std::function< void(char const *const, std::size_t)> & |
| ) |
const |
|
inlinevirtual |
Pass a pointer to a buffer containing this class's marshalled representation into the function f.
This pointer is not guaranteed to live beyond the duration of the call to f, so make a copy if you need to keep it around.
NOTE: it is recommended that users not call this directly, and prefer to use mutils::post_object(f,T) instead.
Implements mutils::ByteRepresentable.
Definition at line 30 of file Bytes.hpp.
◆ to_bytes()
std::size_t mutils::Bytes::to_bytes |
( |
char * |
v | ) |
const |
|
inlinevirtual |
Write this class's marshalled representation into the array found at v.
assume v has at least bytes_size() of free memory available; behavior is undefined otherwise.
Returns number of bytes written, which should be the same as bytes_size().
NOTE: it is recommended that users not call this directly, and prefer to use mutils::to_bytes(T,v) instead.
Implements mutils::ByteRepresentable.
Definition at line 20 of file Bytes.hpp.
◆ bytes
char const* const mutils::Bytes::bytes |
◆ size
const std::size_t mutils::Bytes::size |
The documentation for this struct was generated from the following file:
- include/derecho/mutils-serialization/Bytes.hpp