21#include "serializer.h"
45 buffer.open(QIODevice::ReadWrite);
61 buffer.open(QIODevice::ReadWrite);
101 deserialize(value, result);
117 bytes.setRawData((
char*)value.mv_data, value.mv_size);
138 if (buffer.pos() > 0) {
156 val.mv_size = buffer.pos();
157 val.mv_data = (
char*)bytes.data();
A class handling serialization/deserialization.
Definition serializer.h:33
~Serializer()
Destoys the serializer.
Definition serializer.hpp:69
Serializer()
Creates an empty Serializer.
Definition serializer.hpp:40
MDB_val getData()
Returns the data if it already was serialized.
Definition serializer.hpp:153
T deserialize(const MDB_val &value)
Deserializes value.
Definition serializer.hpp:99
void clear()
Clears the state of serializer.
Definition serializer.hpp:137
MDB_val setData(const T &value)
Sets the data to the seriazer.
Definition serializer.hpp:83