BridgesUNCC / bridges-java

JAVA Client library for Bridges
http://bridgesuncc.github.io
GNU General Public License v2.0
4 stars 12 forks source link

Graph Error with no Nodes/Links #110

Closed squeetus closed 7 years ago

squeetus commented 7 years ago

When calling Bridges.visualize() on a graph data structure which contains either zero nodes or zero links, a String index out of range exception is thrown.

This occurs in GraphAdjList.java, and likely also in the matrix version.

krs-world commented 7 years ago

This should be fixed now - updates pushed to git. However the whole issue of exceptions in teh code needs a fresh look to bullet proof. For instance, passing a null pointer to the setDataStructure() (I added an exception in the setDataStructure() method, but this continues into visualize() and dies someplace there..