NEWBIE QUESTIONS ABOUT BGL
Hi, I've read most of the online documentation about the Boost Graph Library and I've tried a few examples but some questions remain unanswered: Properties: - Once we have a property map for vertices or edges, do we have to assign a value to each vertex (or edge) of the graph? (My preliminary tests tell me that we have to.) - Is the graph the only mean to iterate through all the elements of a property map that it owns? - What is the difference between a graph and a property graph: when would we choose to use a graph interface instead of a property graph? - How can I attach a local property to an element of a subgraph and still have the original property unchanged for the corresponding element on the parent graph? (At the time beeing it seems impossible to do so.) - How can I define a custom property within a specific namespace? PROBLEMS: It seems that there are compilers' limitations regarding the number of properties (and their value type) that can be attached to an adjacency_list (at least with CodeWarrior). Thanks in advance. __________________________________________________________ Lèche-vitrine ou lèche-écran ? magasinage.yahoo.ca
Properties can be either internal or external. An effective way to external properties is via std::map with a vertice or edge decriptor being used as the map's key. I believe this solution addresses both your questions. o a given vertice/edge need not have a property. o iterating the map is (or can be) independent of the graph. Hugues Joly wrote:
Hi, I've read most of the online documentation about the Boost Graph Library and I've tried a few examples but some questions remain unanswered:
Properties:
- Once we have a property map for vertices or edges, do we have to assign a value to each vertex (or edge) of the graph? (My preliminary tests tell me that we have to.)
- Is the graph the only mean to iterate through all the elements of a property map that it owns?
- What is the difference between a graph and a property graph: when would we choose to use a graph interface instead of a property graph?
- How can I attach a local property to an element of a subgraph and still have the original property unchanged for the corresponding element on the parent graph? (At the time beeing it seems impossible to do so.)
- How can I define a custom property within a specific namespace?
PROBLEMS:
It seems that there are compilers' limitations regarding the number of properties (and their value type) that can be attached to an adjacency_list (at least with CodeWarrior).
Thanks in advance.
__________________________________________________________ Lèche-vitrine ou lèche-écran ? magasinage.yahoo.ca _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
I have found this google link http://www.google.com/custom?hl=en&lr=&ie=ISO-8859-1&safe=off&cof=AWFID%3A9b83d16ce652ed5a%3BL%3Ahttp%3A%2F%2Fwww.boost.org%2Fc%2B%2Bboost.gif%3BLH%3A86%3BLW%3A277%3BAH%3Acenter%3BS%3Ahttp%3A%2F%2Fwww.boost.org%3B&domains=lists.boost.org%3Bwww.boost.org&q=&btnG=Google+Search&sitesearch=www.boost.org helpful. -d Hugues Joly wrote:
Hi, I've read most of the online documentation about the Boost Graph Library and I've tried a few examples but some questions remain unanswered:
Properties:
- Once we have a property map for vertices or edges, do we have to assign a value to each vertex (or edge) of the graph? (My preliminary tests tell me that we have to.)
- Is the graph the only mean to iterate through all the elements of a property map that it owns?
- What is the difference between a graph and a property graph: when would we choose to use a graph interface instead of a property graph?
- How can I attach a local property to an element of a subgraph and still have the original property unchanged for the corresponding element on the parent graph? (At the time beeing it seems impossible to do so.)
- How can I define a custom property within a specific namespace?
PROBLEMS:
It seems that there are compilers' limitations regarding the number of properties (and their value type) that can be attached to an adjacency_list (at least with CodeWarrior).
Thanks in advance.
__________________________________________________________ Lèche-vitrine ou lèche-écran ? magasinage.yahoo.ca _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
-- David Ohlemacher BBN Technologies 127 John Clarke Rd. Middletown, RI 02878 Phone: (401)848-3542, Fax:(401)849-8611 ohlemacher at bbn dot com
participants (3)
-
David Ohlemacher
-
Hugues Joly
-
Jeff Holle