|
template<class Archive > |
typename ::cereal::detail::InputBindingMap< Archive >::Serializers | getInputBinding (Archive &ar, std::uint32_t const nameid) |
| Get an input binding from the given archive by deserializing the type meta data. More...
|
|
template<class Archive , class T > |
std::enable_if<(traits::is_default_constructible< T >::value||traits::has_load_and_construct< T, Archive >::value) &&!std::is_abstract< T >::value, bool >::type | serialize_wrapper (Archive &ar, std::shared_ptr< T > &ptr, std::uint32_t const nameid) |
| Serialize a shared_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee. More...
|
|
template<class Archive , class T , class D > |
std::enable_if<(traits::is_default_constructible< T >::value||traits::has_load_and_construct< T, Archive >::value) &&!std::is_abstract< T >::value, bool >::type | serialize_wrapper (Archive &ar, std::unique_ptr< T, D > &ptr, std::uint32_t const nameid) |
| Serialize a unique_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee. More...
|
|
template<class Archive , class T > |
std::enable_if<(!traits::is_default_constructible< T >::value &&!traits::has_load_and_construct< T, Archive >::value)||std::is_abstract< T >::value, bool >::type | serialize_wrapper (Archive &, std::shared_ptr< T > &, std::uint32_t const nameid) |
| Serialize a shared_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee. More...
|
|
template<class Archive , class T , class D > |
std::enable_if<(!traits::is_default_constructible< T >::value &&!traits::has_load_and_construct< T, Archive >::value)||std::is_abstract< T >::value, bool >::type | serialize_wrapper (Archive &, std::unique_ptr< T, D > &, std::uint32_t const nameid) |
| Serialize a unique_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee. More...
|
|
template<class Archive , class T >
Serialize a shared_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee.
This case is for when we can't actually construct the shared pointer. Normally this would be caught as the pointer itself is serialized, but since this is a polymorphic pointer, if we tried to serialize the pointer we'd end up back here recursively. So we have to catch the error here as well, if this was a polymorphic type serialized by its proper pointer type
template<class Archive , class T , class D >
Serialize a unique_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee.
This case is for when we can't actually construct the unique pointer. Normally this would be caught as the pointer itself is serialized, but since this is a polymorphic pointer, if we tried to serialize the pointer we'd end up back here recursively. So we have to catch the error here as well, if this was a polymorphic type serialized by its proper pointer type
template<class Archive , class T >
Serialize a shared_ptr if the 2nd msb in the nameid is set, and if we can actually construct the pointee.
This check lets us try and skip doing polymorphic machinery if we can get away with using the derived class serialize function
Note that on MSVC 2013 preview, is_default_constructible<T> returns true for abstract classes with default constructors, but on clang/gcc this will return false. So we also need to check for that here.