@Override
  public boolean iterateContent(@NotNull ContentIterator processor, @Nullable VirtualFileFilter filter) {
    Pair<List<VirtualFile>, List<VirtualFile>> rootsPair = ReadAction.compute(() -> {
      Set<VirtualFile> allRecursiveRoots = new LinkedHashSet<>();
      List<VirtualFile> allNonRecursiveRoots = new ArrayList<>();
      myWorkspaceFileIndex.visitFileSets(fileSet -> {
        ProgressManager.checkCanceled();
        if (fileSet.getKind().isContent()) {
          VirtualFile root = fileSet.getRoot();
          if (fileSet instanceof WorkspaceFileSetImpl && !((WorkspaceFileSetImpl)fileSet).getRecursive()) {
            allNonRecursiveRoots.add(root);
          }
          else {
            allRecursiveRoots.add(root);
          }
        }
      });
      List<VirtualFile> recursiveRoots =
        ContainerUtil.filter(allRecursiveRoots, root -> root.getParent() == null ||
                                                        myWorkspaceFileIndex.getContentFileSetRoot(root.getParent(), false) == null);
      return new Pair<>(recursiveRoots, allNonRecursiveRoots);
    });
    return iterateProvidedRootsOfContent(processor, filter, rootsPair.getFirst(), rootsPair.getSecond());
  }
@Override
  public boolean iterateContent(@NotNull ContentIterator processor, @Nullable VirtualFileFilter filter)