Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void createGraph() {
- ComputerNode c1 = new ComputerNode (0, 2); // computer 0 at time stamp 2
- ComputerNode c2 = new ComputerNode(1,2); // computer 1 at timestamp 2
- c1.addNeighbor(c2); // adding an edge
- c2.addNeighbor(c1);
- map.put(0, c1);
- map.put(0, listComputers.add(c2));
- map.put(1, listComputers.add(c2));
- //map.entrySet(0, c1);
- if(listComputers.contains(c1)) {
- } else {
- listComputers.add(c1);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement