2
0
mirror of https://github.com/boostorg/graph.git synced 2026-02-12 00:02:10 +00:00

provide access to unqualified pmap

[SVN r9922]
This commit is contained in:
Jeremy Siek
2001-04-23 18:19:56 +00:00
parent 61f5b67f8b
commit c0fe0b2432

View File

@@ -39,6 +39,7 @@ namespace boost {
struct vertex_copy_t { enum { num = detail::vertex_copy_num }; };
struct vertex_isomorphism_t { enum { num =detail::vertex_isomorphism_num}; };
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 }; };
namespace detail {
@@ -97,6 +98,14 @@ namespace boost {
return Params(pmap, *this);
}
template <typename RootMap>
bgl_named_params<RootMap, vertex_root_t, self>
root_map(const RootMap& pmap) const {
typedef bgl_named_params<RootMap, vertex_root_t, self>
Params;
return Params(pmap, *this);
}
template <typename ColorMap>
bgl_named_params<ColorMap, vertex_color_t, self>
color_map(const ColorMap& pmap) const {
@@ -104,6 +113,39 @@ namespace boost {
return Params(pmap, *this);
}
template <typename CapacityMap>
bgl_named_params<CapacityMap, edge_capacity_t, self>
capacity_map(CapacityMap pmap) {
typedef bgl_named_params<CapacityMap, edge_capacity_t, self> Params;
return Params(pmap, *this);
}
template <typename Residual_CapacityMap>
bgl_named_params<Residual_CapacityMap, edge_residual_capacity_t, self>
residual_capacity_map(Residual_CapacityMap pmap) {
typedef bgl_named_params<Residual_CapacityMap,
edge_residual_capacity_t, self>
Params;
return Params(pmap, *this);
}
template <typename ReverseMap>
bgl_named_params<ReverseMap, edge_reverse_t, self>
reverse_edge_map(ReverseMap pmap) {
typedef bgl_named_params<ReverseMap,
edge_reverse_t, self>
Params;
return Params(pmap, *this);
}
template <typename DiscoverTimeMap>
bgl_named_params<DiscoverTimeMap, vertex_discover_time_t, self>
discover_time_map(const DiscoverTimeMap& pmap) const {
typedef bgl_named_params<DiscoverTimeMap, vertex_discover_time_t, self>
Params;
return Params(pmap, *this);
}
template <typename IndexMap>
bgl_named_params<IndexMap, vertex_index_t, self>
vertex_index_map(const IndexMap& pmap) const {
@@ -240,6 +282,13 @@ namespace boost {
return Params(pmap);
}
template <typename RootMap>
bgl_named_params<RootMap, vertex_root_t>
root_map(RootMap pmap) {
typedef bgl_named_params<RootMap, vertex_root_t> Params;
return Params(pmap);
}
template <typename ColorMap>
bgl_named_params<ColorMap, vertex_color_t>
color_map(ColorMap pmap) {
@@ -247,6 +296,36 @@ namespace boost {
return Params(pmap);
}
template <typename CapacityMap>
bgl_named_params<CapacityMap, edge_capacity_t>
capacity_map(CapacityMap pmap) {
typedef bgl_named_params<CapacityMap, edge_capacity_t> Params;
return Params(pmap);
}
template <typename Residual_CapacityMap>
bgl_named_params<Residual_CapacityMap, edge_residual_capacity_t>
residual_capacity_map(Residual_CapacityMap pmap) {
typedef bgl_named_params<Residual_CapacityMap, edge_residual_capacity_t>
Params;
return Params(pmap);
}
template <typename ReverseMap>
bgl_named_params<ReverseMap, edge_reverse_t>
reverse_edge_map(ReverseMap pmap) {
typedef bgl_named_params<ReverseMap, edge_reverse_t>
Params;
return Params(pmap);
}
template <typename DiscoverTimeMap>
bgl_named_params<DiscoverTimeMap, vertex_discover_time_t>
discover_time_map(DiscoverTimeMap pmap) {
typedef bgl_named_params<DiscoverTimeMap, vertex_discover_time_t> Params;
return Params(pmap);
}
template <typename IndexMap>
bgl_named_params<IndexMap, vertex_index_t>
vertex_index_map(IndexMap pmap) {
@@ -383,6 +462,7 @@ namespace boost {
struct bind {
typedef const P& const_result_type;
typedef const P& result_type;
typedef P type;
static const_result_type const_apply(const P& p, const Graph&, Tag&)
{ return p; }
static result_type apply(const P& p, Graph&, Tag&)
@@ -424,6 +504,7 @@ namespace boost {
typedef typename Selector:: template bind<Param, Graph, Tag> type;
typedef typename type::result_type result_type;
typedef typename type::const_result_type const_result_type;
typedef typename type::type result;
};