Boost logo

Boost :

From: Dean Michael Berris (mikhailberis_at_[hidden])
Date: 2007-12-19 21:03:05


Hey!

On Dec 20, 2007 3:04 AM, Cromwell Enage <sponage_at_[hidden]> wrote:
> --- Dean Michael Berris wrote:
> > Hi Guys,
>
> Kumusta ka, pare!
>

I'm good. :)

> > Is there a definitive guide in the Boost.Graph
> > documentation about how to create custom
> > selectors?
>
> Try:
>
> <http://www.boost.org/libs/graph/doc/using_adjacency_list.html#sec:custom-storage>
>

I tried this, but I got a bunch of errors. Basically, what I tried
precisely are:

struct pooled_vectorS { }; // the selector

namespace boost {
  template <typename ValueType>
  struct container_gen<pooled_vectorS, ValueType> {
    typedef std::vector<ValueType, pool_allocator<ValueType> > type;
  };
};

Unfortunately, when I try to do:

typedef adjacency_list<
  pooled_vectorS,
  pooled_vectorS,
  undirectedS,
  property<vector_name_t, int,
    property<vector_distance_t, int,
      property<vector_color_t, int>
>
>
> graph_type;

graph_type my_graph;

I get a whole slew of errors which all boils down to:

/usr/local/lib/boost/boost/graph/adjacency_list.hpp:282: error: no
type named 'type' in 'struct
boost::parallel_edge_traits<pooled_vectorS>'

Am I missing something here?

I'm using the version in r41409.

-- 
Dean Michael C. Berris
Software Engineer, Friendster, Inc.
[http://cplusplus-soup.blogspot.com/]
[mikhailberis_at_[hidden]]
[+63 928 7291459]
[+1 408 4049523]

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk