Elements  6.2
A C++ base framework for the Euclid Software.
callback.cpp
Go to the documentation of this file.
1 
22 #include <pybind11/functional.h>
23 #include <pybind11/pybind11.h>
24 #include <pybind11/stl.h>
25 #include <pyerrors.h>
26 
28 #include "ElementsKernel/Export.h"
29 
31  mod.def("test", &Elements::Examples::testCallBack);
32 }
Export.h
defines the macros to be used for explicit export of the symbols
ELEMENTS_API
#define ELEMENTS_API
Dummy definitions for the backward compatibility mode.
Definition: Export.h:74
callBackExample.h
Elements::Examples::testCallBack
ELEMENTS_API double testCallBack(std::vector< double > x, const std::function< double(std::vector< double >)> &fun)
Definition: callBackExample.cpp:34
PYBIND11_MODULE
ELEMENTS_API PYBIND11_MODULE(testCallBack, mod)
Definition: callback.cpp:30