Commit a557040a authored by Pierre Fernbach's avatar Pierre Fernbach
Browse files

[Format]

parent 85c475ff
......@@ -26,7 +26,9 @@ void exposeEnumContactType() {
.value("CONTACT_POINT", CONTACT_POINT);
}
void exposeScenarioEnums() { exposeEnumConicType(); exposeEnumContactType();}
void exposeScenarioEnums() {
exposeEnumConicType();
exposeEnumContactType();
}
} // namespace python
} // namespace multicontact_api
......@@ -260,7 +260,6 @@ struct ContactSequencePythonVisitor : public bp::def_visitor<ContactSequencePyth
static bp::list getAllEffectorsInContactAsList(CS& self) {
return toPythonList<std::string>(self.getAllEffectorsInContact());
}
};
} // namespace python
} // namespace multicontact_api
......
......@@ -13,22 +13,20 @@ namespace bp = boost::python;
template <typename Derived>
struct cs_pickle_suite : bp::pickle_suite {
static bp::object getstate(const Derived& cs) {
std::ostringstream os;
boost::archive::text_oarchive oa(os);
oa << cs;
return bp::str(os.str());
}
static bp::object getstate (const Derived& cs) {
std::ostringstream os;
boost::archive::text_oarchive oa(os);
oa << cs;
return bp::str(os.str());
}
static void
setstate(Derived& cs, bp::object entries) {
bp::str s = bp::extract<bp::str> (entries)();
std::string st = bp::extract<std::string> (s)();
std::istringstream is (st);
boost::archive::text_iarchive ia (is);
ia >> cs;
}
static void setstate(Derived& cs, bp::object entries) {
bp::str s = bp::extract<bp::str>(entries)();
std::string st = bp::extract<std::string>(s)();
std::istringstream is(st);
boost::archive::text_iarchive ia(is);
ia >> cs;
}
};
template <typename Derived>
......
......@@ -29,7 +29,8 @@ struct ContactPatchTpl : public serialization::Serializable<ContactPatchTpl<_Sca
ContactPatchTpl(const SE3& placement, const Scalar mu) : m_contact_model(mu), m_placement(placement) {}
/// \brief Copy constructor
ContactPatchTpl(const ContactPatchTpl& other) : m_contact_model(other.m_contact_model), m_placement(other.m_placement) {}
ContactPatchTpl(const ContactPatchTpl& other)
: m_contact_model(other.m_contact_model), m_placement(other.m_placement) {}
const SE3& placement() const { return m_placement; }
SE3& placement() { return m_placement; }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment