Use class_.staticmethod(...) as shown below:

On Friday 30 October 2009 17:47:45 James Amundson wrote:
> BOOST_PYTHON_MODULE(foo)
> {
>      class_<Foo>("Foo",init<>())
>      .def("doit", &Foo::doit)

       .staticmethod( "doit" )

>      .def("nonstatic_doit", &Foo::nonstatic_doit)
>      ;
> }
 
Regards,
Ravi

_______________________________________________
Cplusplus-sig mailing list
Cplusplus-sig@python.org
http://mail.python.org/mailman/listinfo/cplusplus-sig

Reply via email to