mirror of
https://github.com/Electrostatics/apbs.git
synced 2026-06-08 06:54:22 +08:00
Initial module for porting swig BS to pybind11; see #19
This commit is contained in:
24
tools/python-pybind/module.cpp
Normal file
24
tools/python-pybind/module.cpp
Normal file
@@ -0,0 +1,24 @@
|
||||
#include <pybind11/pybind11.h>
|
||||
|
||||
#include "bind_nosh.hpp"
|
||||
|
||||
/**
|
||||
* @file tools/python-pybind/module.cpp
|
||||
* @author Asher Mancinelli <asher.mancinelli@pnnl.gov>
|
||||
*
|
||||
* @brief Glue code that binds each function/class to python
|
||||
*
|
||||
* @note Keep all binding functions in their own header/impl pair. No raw
|
||||
* functions should live in this file; this is for *binding only*.
|
||||
*/
|
||||
|
||||
namespace py = pybind11;
|
||||
|
||||
PYBIND11_MODULE(apbs, m) {
|
||||
m.doc() = R"pbdoc(
|
||||
)pbdoc";
|
||||
|
||||
/// @see bind_nosh.hpp
|
||||
m.def("parseInputFromString", &parseInputFromString);
|
||||
m.def("getPotentials", &getPotentials<double>);
|
||||
}
|
||||
Reference in New Issue
Block a user