lemon/dfs.h
changeset 1871 3905d347112c
parent 1799 990ef198f64d
child 1874 396831fa7012
equal deleted inserted replaced
20:ba5c8f1e831f 21:afd27d640ea2
   557     ///Executes the algorithm until a condition is met.
   557     ///Executes the algorithm until a condition is met.
   558     ///
   558     ///
   559     ///\pre init() must be called and at least one node should be added
   559     ///\pre init() must be called and at least one node should be added
   560     ///with addSource() before using this function.
   560     ///with addSource() before using this function.
   561     ///
   561     ///
   562     ///\param nm must be a bool (or convertible) edge map. The algorithm
   562     ///\param em must be a bool (or convertible) edge map. The algorithm
   563     ///will stop when it reaches an edge \c e with <tt>nm[e]==true</tt>.
   563     ///will stop when it reaches an edge \c e with \code em[e]==true \endcode.
   564     ///
   564     ///
   565     ///\warning Contrary to \ref Dfs and \ref Dijkstra, \c em is an edge map,
   565     ///\warning Contrary to \ref Dfs and \ref Dijkstra, \c em is an edge map,
   566     ///not a node map.
   566     ///not a node map.
   567     template<class EM>
   567     template<class EM>
   568     void start(const EM &em)
   568     void start(const EM &em)
  1142     typedef typename Graph::template NodeMap<bool> ReachedMap;
  1142     typedef typename Graph::template NodeMap<bool> ReachedMap;
  1143 
  1143 
  1144     /// \brief Instantiates a ReachedMap.
  1144     /// \brief Instantiates a ReachedMap.
  1145     ///
  1145     ///
  1146     /// This function instantiates a \ref ReachedMap. 
  1146     /// This function instantiates a \ref ReachedMap. 
  1147     /// \param G is the graph, to which
  1147     /// \param graph is the graph, to which
  1148     /// we would like to define the \ref ReachedMap.
  1148     /// we would like to define the \ref ReachedMap.
  1149     static ReachedMap *createReachedMap(const Graph &graph) {
  1149     static ReachedMap *createReachedMap(const Graph &graph) {
  1150       return new ReachedMap(graph);
  1150       return new ReachedMap(graph);
  1151     }
  1151     }
  1152 
  1152 
  1425     /// Executes the algorithm until a condition is met.
  1425     /// Executes the algorithm until a condition is met.
  1426     ///
  1426     ///
  1427     /// \pre init() must be called and at least one node should be added
  1427     /// \pre init() must be called and at least one node should be added
  1428     /// with addSource() before using this function.
  1428     /// with addSource() before using this function.
  1429     ///
  1429     ///
  1430     /// \param nm must be a bool (or convertible) edge map. The algorithm
  1430     /// \param em must be a bool (or convertible) edge map. The algorithm
  1431     /// will stop when it reaches an edge \c e with <tt>nm[e]==true</tt>.
  1431     /// will stop when it reaches an edge \c e with \code nm[e]==true \endcode.
  1432     ///
  1432     ///
  1433     /// \warning Contrary to \ref Dfs and \ref Dijkstra, \c em is an edge map,
  1433     /// \warning Contrary to \ref Dfs and \ref Dijkstra, \c em is an edge map,
  1434     /// not a node map.
  1434     /// not a node map.
  1435     template <typename EM>
  1435     template <typename EM>
  1436     void start(const EM &em) {
  1436     void start(const EM &em) {