Nothing too much changed: * box distrubutions (IMP::algebra::random_vector_on_box(), IMP::algebra::random_vector_in_box()) take bounding boxes
* IMP::em::DensityMap are now IMP::Object objects. Some current allocations on the stack may need to be changed.
* IMP::em::DensityMap::Read() is now deprecated (as is Write). Use the more conventional IMP::em::read_map() and IMP::em::write_map() instead.
Remember, any time an object accepts and stores a pointer to another object, the passed object must be reference counted. Otherwise it is very difficult for users to get memory management correct. To make an object reference counted inherit from RefCounted or Object and used IMP::Pointer instead of a raw pointer to store.
can you please refer to examples of IMP::Pointer for storing ? On Jun 26, 2009, at 10:58 PM, Daniel Russel wrote:
> Nothing too much changed: > * box distrubutions (IMP::algebra::random_vector_on_box(), > IMP::algebra::random_vector_in_box()) take bounding boxes > > * IMP::em::DensityMap are now IMP::Object objects. Some current > allocations on the stack may need to be changed. > > * IMP::em::DensityMap::Read() is now deprecated (as is Write). Use > the more conventional IMP::em::read_map() and IMP::em::write_map() > instead. > > Remember, any time an object accepts and stores a pointer to another > object, the passed object must be reference counted. Otherwise it is > very difficult for users to get memory management correct. To make an > object reference counted inherit from RefCounted or Object and used > IMP::Pointer instead of a raw pointer to store. > _______________________________________________ > IMP-dev mailing list > IMP-dev@salilab.org > https://salilab.org/mailman/listinfo/imp-dev
Keren Lasker wrote: > can you please refer to examples of IMP::Pointer for storing ?
Most of the PairScores (e.g. IMP::core::DistancePairScore) keep a reference to a UnaryFunction, and use an IMP::Pointer to keep track of that.
Ben
participants (3)
-
Ben Webb
-
Daniel Russel
-
Keren Lasker