Boost logo

Boost Users :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2004-04-01 01:17:28

Douglas Paul Gregor wrote:

> The only thing I've ever found complex in the BGL is actually forming a
> graph type out of adjacency_list. Every single time I need a graph I have
> to read through the adjacency_list documentation to figure out what to do,
> although often I just copy the typedef from somewhere else. Simplified
> graph adaptors could really help here.

Agreed. For example, I never can remember the order of all template
arguments to adjacency_list, and declaration of properties. Maybe, some
combination of "named template parameters" and mpl::list would help:

   adjacency_list< graph_config<
        vertex_property_t, mpl::list<vertex_index_t, unsigned,
                                     vertex_name_t, std::string>,
        edge_property_t, mpl::list<edge_weight_t, float> > > graph;

The "associative_list" that was posted some time ago probably can be used to
implement this syntax.

(BTW, shouldn't we move this conversation to the main mailing list. After
all, we're not talking how to use existing interface, but how it can be

- Volodya

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at