Boost Users :
From: Gustavo Sánchez (gustsanc_at_[hidden])
Date: 2004-04-02 03:54:34
I'm developing a hardware test program with some class abstractions like resistor, diode, relay ... which I stick to the BGL graph structure in the edge properties. I so have some information associated with vertices, and the result is a set of data composed of the graph itself - an ajacency_list - the graph properties for edges and vertices and a couple of vectors for the abstractions. My problem is how can I manage all these data in an OO program. The method used in BGL examples (just declare all these in main ) is right just for that, but in a more complex object colaboration society I consider it to be simple and useless. I just use a class named GraphContainer to package all the elements, but I wonder if there is any other better aproach...
property_map<UGraph, vertex_index_t>::type id;
property_map<UGraph, edge_name_t>::type name;
property_map<UGraph, vertex_name_t>::type vname;
std::map<string,boost::graph_traits<UGraph>::vertex_descriptor> vertx; // mapa vertices(string)--vertex_descriptor
Thanks a lot...
Antivirus • Filtros antispam • 6 MB gratis
¿Todavía no tienes un correo inteligente?
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