String (@NotNull EdgesInRowGenerator edgesInRowGenerator, int nodesCount) { StringBuilder s = new StringBuilder(); for (int i = 0; i < nodesCount; i++) { if (i > 0) s.append("\n"); Set<GraphEdge> edgesInRow = edgesInRowGenerator.getEdgesInRow(i); s.append(edgesToStr(edgesInRow)); } return s.toString(); }