[BGL, Serialization] Serialization of vertex|edege properties
Hi folks,
I am using the BGL and now I want to serialize the graph.
Serialization of the vertices and edges works fine, but how do I serialize
the vertex|edge properties?
My properties and graph definition are the following:
<code>
struct vertex_cId_t {
typedef vertex_property_tag kind;
};
struct vertex_cType_t {
typedef vertex_property_tag kind;
};
struct vertex_cShape_t {
typedef vertex_property_tag kind;
};
struct edge_cType_t {
typedef vertex_property_tag kind;
};
struct edge_cColor_t {
typedef vertex_property_tag kind;
};
namespace boost {
BOOST_INSTALL_PROPERTY(vertex, cId);
BOOST_INSTALL_PROPERTY(vertex, cType);
BOOST_INSTALL_PROPERTY(vertex, cShape);
BOOST_INSTALL_PROPERTY(edge, cType);
BOOST_INSTALL_PROPERTY(edge, cColor);
}
typedef property
Hi David, On Oct 15, 2007, at 9:22 AM, David Angelo wrote:
I am using the BGL and now I want to serialize the graph. Serialization of the vertices and edges works fine, but how do I serialize the vertex|edge properties? [snip] typedef property
CVertexId; typedef property CVertexShape; typedef property CVertexAttribute; typedef property
CEdgeColor; typedef property CEdgeAttribute; typedef adjacency_list
Graph; </code> How must the serialize functions for CVertexAttribute and CEdgeAttribute look like?
The serialization code for property<...> types is in boost/pending/ property_serialize.hpp, which is already included by the BGL serialization code for adjacency lists. Are you running into some kind of compilation error? - Doug
participants (2)
-
David Angelo
-
Doug Gregor