FullGraph Class Reference
[Graph Structures]

#include <full_graph.h>

List of all members.


Detailed Description

This is a simple and fast directed full graph implementation. It is completely static, so you can neither add nor delete either edges or nodes. Thus it conforms to the StaticGraph concept
See also:
skeleton::StaticGraph.
Todo:
What about loops?

Don't we need SymEdgeMap?

Author:
Alpar Juttner

Definition at line 51 of file full_graph.h.

Public Member Functions

 FullGraph (int n)
 Creates a full graph with n nodes.
int nodeNum () const
 Number of nodes.
int edgeNum () const
 Number of edges.
int maxNodeId () const
 Maximum node ID.
int maxEdgeId () const
 Maximum edge ID.
Edge findEdge (Node u, Node v, Edge prev=INVALID)
 Finds an edge between two nodes.

Static Public Member Functions

int id (Node v)
 Node ID.
int id (Edge e)
 Edge ID.


Member Function Documentation

int maxNodeId  )  const [inline]
 

Maximum node ID.

See also:
id(Node)
Definition at line 89 of file full_graph.h.

int maxEdgeId  )  const [inline]
 

Maximum edge ID.

See also:
id(Edge)
Definition at line 94 of file full_graph.h.

int id Node  v  )  [inline, static]
 

The ID of a valid Node is a nonnegative integer not greater than maxNodeId(). The range of the ID's is not surely continuous and the greatest node ID can be actually less then maxNodeId().

The ID of the INVALID node is -1.

Returns:
The ID of the node v.
Definition at line 116 of file full_graph.h.

int id Edge  e  )  [inline, static]
 

The ID of a valid Edge is a nonnegative integer not greater than maxEdgeId(). The range of the ID's is not surely continuous and the greatest edge ID can be actually less then maxEdgeId().

The ID of the INVALID edge is -1.

Returns:
The ID of the edge e.
Definition at line 125 of file full_graph.h.

Edge findEdge Node  u,
Node  v,
Edge  prev = INVALID
[inline]
 

Finds an edge from node u to node v.

If prev is INVALID (this is the default value), then It finds the first edge from u to v. Otherwise it looks for the next edge from u to v after prev.

Returns:
The found edge or INVALID if there is no such an edge.
Definition at line 135 of file full_graph.h.

References lemon::INVALID.


The documentation for this class was generated from the following file:
Generated on Thu Sep 30 12:18:37 2004 for LEMON by doxygen 1.3.8