EulerIt Class Template Reference
[Topology related algorithms]

#include <lemon/euler.h>

List of all members.


Detailed Description

template<class Graph>
class lemon::EulerIt< Graph >

This iterator converts to the Edge type of the graph and using operator ++ it provides an Euler tour of the graph (if there exists).

For example if the given graph if Euler (i.e it has only one nontrivial component and the in-degree is equal to the out-degree for all nodes), the following code will print the edge IDs according to an Euler tour of g.

       for(EulerIt<ListGraph> e(g),e!=INVALID;++e) {
         std::cout << g.id(e) << std::eol;
       }
If g is not Euler then the resulted tour will not be full or closed.
Todo:
Test required


Public Member Functions

 EulerIt (const Graph &_g, typename Graph::Node start=INVALID)
 Constructor.
 operator Edge ()
 Edge Conversion.
EulerItoperator++ ()
 Next edge of the tour.
Edge operator++ (int)
 Postfix incrementation.


Constructor & Destructor Documentation

EulerIt const Graph _g,
typename Graph::Node  start = INVALID
[inline]
 

Parameters:
_g A directed graph.
start The starting point of the tour. If it is not given the tour will start from the first node.


Member Function Documentation

Edge operator++ int   )  [inline]
 

Warning:
This incrementation returns an Edge, not an EulerIt, as one may expect.


The documentation for this class was generated from the following file:
Generated on Fri Feb 3 18:41:22 2006 for LEMON by  doxygen 1.4.6