lemon/maps.h
changeset 2241 37e0966e43b6
parent 2091 c8ccc1f8fd51
child 2248 1ac928089d68
equal deleted inserted replaced
23:d6b9d90afaa3 24:737b2c26fcc1
  1092   ///
  1092   ///
  1093   ///\code
  1093   ///\code
  1094   /// vector<UEdge> span_tree_uedges;
  1094   /// vector<UEdge> span_tree_uedges;
  1095   /// BackInserterBoolMap<vector<UEdge> > inserter_map(span_tree_uedges);
  1095   /// BackInserterBoolMap<vector<UEdge> > inserter_map(span_tree_uedges);
  1096   /// prim(ugraph, cost, inserter_map);
  1096   /// prim(ugraph, cost, inserter_map);
  1097   ///
       
  1098   /// for (int i = 0; i < (int)span_tree_uedges.size(); ++i) {
       
  1099   /// std::cout << ugraph.id(ugraph.source(span_tree_uedges[i])) << ' '
       
  1100   ///           << ugraph.id(ugraph.target(span_tree_uedges[i])) << ' '
       
  1101   ///           << cost[span_tree_uedges[i]] << endl;
       
  1102   ///\endcode
  1097   ///\endcode
  1103   template <typename Container,
  1098   template <typename Container,
  1104             typename Functor =
  1099             typename Functor =
  1105             _maps_bits::Identity<typename Container::value_type> >
  1100             _maps_bits::Identity<typename Container::value_type> >
  1106   class BackInserterBoolMap {
  1101   class BackInserterBoolMap {
  1313   ///   if (!dfs.reached(it)) {
  1308   ///   if (!dfs.reached(it)) {
  1314   ///     dfs.addSource(it);
  1309   ///     dfs.addSource(it);
  1315   ///     dfs.start();
  1310   ///     dfs.start();
  1316   ///   }
  1311   ///   }
  1317   /// }
  1312   /// }
  1318   /// for (NodeIt it(graph); it != INVALID; ++it) {
       
  1319   ///   cout << graph.id(it) << ' ' << order[it] << endl;
       
  1320   /// }
       
  1321   ///\endcode
  1313   ///\endcode
  1322   template <typename Map>
  1314   template <typename Map>
  1323   class SettingOrderBoolMap {
  1315   class SettingOrderBoolMap {
  1324   public:
  1316   public:
  1325     typedef typename Map::Key Key;
  1317     typedef typename Map::Key Key;