private static <T> void processMap(Map<EdgeType, List<T>> map) {
    map.remove(EdgeType.EXCEPTION);

    List<T> lst = map.get(EdgeType.DIRECT_ALL);
    if (lst != null) {
      map.put(EdgeType.ALL, new ArrayList<>(lst));
    }
    else {
      map.remove(EdgeType.ALL);
    }
  }
private static <T> void processMap(Map<EdgeType, List<T>> map)