5 #ifndef __pinocchio_python_multibody_joint_joint_hpp__ 6 #define __pinocchio_python_multibody_joint_joint_hpp__ 8 #include <boost/python.hpp> 10 #include "pinocchio/multibody/joint/joint-generic.hpp" 20 :
public boost::python::def_visitor< JointModelPythonVisitor >
23 template<
class PyClass>
27 .def(bp::init<>(bp::arg(
"self")))
29 .add_property(
"id",&
getId)
32 .add_property(
"nq",&
getNq)
33 .add_property(
"nv",&
getNv)
36 bp::args(
"self",
"id",
"idx_q",
"idx_v"))
37 .def(
"hasSameIndexes",
38 &JointModel::hasSameIndexes<JointModel>,
40 "Check if this has same indexes than other.")
43 .def(bp::self == bp::self)
44 .def(bp::self != bp::self)
56 bp::class_<JointModel>(
"JointModel",
57 "Generic Joint Model",
59 .def(bp::init<JointModel>(
bp::args(
"self",
"other")))
69 #endif // ifndef __pinocchio_python_multibody_joint_joint_hpp__ static int getIdx_q(const JointModel &self)
Set the Python method str and repr to use the overloading operator<<.
static int getNv(const JointModel &self)
static int getNq(const JointModel &self)
static int getIdx_v(const JointModel &self)
void visit(PyClass &cl) const
std::string shortname() const
void setIndexes(JointIndex id, int nq, int nv)
Main pinocchio namespace.
static JointIndex getId(const JointModel &self)