Classes | Public Member Functions | Private Member Functions

Digraph Class Reference


Detailed Description

This class describes the concept of the immutable directed digraphs.

Note that actual digraph implementation like ListDigraph or SmartDigraph may have several additional functionality.

See also:
Concepts

#include <lemon/concepts/digraph.h>

List of all members.

Classes

class  Arc
 Class for identifying an arc of the digraph. More...
class  ArcIt
 This iterator goes through each arc. More...
class  ArcMap
class  InArcIt
 This iterator goes trough the incoming arcs of a node. More...
class  Node
 Class for identifying a node of the digraph. More...
class  NodeIt
 This iterator goes through each node. More...
class  NodeMap
class  OutArcIt
 This iterator goes trough the outgoing arcs of a node. More...

Public Member Functions

 Digraph ()
 
Node target (Arc) const
Node source (Arc) const
int id (Node) const
 Returns the ID of the node.
int id (Arc) const
 Returns the ID of the arc.
Node nodeFromId (int) const
 Returns the node with the given ID.
Arc arcFromId (int) const
 Returns the arc with the given ID.
int maxNodeId () const
 Returns an upper bound on the node IDs.
int maxArcId () const
 Returns an upper bound on the arc IDs.
Node baseNode (const InArcIt &) const
 The base node of the iterator.
Node runningNode (const InArcIt &) const
 The running node of the iterator.
Node baseNode (const OutArcIt &) const
 The base node of the iterator.
Node runningNode (const OutArcIt &) const
 The running node of the iterator.
Node oppositeNode (const Node &, const Arc &) const
 The opposite node on the given arc.

Private Member Functions

 Digraph (const Digraph &)
void operator= (const Digraph &)

Constructor & Destructor Documentation

Digraph ( const Digraph ) [inline, private]

Digraphs are not copy constructible. Use DigraphCopy() instead.

Digraph ( ) [inline]

Defalult constructor. Defalult constructor.


Member Function Documentation

void operator= ( const Digraph ) [inline, private]

Assignment of Digraphs to another ones are not allowed. Use DigraphCopy() instead.

Node target ( Arc  ) const [inline]

Gives back the target node of an arc.

Node source ( Arc  ) const [inline]

Gives back the source node of an arc.

Node nodeFromId ( int  ) const [inline]
Precondition:
The argument should be a valid node ID in the graph.
Arc arcFromId ( int  ) const [inline]
Precondition:
The argument should be a valid arc ID in the graph.
Node baseNode ( const InArcIt ) const [inline]

Gives back the base node of the iterator. It is always the target of the pointed arc.

Node runningNode ( const InArcIt ) const [inline]

Gives back the running node of the iterator. It is always the source of the pointed arc.

Node baseNode ( const OutArcIt ) const [inline]

Gives back the base node of the iterator. It is always the source of the pointed arc.

Node runningNode ( const OutArcIt ) const [inline]

Gives back the running node of the iterator. It is always the target of the pointed arc.

Node oppositeNode ( const Node ,
const Arc  
) const [inline]

Gives back the opposite node on the given arc.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines