cereal
A C++11 library for serialization
Static Public Member Functions | List of all members
cereal::access Class Reference

A class that can be made a friend to give cereal access to non public functions. More...

#include </build/libcereal-SAfJB3/libcereal-1.3.2+dfsg/include/cereal/access.hpp>

Static Public Member Functions

template<class Archive , class T >
static auto member_serialize (Archive &ar, T &t) -> decltype(t.CEREAL_SERIALIZE_FUNCTION_NAME(ar))
 
template<class Archive , class T >
static auto member_save (Archive &ar, T const &t) -> decltype(t.CEREAL_SAVE_FUNCTION_NAME(ar))
 
template<class Archive , class T >
static auto member_save_non_const (Archive &ar, T &t) -> decltype(t.CEREAL_SAVE_FUNCTION_NAME(ar))
 
template<class Archive , class T >
static auto member_load (Archive &ar, T &t) -> decltype(t.CEREAL_LOAD_FUNCTION_NAME(ar))
 
template<class Archive , class T >
static auto member_save_minimal (Archive const &ar, T const &t) -> decltype(t.CEREAL_SAVE_MINIMAL_FUNCTION_NAME(ar))
 
template<class Archive , class T >
static auto member_save_minimal_non_const (Archive const &ar, T &t) -> decltype(t.CEREAL_SAVE_MINIMAL_FUNCTION_NAME(ar))
 
template<class Archive , class T , class U >
static auto member_load_minimal (Archive const &ar, T &t, U &&u) -> decltype(t.CEREAL_LOAD_MINIMAL_FUNCTION_NAME(ar, std::forward< U >(u)))
 
template<class Archive , class T >
static auto member_serialize (Archive &ar, T &t, const std::uint32_t version) -> decltype(t.CEREAL_SERIALIZE_FUNCTION_NAME(ar, version))
 
template<class Archive , class T >
static auto member_save (Archive &ar, T const &t, const std::uint32_t version) -> decltype(t.CEREAL_SAVE_FUNCTION_NAME(ar, version))
 
template<class Archive , class T >
static auto member_save_non_const (Archive &ar, T &t, const std::uint32_t version) -> decltype(t.CEREAL_SAVE_FUNCTION_NAME(ar, version))
 
template<class Archive , class T >
static auto member_load (Archive &ar, T &t, const std::uint32_t version) -> decltype(t.CEREAL_LOAD_FUNCTION_NAME(ar, version))
 
template<class Archive , class T >
static auto member_save_minimal (Archive const &ar, T const &t, const std::uint32_t version) -> decltype(t.CEREAL_SAVE_MINIMAL_FUNCTION_NAME(ar, version))
 
template<class Archive , class T >
static auto member_save_minimal_non_const (Archive const &ar, T &t, const std::uint32_t version) -> decltype(t.CEREAL_SAVE_MINIMAL_FUNCTION_NAME(ar, version))
 
template<class Archive , class T , class U >
static auto member_load_minimal (Archive const &ar, T &t, U &&u, const std::uint32_t version) -> decltype(t.CEREAL_LOAD_MINIMAL_FUNCTION_NAME(ar, std::forward< U >(u), version))
 
template<class T >
static auto shared_from_this (T &t) -> decltype(t.shared_from_this())
 
template<class T , class ... Args>
static void construct (T *&ptr, Args &&... args)
 
template<class T >
static T * construct ()
 
template<class T >
static std::false_type load_and_construct (...)
 
template<class T , class Archive >
static auto load_and_construct (Archive &ar, ::cereal::construct< T > &construct) -> decltype(T::load_and_construct(ar, construct))
 
template<class T , class Archive >
static auto load_and_construct (Archive &ar, ::cereal::construct< T > &construct, const std::uint32_t version) -> decltype(T::load_and_construct(ar, construct, version))
 

Detailed Description

A class that can be made a friend to give cereal access to non public functions.

If you desire non-public serialization functions within a class, cereal can only access these if you declare cereal::access a friend.

class MyClass
{
private:
friend class cereal::access; // gives access to the private serialize
template <class Archive>
void serialize( Archive & ar )
{
// some code
}
};
A class that can be made a friend to give cereal access to non public functions.
Definition: access.hpp:241
void serialize(Archive &, std::less< T > &)
Saving for std::less.
Definition: functional.hpp:39

The documentation for this class was generated from the following file: