I was wondering if someone could give me a tip on how to construct the
following graph. The problem is that the queue type definition does not
know what "edge" is until the type definition for the graph is created.
Is there a way to get around this?
Thank you
#include
#include <queue>
// Type definition for a priority queue of (double,edge) pairs
typedef std::priority_queue > edge_queue;
struct vertex_edge_priority_t {
typedef vertex_property_tag kind;
};
// Vertex properties:
typedef property < vertex_edge_priority_t, edge_queue
> domainVertexProperty;
// Edge propeties:
typedef property < edge_index_t, int,
property < edge_weight_t, double > > domainEdgeProperty;
// Graph used to represent possible vertices and edges within the domain.
typedef adjacency_list<
setS,
vecS,
undirectedS,
domainVertexProperty,
domainEdgeProperty
> domainGraph;
typedef graph_traits<domainGraph>::edge_descriptor edge;