Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

Edge Class Reference

#include <Graph.h>

List of all members.


Detailed Description

A graph's edge.

It connects to vertices together and can store any data.

See also:
See collections.txt for an overview of the available collection classes.
Author:
Thomas Jacob

Definition at line 22 of file Graph.h.

Public Member Functions

void * GetData ()
 Returns the data stored in the edge.

VertexGetFromVertex ()
 Returns the vertex where the edge starts.

VertexGetToVertex ()
 Returns the vertex where the edge ends.

void SetData (void *data)
 Sets any data to be stored in the edge.


Private Member Functions

 Edge (class Graph *Graph, Vertex *FromVertex, Vertex *ToVertex)
 Creates a new edge.

virtual ~Edge ()
 Destroys the edge.


Private Attributes

friend ArrayList<Edge>
friend ArrayList<Vertex>
void * Data
 Any application's data to store in the edge.

friend Edge
friend EdgeArray
VertexFromVertex
 The vertex where the edge starts.

GraphGraph
 The graph the edge belongs to.

friend Graph
VertexToVertex
 The vertex where the edge ends.

friend Vertex
friend VertexArray
double Weight
 A weight information for the edge.


Constructor & Destructor Documentation

Edge class Graph Graph,
Vertex FromVertex,
Vertex ToVertex
[private]
 

Creates a new edge.

Parameters:
Graph The graph this edge belongs to.
FromVertex The vertex where this edge starts.
ToVertex The vertex where this edge ends.

virtual ~Edge  )  [private, virtual]
 

Destroys the edge.


Member Function Documentation

void* GetData  )  [inline]
 

Returns the data stored in the edge.

Returns:
The data stored in the edge.

Vertex* GetFromVertex  )  [inline]
 

Returns the vertex where the edge starts.

Returns:
The vertex where the edge starts.

Vertex* GetToVertex  )  [inline]
 

Returns the vertex where the edge ends.

Returns:
The vertex where the edge ends.

void SetData void *  data  )  [inline]
 

Sets any data to be stored in the edge.

Parameters:
data The data to be stored.


Member Data Documentation

friend ArrayList<Edge> [private]
 

Definition at line 30 of file Graph.h.

friend ArrayList<Vertex> [private]
 

Definition at line 27 of file Graph.h.

void* Data [private]
 

Any application's data to store in the edge.

Definition at line 50 of file Graph.h.

friend Edge [private]
 

Definition at line 28 of file Graph.h.

friend EdgeArray [private]
 

Definition at line 29 of file Graph.h.

Vertex* FromVertex [private]
 

The vertex where the edge starts.

Definition at line 55 of file Graph.h.

class Graph* Graph [private]
 

The graph the edge belongs to.

Definition at line 60 of file Graph.h.

friend Graph [private]
 

Definition at line 24 of file Graph.h.

Vertex* ToVertex [private]
 

The vertex where the edge ends.

Definition at line 72 of file Graph.h.

friend Vertex [private]
 

Definition at line 25 of file Graph.h.

friend VertexArray [private]
 

Definition at line 26 of file Graph.h.

double Weight [private]
 

A weight information for the edge.

Definition at line 77 of file Graph.h.


The documentation for this class was generated from the following file:
Generated on Tue Oct 3 00:23:39 2006 for ToolBox by doxygen 1.3.6