D | DirectedGraph.java | 67 public void addEdge(V from, V to) { in addEdge() argument 69 this.addVertice(to); in addEdge() 70 neighbors.get(from).add(to); in addEdge() 78 public void removeEdge(V from, V to) { in removeEdge() argument 79 if (!(this.contains(from) && this.contains(to))) { in removeEdge() 82 neighbors.get(from).remove(to); in removeEdge() 96 for (V to: neighbors.get(from)) { in inDegree() 97 result.put(to, result.get(to) + 1); in inDegree()
|