Boost logo

Boost Users :

From: Robert Ramey (ramey_at_[hidden])
Date: 2005-06-17 10:47:22


The serialization library is designed to make the possible - and hopefully
easy - without modification of the BGL library. This depends on the BGL
library exposing enough information in order to save and load back the state
of the objects it uses. I can't know that it does this. Note that
serialization is implemented totally non-intrusively for all std
collections, variant and now shared_ptr. So what you want to do should be
possible.

Robert Ramey

Jean-Noël Rivasseau wrote:
> Hello,
>
> I was wondering if one could use Boost serialization library with the
> Boost Graph Library. Specifically, if one my class holds a graph (for
> example, an adjacency_list class), is it possible to serialize it?
> From what I've read from the Boost serialization documentation, this
> doesn't seem possible as it eventually requires access to the class
> members; in the case of the BGL, the implementation of the classes is
> probably so complex that I wouldn't go through that route; plus, they
> may very well be private.
>
> I was wondering if there is any way to do serialization via the
> public interface of the BGL (ie, add_edge, etc...) ? If I understood
> the Serialization library correctly, everything works via the
> operator & which acts as >> and <<. If I define a << operator for the
> BGL classes, that implement the export / import operations, needed,
> would it be possible to use the BGL with serialization?
>
> Any help from knowledgeable people would be appreciated (I now have a
> quite good knowledge of the BGL but I am new to the serialization
> library).
>
> Jean-Noël


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