Bernhard Maeder | 22 May 19:27

Re: [serialization] Handling of references into a std::map

Johan Råde <rade <at> maths.lth.se> writes:

> 
> Bernhard Maeder wrote:
> 
> You could save a reference to the map and the value of the key for the element.
> When you load the archive, you can use that information to reconstruct the
reference to the element.
> 
> --Johan Råde

Yes, I could do that, but it would be more complicated. In my real application,
I don't keep the references to that map's values in the same place with the map;
the reconstruction process would thus influence many other components as well,
which I wouldn't want to do. If I understand Boost.Serialization correctly (and
that is of course in doubt here! :-), it is able to accomplish these things for
you and should thus make the serialization code much less verbose.

Bernhard

_______________________________________________
Boost-users mailing list
Boost-users <at> lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users

Gmane