Boost logo

Boost Users :

From: Johan Oudinet (johan.oudinet_at_[hidden])
Date: 2005-11-21 05:01:06


Hello,
I have a graph representing the Network topology and I want to replace
it by a BGL graph.
My problem is that I need to find a vertex by its IP address (an
internal property), but I think we can only find a vertex with its
vertex_descriptor. A solution is to maintain a map from IP address to
vertex_descriptor.
But removing a vertex with vecS for VertexList invalidates all vertex
descriptors. Unfortunately, I need some efficiently to find a vertex,
so listS seems not appropriated.
Finally, I try to use setS for VertexList (and it works IMHO), but in
the documentation:
"The container must model Sequence or RandomAccessContainer."

Hence, my questions are:
- Can I use setS for VertexList ? And if I can't, why ?
- Is there a better solution to find vertex by an internal property
that handle an exterior map ?

Cheers,

--
Johan

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