&, EdgeColorMap edge_color, VertexColorMap vertex_color) { undirected_dfs(g, vis, vertex_color, edge_color, start_vertex); } }; template <> struct udfs_dispatch { template static void apply(const Graph& g, DFSVisitor vis, Vertex start_vertex, const bgl_named_params& params, EdgeColorMap edge_color, detail::error_property_not_found) { std::vector color_vec(num_vertices(g)); default_color_type c = white_color; // avoid warning about un-init undirected_dfs (g, vis, make_iterator_property_map (color_vec.begin(), choose_const_pmap(get_param(params, vertex_index), g, vertex_index), c), edge_color, start_vertex); } }; } // namespace detail // Named Parameter Variant template void undirected_dfs(const Graph& g, const bgl_named_params& params) { typedef typename property_value< bgl_named_params, vertex_color_t>::type C; detail::udfs_dispatch::apply (g, choose_param(get_param(params, graph_visitor), make_dfs_visitor(null_visitor())), choose_param(get_param(params, root_vertex_t()), *vertices(g).first), params, get_param(params, edge_color), get_param(params, vertex_color) ); } template void undirected_depth_first_visit (const IncidenceGraph& g, typename graph_traits::vertex_descriptor u, DFSVisitor vis, VertexColorMap vertex_color, EdgeColorMap edge_color) { detail::undir_dfv_impl(g, u, vis, vertex_color, edge_color); } } // namespace boost #endif
& params, EdgeColorMap edge_color, detail::error_property_not_found) { std::vector color_vec(num_vertices(g)); default_color_type c = white_color; // avoid warning about un-init undirected_dfs (g, vis, make_iterator_property_map (color_vec.begin(), choose_const_pmap(get_param(params, vertex_index), g, vertex_index), c), edge_color, start_vertex); } }; } // namespace detail // Named Parameter Variant template void undirected_dfs(const Graph& g, const bgl_named_params& params) { typedef typename property_value< bgl_named_params, vertex_color_t>::type C; detail::udfs_dispatch::apply (g, choose_param(get_param(params, graph_visitor), make_dfs_visitor(null_visitor())), choose_param(get_param(params, root_vertex_t()), *vertices(g).first), params, get_param(params, edge_color), get_param(params, vertex_color) ); } template void undirected_depth_first_visit (const IncidenceGraph& g, typename graph_traits::vertex_descriptor u, DFSVisitor vis, VertexColorMap vertex_color, EdgeColorMap edge_color) { detail::undir_dfv_impl(g, u, vis, vertex_color, edge_color); } } // namespace boost #endif
& params) { typedef typename property_value< bgl_named_params
, vertex_color_t>::type C; detail::udfs_dispatch::apply (g, choose_param(get_param(params, graph_visitor), make_dfs_visitor(null_visitor())), choose_param(get_param(params, root_vertex_t()), *vertices(g).first), params, get_param(params, edge_color), get_param(params, vertex_color) ); } template void undirected_depth_first_visit (const IncidenceGraph& g, typename graph_traits::vertex_descriptor u, DFSVisitor vis, VertexColorMap vertex_color, EdgeColorMap edge_color) { detail::undir_dfv_impl(g, u, vis, vertex_color, edge_color); } } // namespace boost #endif