Specialization of YAML::convert for std::shared_ptr, this is used to redirect the serialization of a derived class to the specialization of the serialization for a base class, for example all subclasses of Component can use the Component serialization specialization, currently each redirection has to be implemented separately, the re is probably a way to do this automatically.
More...
#include <SurgSim/Framework/FrameworkConvert.h>
template<class T>
struct YAML::convert< std::shared_ptr< T > >
Specialization of YAML::convert for std::shared_ptr, this is used to redirect the serialization of a derived class to the specialization of the serialization for a base class, for example all subclasses of Component can use the Component serialization specialization, currently each redirection has to be implemented separately, the re is probably a way to do this automatically.
- Template Parameters
-
T | class that should be converted from a shared ptr |
§ decode()
template<class T >
bool YAML::convert< std::shared_ptr< T > >::decode |
( |
const Node & |
node, |
|
|
typename std::enable_if< std::is_base_of< SurgSim::Framework::Component, T >::value, std::shared_ptr< T >>::type & |
rhs |
|
) |
| |
|
static |
§ encode()
template<class T >
YAML::Node YAML::convert< std::shared_ptr< T > >::encode |
( |
const typename std::enable_if< std::is_base_of< SurgSim::Framework::Component, T >::value, std::shared_ptr< T >>::type |
rhs | ) |
|
|
static |
The documentation for this struct was generated from the following files: