Skip to content

Commit

Permalink
add comment
Browse files Browse the repository at this point in the history
Signed-off-by: RALAMBOTIANA MIORA <miora.ralambotiana@rte-france.com>
  • Loading branch information
miovd committed Sep 24, 2019
1 parent 1422176 commit 4401a85
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,8 @@ BusExt getConnectableBus(int node) {
BusExt[] connectableBus2 = new BusExt[1];
graph.traverse(node, (v1, e, v2) -> {
if (connectableBus2[0] != null) {
// traverse does not stop the algorithm when TERMINATE, it only stops searching in a given direction
// this condition insures that while checking all the edges (in every direction) of a node, if a bus is found, it will not be lost
return TraverseResult.TERMINATE;
}
connectableBus2[0] = getBus(v2);
Expand Down

0 comments on commit 4401a85

Please sign in to comment.