Hi,
I have a mutable property undirected graph. I want to delete all the
vertices and edges in the graph.
I tried using the for loop
for( b = *vertices( databaseGraph ).first; b!= *vertices(
databaseGraph ).second; b++ ){
clear_vertex( b, databaseGraph );
remove_vertex( b, databaseGraph );
}
This works fine for some extent, but then crashes. My guess is that
the loop crashes when it reaches a vertex whose edges have not been
deleted. But my speculation was that clear_vertex deletes all the
edges associated with a vertex and the function should not crash when
clear_vertex is called before remove_vertex.
Clearly, I am making a mistake, but am not able to point it out.
Can you let me know what is the correct way of deleting all edges and
vertices in a mutable property undirected graph.
Thanks in anticipation.
Regards,
Abhijit
_______________________________________________
Boost-users mailing list
Boost...@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users