|
Boost Users : |
From: Bill Lear (rael_at_[hidden])
Date: 2007-08-19 09:34:02
On Saturday, August 18, 2007 at 16:51:34 (-0600) Dominick Layfield writes:
>...
>
>Fundamentally, there are two approaches to dealing with pointer
>serialization: (1) disallow it altogether; or (2) serialize the
>pointed-to object, and do all the clever object-tracking stuff.
>
>The first approach has the benefit of simplicity . So the only
>reason to take the second approach would be if automagic pointer
>serialization is really useful.
>
>However, I can't think of an example of when this would be really
>useful. Hence my question.
I'm baffled how you can't see the utility of serializing pointers and
thereby maintaining object relationships. Suppose you have a list of
objects, and several other structures that map to this list and to
other lists of objects. These relational structures may be very
expensive to construct, and extremely large. Being able to write
this:
os & list & map1 & map;
Instead of rebuilding the maps is very convenient.
Were we not to have object tracking, it would have made my job
serializing our massive and intertwined data structures much, much
more difficult.
Bill
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net