Chapter 10. Interfacing with Other Graph Libraries
Although the main goal of BGL is to aid the development of new applications and graph algorithms, there are quite a few existing codes that can benefit from using BGL algorithms. One way to use the BGL algorithms with existing graph data structures is to copy data from the older graph format into a BGL graph, which is then used with the BGL algorithms. The problem with this approach is that it can be inconvenient and expensive to perform this copy. Another approach is to use the existing data structure directly by wrapping it with a BGL interface.
The Adaptor pattern [14] is one mechanism for providing a new interface to an existing class. This approach typically requires that the adapted object ...
Get The Boost Graph Library: User Guide and Reference Manual now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.