private static List<PathElement[]> createPaths(@NotNull JTree tree, @NotNull List<? extends TreePath> paths) {
    List<PathElement[]> list = new ArrayList<>();
    for (TreePath o : paths) {
      if (o.getPathCount() > 1 || tree.isRootVisible()) {
        list.add(createPath(tree.getModel(), o));
      }
    }
    return list;
  }
private static List<PathElement[]> createPaths(@NotNull JTree tree, @NotNull List<? extends TreePath> paths)