File indexing completed on 2025-01-18 09:37:17
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010 #ifndef BOOST_DISTRIBUTED_FILTERED_GRAPH_HPP
0011 #define BOOST_DISTRIBUTED_FILTERED_GRAPH_HPP
0012
0013 #ifndef BOOST_GRAPH_USE_MPI
0014 #error "Parallel BGL files should not be included unless <boost/graph/use_mpi.hpp> has been included"
0015 #endif
0016
0017 #include <boost/graph/parallel/process_group.hpp>
0018 #include <boost/graph/filtered_graph.hpp>
0019
0020 namespace boost {
0021 namespace graph {
0022 namespace parallel {
0023
0024 template<typename Graph, typename EdgePredicate, typename VertexPredicate>
0025 struct process_group_type<filtered_graph<Graph, EdgePredicate, VertexPredicate> >
0026 : process_group_type<Graph> { };
0027
0028 template<typename Graph, typename EdgePredicate, typename VertexPredicate>
0029 struct process_group_type<const filtered_graph<Graph, EdgePredicate, VertexPredicate> >
0030 : process_group_type<Graph> { };
0031 }
0032
0033 }
0034
0035
0036 template<typename Graph, typename EdgePredicate, typename VertexPredicate>
0037 inline typename graph::parallel::process_group_type<Graph>::type
0038 process_group(filtered_graph<Graph, EdgePredicate, VertexPredicate> const& g) {
0039 return process_group(g.m_g);
0040 }
0041
0042
0043 template <typename Graph, typename EdgePredicate, typename VertexPredicate>
0044 typename graph_traits<Graph>::vertex_descriptor
0045 vertex(typename graph_traits<Graph>::vertices_size_type i,
0046 filtered_graph<Graph, EdgePredicate, VertexPredicate> const& g)
0047 { return vertex(i, g.m_g); }
0048
0049 }
0050
0051 #endif