connect
Connects two nodes in the graph, by calling addEdge(node1,node2) and addEdge(node2, node1)
Parameters
node1
The first node to connect.
node2
The second node to connect.
Connects two nodes in the graph, by calling addEdge(node1,node2, weight) and addEdge(node2, node1, weight)
Parameters
node1
The first node to connect.
node2
The second node to connect.
weight
The weight of the connection.
Overloaded function that calls connect with weight converted to a double.