I’m having a bidirectional graph (i.e. a directed graph in which it is possible to iterate both the in-edges and the out-edges).
Each vertex, among other internal properties, has a special ID property which is an integer from a finite set (couple of hundreds) which is known at program's startup, that is – it won’t change during program's life time, but it is unknown at compile time.
This property is not unique at the scope of the graph (i.e. there can be two Vertices with the same ID), and therefore cannot be used with named/labeled_graph. It is however unique in the scope of a given Vertex, that is both the incoming neighbors and the outgoing neighbors of a vertex should all have different IDs.
My question is whether there is a build in mechanism in BGL to efficiently find an adjacent vertex u, of v given u’s descriptor, the graph, and the ID of u.
This can of course be achieve using some external mapping, but it feels like quite a common scenario, and given that the adjacency_list’s first template parameter can be an associative container – it seems only natural to have some kind of find_adjacent(v,g,ID) function, alas, I wasn’t able to find anything like it.
Many thanks, Andrey