cereal Namespace Reference

Classes

class  ArrayWrapper
 This class is used as a shim for cereal to be able to serialize a raw pointer array. More...

 
struct  is_cereal_archive
 
struct  is_cereal_archive_saving
 
class  PointerVectorWrapper
 The objective of this class is to create a wrapper for std::vector that hold pointers by adding also the size of the vector. More...

 
class  PointerWrapper
 The objective of this class is to create a wrapper for raw pointer by encapsulating them in a smart pointer of type unique_ptr. More...

 

Functions

template<class Archive , template< typename... > class Map, typename... Args, typename = typename Map<Args...>::mapped_type>
void CEREAL_LOAD_FUNCTION_NAME (Archive &ar, Map< Args... > &map)
 Loading for std-like pair associative containers. More...

 
template<class Archive , template< typename... > class Map, typename... Args, typename = typename Map<Args...>::mapped_type>
void CEREAL_SAVE_FUNCTION_NAME (Archive &ar, Map< Args... > const &map)
 Saving for std-like pair associative containers. More...

 
template
<
typename
Archive
>
bool is_loading (const typename std::enable_if< is_cereal_archive< Archive >::value, Archive >::type *=0)
 
template
<
typename
Archive
>
bool is_loading (const typename std::enable_if< !is_cereal_archive< Archive >::value, Archive >::type *=0)
 
template
<
typename
Archive
>
bool is_saving (const typename std::enable_if< is_cereal_archive_saving< Archive >::value, Archive >::type *=0)
 
template
<
typename
Archive
>
bool is_saving (const typename std::enable_if< !is_cereal_archive_saving< Archive >::value, Archive >::type *=0)
 
template
<
class
T
,
class
S
>
ArrayWrapper< T > make_array (T *&t, S &s)
 This function is used to serialized old c-style array. More...

 
template
<
class
T
>
PointerWrapper< T > make_pointer (T *&t)
 Serialize raw pointer object by encapsulating the pointer into a smart pointer. More...

 
template
<
class
T
>
PointerVectorWrapper< T > make_pointer_vector (std::vector< T *> &t)
 Serialize an std::vector that holds raw pointer object by encapsulating them into a smart pointer. More...

 

Function Documentation

◆ CEREAL_LOAD_FUNCTION_NAME()

void cereal::CEREAL_LOAD_FUNCTION_NAME ( Archive &  ar,
Map< Args... > &  map 
)
inline

Loading for std-like pair associative containers.

Definition at line 59 of file pair_associative_container.hpp.

References core::v2::move(), and core::v2::size().

◆ CEREAL_SAVE_FUNCTION_NAME()

void cereal::CEREAL_SAVE_FUNCTION_NAME ( Archive &  ar,
Map< Args... > const &  map 
)
inline

Saving for std-like pair associative containers.

Definition at line 49 of file pair_associative_container.hpp.

◆ is_loading() [1/2]

bool cereal::is_loading ( const typename std::enable_if< is_cereal_archive< Archive >::value, Archive >::type *  = 0)

Definition at line 40 of file is_loading.hpp.

◆ is_loading() [2/2]

bool cereal::is_loading ( const typename std::enable_if< !is_cereal_archive< Archive >::value, Archive >::type *  = 0)

Definition at line 48 of file is_loading.hpp.

◆ is_saving() [1/2]

bool cereal::is_saving ( const typename std::enable_if< is_cereal_archive_saving< Archive >::value, Archive >::type *  = 0)

Definition at line 41 of file is_saving.hpp.

◆ is_saving() [2/2]

bool cereal::is_saving ( const typename std::enable_if< !is_cereal_archive_saving< Archive >::value, Archive >::type *  = 0)

Definition at line 49 of file is_saving.hpp.

◆ make_array()

ArrayWrapper<T> cereal::make_array ( T *&  t,
S &  s 
)
inline

This function is used to serialized old c-style array.

Parameters
tC Style array.
sthe size of the array.

Definition at line 74 of file array_wrapper.hpp.

◆ make_pointer()

PointerWrapper<T> cereal::make_pointer ( T *&  t)
inline

Serialize raw pointer object by encapsulating the pointer into a smart pointer.

Parameters
tA reference to raw pointer to be serialized.

Definition at line 83 of file pointer_wrapper.hpp.

◆ make_pointer_vector()

PointerVectorWrapper<T> cereal::make_pointer_vector ( std::vector< T *> &  t)
inline

Serialize an std::vector that holds raw pointer object by encapsulating them into a smart pointer.

Parameters
tA reference to std::vector that holds raw pointer to be serialized.

Definition at line 80 of file pointer_vector_wrapper.hpp.