1 #ifndef SERIALIZE_STL_HH
2 #define SERIALIZE_STL_HH
13 static constexpr
int size = -1;
16 static auto begin(
const T&
t) {
return t.begin(); }
17 static auto end (
const T&
t) {
return t.end(); }
24 return std::inserter(
t,
begin(
t));
45 static constexpr
bool loadInPlace =
false;
46 static void prepare(std::vector<T>& v,
int n) {
47 v.clear(); v.reserve(n);
49 static auto output(std::vector<T>& v) {
50 return std::back_inserter(v);
This implements a queue on top of circular_buffer (not part of boost).
This file implemented 3 utility functions:
static auto output(cb_queue< T > &q)
static void prepare(cb_queue< T > &q, int n)
static auto output(std::vector< T > &v)
static void prepare(std::vector< T > &v, int n)
static void prepare(T &t, int)
static auto begin(const T &t)
static constexpr int size
static constexpr bool loadInPlace
static auto end(const T &t)
typename T::value_type value_type