
Hi Bruno, ----- Mensaje original ----- De: Bruno Martínez Aguerre <br1@internet.com.uy> Fecha: Viernes, Septiembre 24, 2004 10:44 pm Asunto: [boost] [Pointer Containers] [Indexed Set]
Hi.
I was wondering if these two libs work together. That is, can Indexed Sets take ownership of my pointers?
(First of all, the lib was renamed to Boost.MultiIndex.) Indexed containers are no different to STL containers in this respect: you can control ownership issues with some smart pointer, for instance boost::shared_ptr, so that objects pointed to get deleted along with the container. Apart from this, no special provision has been made to work with pointers. Ownership management aside, I'd say one of the key features of Thorsten's pointer containers is that their interface automatically dereference the pointers held so as to create the illusion that it is the actual elements that are being stored in the container. This feature is not supported by Boost.MultiIndex, and I don't think both libs can be used together to implement this artifact. To get something close to that, you can put a "view" on top of a multi_index_container of pointers and get dereferencing access. There are some view libraries out there.
Also, I couldn't find the docs for neither of the two libs. I looked here http://www.boost.org/regression-logs/cs- win32_metacomm/doc/html/libraries.html for Indexed Set,
The lib was renamed to Boost.MultiIndex, and will ship with Boost 1.32. In the meantime you can consult the docs at www.boost-consulting.com/boost/libs/multi_index
and here http://boost-consulting.com/boost/more/formal_review_schedule.html for Pointer Containers.
This Thorsten already anwered. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo