diff --git a/modules/mol/base/pymod/export_atom.cc b/modules/mol/base/pymod/export_atom.cc index 5891f4c10d8bdb34bfc7303a392049cf543e09dc..48695455dd9a816476e543ffdb89d24f26c4b51d 100644 --- a/modules/mol/base/pymod/export_atom.cc +++ b/modules/mol/base/pymod/export_atom.cc @@ -50,7 +50,6 @@ void export_Atom() return_value_policy<copy_const_reference>()), &AtomBase::SetName) .add_property("index", &AtomBase::GetIndex) - .def("GetRadius", &AtomBase::GetRadius) .def("GetElement", &AtomBase::GetElement, return_value_policy<copy_const_reference>()) @@ -85,6 +84,7 @@ void export_Atom() .def("GetBondList", &AtomHandle::GetBondList) .def("GetBondCount", &AtomHandle::GetBondCount) .def("GetEntity", &AtomHandle::GetEntity) + .add_property("bonds", &AtomHandle::GetBondList) .def("GetHandle", &AtomHandle::GetHandle) .add_property("handle", &AtomHandle::GetHandle) .add_property("entity", &AtomHandle::GetEntity) diff --git a/modules/mol/base/pymod/export_bond.cc b/modules/mol/base/pymod/export_bond.cc index 7309ef939edb58d4609df9618d58c504ee5f7664..b5da041244cd0ec9dfc204f9c173d309adc90565 100644 --- a/modules/mol/base/pymod/export_bond.cc +++ b/modules/mol/base/pymod/export_bond.cc @@ -26,7 +26,9 @@ using namespace boost::python; using namespace ost; using namespace ost::mol; + #include <ost/export_helper/generic_property_def.hh> +#include <ost/export_helper/vector.hh> void export_Bond() { @@ -38,8 +40,6 @@ void export_Bond() make_function(&BondHandle::GetFirst)) .add_property("second", make_function(&BondHandle::GetSecond)) - .add_property("other", - make_function(&BondHandle::GetOther)) .add_property("length", &BondHandle::GetLength) .add_property("bond_order", @@ -59,6 +59,7 @@ void export_Bond() generic_prop_def<BondHandle>(bond_handle); class_<BondHandleList>("BondHandleList", no_init) .def(vector_indexing_suite<BondHandleList>()) + .def(ost::VectorAdditions<BondHandleList>()) ; def("BondExists", &BondExists); }