Class to extract a c++ class that was exposed to python with Swig. @detials This class is used to unwrap a c++ class that was exposed to python with Swig and then passed to MUQ through pybind11 bindings. The class is defined in a way to enable straightforward conversions with code like. More...
#include <SwigExtract.h>
Class to extract a c++ class that was exposed to python with Swig. @detials This class is used to unwrap a c++ class that was exposed to python with Swig and then passed to MUQ through pybind11 bindings. The class is defined in a way to enable straightforward conversions with code like.
Instead of using the implicit conversion, it is also possible to explicitly cast the python object:
Definition at line 35 of file SwigExtract.h.
Public Member Functions | |
SwigExtract (pybind11::object const &objIn) | |
template<typename T > | |
operator T () | |
template<typename T > | |
T | Cast () |
|
inline |
Definition at line 39 of file SwigExtract.h.
|
inline |
Definition at line 48 of file SwigExtract.h.
References obj.
Referenced by muq::Modeling::FenicsPiece::EvaluateFunc().
|
inlineprivate |
Definition at line 76 of file SwigExtract.h.
References obj.
|
inline |
Definition at line 42 of file SwigExtract.h.
|
private |
Definition at line 73 of file SwigExtract.h.
Referenced by Cast(), and ConversionError().