I have a Boost Graph with VertexList=vecS.
typedef adjacency_list <listS, vecS, undirectedS, TrackInformation, LinkInformation> TracksConnectionGraph;
Now I want to iterate through my vertices and remove those that have a specific property. How can I do this?
The problem is whenever I call remove_vertex, the iterator to the vertices in the graph along with the vertex descriptors are invalidated.
I don’t think it is possible (in a reasonable time) with
vecSas a template parameter. Look what Boost documentation says:In case of
listSthe iterators are not invalidated by callingremove_vertexunless the iterator is pointing to the actual vertex that was removed.