My Project
List of all members | Public Member Functions
Graph::EdgeIt Class Reference

Detailed Description

This iterator goes through each edge of the graph. Its usage is quite simple, for example, you can count the number of edges in a graph g of type Graph as follows:

int count=0;
for(Graph::EdgeIt e(g); e!=INVALID; ++e) ++count;
const Invalid INVALID
Invalid iterators.
Definition: base.cc:32

#include <lemon/concepts/graph.h>

Inherits Edge.

Public Member Functions

 EdgeIt ()
 Default constructor. More...
 
 EdgeIt (const EdgeIt &e)
 Copy constructor. More...
 
 EdgeIt (Invalid)
 Invalid constructor & conversion. More...
 
 EdgeIt (const Graph &)
 Sets the iterator to the first edge. More...
 
 EdgeIt (const Graph &, const Edge &)
 Sets the iterator to the given edge. More...
 
EdgeItoperator++ ()
 Next edge. More...
 

Constructor & Destructor Documentation

◆ EdgeIt() [1/5]

EdgeIt ( )
inline

Default constructor.

Warning
It sets the iterator to an undefined value.

◆ EdgeIt() [2/5]

EdgeIt ( const EdgeIt e)
inline

Copy constructor.

◆ EdgeIt() [3/5]

EdgeIt ( Invalid  )
inline

Initializes the iterator to be invalid.

See also
Invalid for more details.

◆ EdgeIt() [4/5]

EdgeIt ( const Graph )
inlineexplicit

Sets the iterator to the first edge of the given graph.

◆ EdgeIt() [5/5]

EdgeIt ( const Graph ,
const Edge  
)
inline

Sets the iterator to the given edge of the given graph.

Member Function Documentation

◆ operator++()

EdgeIt& operator++ ( )
inline

Assign the iterator to the next edge.