mlpack
Public Member Functions | List of all members
cereal::PointerWrapper< T > Class Template Reference

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...

#include <pointer_wrapper.hpp>

Public Member Functions

 PointerWrapper (T *&pointer)
 
template<class Archive >
void save (Archive &ar, const uint32_t) const
 
template<class Archive >
void load (Archive &ar, const uint32_t)
 
T *& release ()
 

Detailed Description

template<class T>
class cereal::PointerWrapper< T >

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

Cereal does not support the serialization of raw pointer out of the box. Therefore, we have created this wrapper to serialize raw pointer in cereal as a smart pointer since because it will be difficult to change all pointer type in mlpack.


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