code: private List<PathEdge> remove(final int x) {
          final List<PathEdge> edges = graph[x];
          graph[x] = Collections.emptyList();
          return edges;
      }
docs: Access edges which are incident to <i>x</i> and remove them from the
  graph.
  
  @param x a vertex
  @return vertices incident to x