Boost logo

Boost Users :

Subject: [Boost-users] [BGL] Usage of stateful allocator
From: Geoff Hilton (geoff.hilton_at_[hidden])
Date: 2010-06-03 13:25:18


Is a static instance of a stateful allocator the only way to make the
BGL graph interface accept it with boost::container_gen, or is the use
of a stateful allocator with the BGL possible?

The reason this is necessary is that I'd like to wrap an array class
(which isn't STL compatible) provided by a third party for use with the
BGL so that I can navigate the array of vertices and edges as modeled by
the graph it contains. This array class however is useless unless it
receives a reference to an instance of the stateful allocator upon its'
construction. Currently I have to hold a BGL graph in memory which
contains vertex and edge array indices reflecting matching positions in
instances of the third party array class (one for the vertices, one for
all the edges). (Unrelatedly but possibly useful to know) Once this
graph is complete, I need access to the arrays themselves to pass them
on to other objects that are part of the third party library.

Thanks,
Geoff


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