class Spt

Shortest Path Tree More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods


Detailed Description

Shortest Path Tree

Compute shortest path tree's

typedef map<A, typename Node<A>::NodeRef> Nodes

Nodes

 ~Spt ()

~Spt

bool  set_origin (A node)

set_origin

Set the origin node.

Returns: false if the node doesn't exist, otherwise true.

bool  add_node (A node)

add_node

Add node

Returns: false if the node already exists, otherwise true.

bool  remove_node (A node)

remove_node

Remove node

Returns: false if the node doesn't exist or has already been removed, otherwise true.

bool  exists_node (A node)

exists_node

Does this node exist?

Returns: true if the node exists.

bool  add_edge (A src, int weight, A dst)

add_edge

Add a new edge.

Parameters:

srcsource node must exist.
weightedge weight.
dstdestination node, created if necessary.

Returns: true on success.

bool  update_edge_weight (A src, int weight, A dst)

update_edge_weight

Update existing edge weight.

Parameters:

srcsource node must exist.
weightnew edge weight.
dstdestination node must exist

Returns: true on success.

bool  get_edge_weight (A src, int& weight, A dst)

get_edge_weight

Get edge weight.

Parameters:

srcsource node must exist.
weightof this edge returned.
dstdestination node must exist

Returns: true on success.

bool  remove_edge (A src, A dst)

remove_edge

Remove an edge

Parameters:

srcsource node must exist.
dstdestination node must exist

Returns: true on success.

bool  compute (list<RouteCmd<A> >& routes)

compute

Compute the tree.

Parameters:

routesa list of route adds, deletes and replaces that must be performed.

Returns: true on success

string  str ()

str

[const]

Convert this graph to presentation format.

Returns: C++ string with the human-readable ASCII representation of the graph.


Generated by: pavlin on possum.icir.org on Wed Apr 13 21:52:51 2005, using kdoc $.