
23 Jun
2010
23 Jun
'10
12:26 p.m.
On Wed, 23 Jun 2010, Muthuveerappan Alagappan wrote:
Hi,
I am a newbie to boost graph library (BGL).
1) To build a graph with vertices with unique ids - Able to do this 2) To get the vertex containing a specific idsI have created a graph with vertices that have a custom property. - how can I do this ?
The way I have tried to do is to iterate through all the vertices and checked each vertex's property value. Is there a better way to do this ?
Note - This field is a unique Id field
Can it be indexed based on the unique id, so that it can be accessed directly ?
There is no BGL way to do this; you should probably use an external map or unordered_map (or Boost.MultiIndex) for the lookups. -- Jeremiah Willcock