/************************************************* * Pipe wrapper using Boost.Python * * (C) 2005-2006 Jack Lloyd * *************************************************/ #include using namespace boost::python; #include using namespace Botan; void export_pipe() { void (Pipe::*pipe_write1)(const std::string&) = &Pipe::write; void (Pipe::*pipe_write2)(const byte[], u32bit) = &Pipe::write; class_("Pipe") .def(init< Python_Filter*, optional >()) .def("start_msg", &Pipe::start_msg) .def("end_msg", &Pipe::end_msg) .def("write", pipe_write1) .def("write", pipe_write2) .def("read_all", &Pipe::read_all_as_string); }