@Override
  protected Collection<PsiDirectory> getAllDirectories(GlobalSearchScope scope) {
    if (scope.isForceSearchingInLibrarySources()) {
      if (myDirectoriesWithLibSources == null) {
        myDirectoriesWithLibSources = createCachedDirectories(true);
      }
      return ContainerUtil.filter(myDirectoriesWithLibSources.getValue(), d -> scope.contains(d.getVirtualFile()));
    }
    else {
      if (myDirectories == null) {
        myDirectories = createCachedDirectories(false);
      }
      return ContainerUtil.filter(myDirectories.getValue(), d -> scope.contains(d.getVirtualFile()));
    }
  }
@Override
  protected Collection<PsiDirectory> getAllDirectories(GlobalSearchScope scope)