mirror of
https://github.com/boostorg/graph.git
synced 2026-02-11 11:52:12 +00:00
added root_vertex()
[SVN r10041]
This commit is contained in:
@@ -41,6 +41,7 @@ namespace boost {
|
||||
struct vertex_invariant_t { enum { num =detail::vertex_invariant_num}; };
|
||||
struct vertex_root_t { enum { num =detail::vertex_root_num}; };
|
||||
struct orig_to_copy_t { enum { num = detail::orig_to_copy_num }; };
|
||||
struct root_vertex_t { enum { num = detail::root_vertex_num }; };
|
||||
|
||||
namespace detail {
|
||||
template <class T>
|
||||
@@ -106,6 +107,13 @@ namespace boost {
|
||||
return Params(pmap, *this);
|
||||
}
|
||||
|
||||
template <typename Vertex>
|
||||
bgl_named_params<Vertex, root_vertex_t, self>
|
||||
root_vertex(const Vertex& r) const {
|
||||
typedef bgl_named_params<Vertex, root_vertex_t, self> Params;
|
||||
return Params(r, *this);
|
||||
}
|
||||
|
||||
template <typename ColorMap>
|
||||
bgl_named_params<ColorMap, vertex_color_t, self>
|
||||
color_map(const ColorMap& pmap) const {
|
||||
@@ -289,6 +297,13 @@ namespace boost {
|
||||
return Params(pmap);
|
||||
}
|
||||
|
||||
template <typename Vertex>
|
||||
bgl_named_params<Vertex, root_vertex_t>
|
||||
root_vertex(const Vertex& r) {
|
||||
typedef bgl_named_params<Vertex, root_vertex_t> Params;
|
||||
return Params(r);
|
||||
}
|
||||
|
||||
template <typename ColorMap>
|
||||
bgl_named_params<ColorMap, vertex_color_t>
|
||||
color_map(ColorMap pmap) {
|
||||
|
||||
Reference in New Issue
Block a user