| 16 | namespace aimrt::runtime::python_runtime { |
| 17 | |
| 18 | inline void ExportExecutorManagerRef(pybind11::object m) { |
| 19 | using aimrt::executor::ExecutorManagerRef; |
| 20 | |
| 21 | pybind11::class_<ExecutorManagerRef>(std::move(m), "ExecutorManagerRef") |
| 22 | .def(pybind11::init<>()) |
| 23 | .def("__bool__", &ExecutorManagerRef::operator bool) |
| 24 | .def("GetExecutor", &ExecutorManagerRef::GetExecutor); |
| 25 | } |
| 26 | |
| 27 | inline void PyExecutorRefExecuteWrapper( |
| 28 | aimrt::executor::ExecutorRef& executor, std::function<void()>&& task) { |