Skip to content
Snippets Groups Projects
Commit 1afc13f3 authored by Rakurai's avatar Rakurai
Browse files

Update Cluster.java

Removed redundant code that added new link set mappings to the instance hashmap.
parent fbfe13c4
No related branches found
No related tags found
No related merge requests found
......@@ -58,16 +58,10 @@ public class Cluster {
}
void addLink(Link l) {
if (links.containsKey(l.getSrc()) == false) {
links.put(l.getSrc(), new HashSet<Link>());
if (l.getSrc() < id) id = l.getSrc();
}
add(l.getSrc());
links.get(l.getSrc()).add(l);
if (links.containsKey(l.getDst()) == false) {
links.put(l.getDst(), new HashSet<Link>());
if (l.getDst() < id) id = l.getDst();
}
add(l.getDst());
links.get(l.getDst()).add(l);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment