
8 Sep
2006
8 Sep
'06
8:18 p.m.
Hi,
newbie in python and boost::python
I have a method in c++ that returns a vector of strings, how can i
expose this method in python, and how should i use it in python
class A
{
public:
std::vectorstd::string getName();
};
BOOST_PYTHON_MODULE(pysession)
{
class_<A>("A")
.def("GetName" ,&A::getName)
}
now in python how could i call the function getName() ?
here is my error in python
TypeError: No to_python (by-value) converter found for C++ type: class
std::vect
or