Boost logo

Boost Users :

Subject: [Boost-users] [BGL] - deriving from filtered_graph
From: Michael Fawcett (michael.fawcett_at_[hidden])
Date: 2009-01-27 10:22:03


When using a type that I derived from filtered_graph, if I use
operator[] on the instance, e.g.

derived_from_filtered_graph_instance[descriptor].foo = bar;

I get the following error:

C:\dev\vendor\boost\1.37.0\boost/graph/graph_traits.hpp(124) : error
C2039: 'edge_bundled' : is not a member of
'btra::restricted_graph<Graph>'
1> with
1> [
1> Graph=btra::undirected_graph
1> ]
1> C:\dev\vendor\boost\1.37.0\boost/graph/graph_traits.hpp(137)
: see reference to class template instantiation
'boost::edge_bundle_type<G>' being compiled
1> with
1> [
1> G=btra::restricted_graph<btra::undirected_graph>
1> ]
1> C:\dev\btra\trunk\btra/two_way/esri_io.h(186) : see
reference to class template instantiation
'boost::graph::detail::bundled_result<Graph,Descriptor>' being
compiled
1> with
1> [
1> Graph=btra::restricted_graph<btra::undirected_graph>,
1> Descriptor=boost::detail::edge_desc_impl<boost::undirected_tag,__w64
unsigned int>
1> ]

and if I typedef edge_bundled in the derived class, everything seems
to work okay. filtered_graph doesn't contain the typedef, the Graph
type does, so does this mean that to be more correct I should
specialize graph_traits for my derived type, or is just having the
typedef enough?

Also, in the filtered_graph documentation, it says it models
VertexAndEdgeListGraph and PropertyGraph, but neither of those
concepts mention edge_bundled as an associated type.

Thanks in advance,

--Michael Fawcett


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