Nektar++
Public Member Functions | List of all members
ModuleWrapConverter< MODTYPE > Struct Template Reference

Public Member Functions

 ModuleWrapConverter ()
 

Detailed Description

template<typename MODTYPE>
struct ModuleWrapConverter< MODTYPE >

Definition at line 368 of file Python/Module.cpp.

Constructor & Destructor Documentation

◆ ModuleWrapConverter()

template<typename MODTYPE >
ModuleWrapConverter< MODTYPE >::ModuleWrapConverter ( )
inline

Definition at line 370 of file Python/Module.cpp.

371  {
372  // An important bit of code which will register allow
373  // shared_ptr<MODTYPE> as something that boost::python recognises,
374  // otherwise modules constructed from the factory will not work from
375  // Python.
376  py::objects::class_value_wrapper<
377  std::shared_ptr<MODTYPE>,
378  py::objects::make_ptr_instance<
379  MODTYPE, py::objects::pointer_holder<std::shared_ptr<MODTYPE>,
380  MODTYPE>>>();
381  }