tlp::ConnectedTest Class Reference
[Graph_test]
#include <ConnectedTest.h>
Inherits tlp::GraphObserver.
Inheritance diagram for tlp::ConnectedTest:
[legend]Collaboration diagram for tlp::ConnectedTest:
[legend]List of all members.
Detailed Description
class for testing if the graph is connected
Static Public Member Functions
Member Function Documentation
static bool tlp::ConnectedTest::isConnected |
( |
Graph * |
graph |
) |
[static] |
|
|
Returns true if the graph is connected (ie. it exists an undirected path between each pair of nodes) else false. |
static void tlp::ConnectedTest::makeConnected |
( |
Graph * |
graph, |
|
|
std::vector< edge > & |
addedEdges |
|
) |
[static] |
|
|
If the graph is not connected, adds edges in order to make the graph connected. The new edges are added in addedEdges. |
static unsigned int tlp::ConnectedTest::numberOfConnectedComponnents |
( |
Graph * |
graph |
) |
[static] |
|
|
Returns the number of connected components in the graph; |
|