void (@NotNull ProjectDumbIndexingHistoryImpl projectDumbIndexingHistory, @NotNull ProgressIndicator progressIndicator) { int numberOfIndexingThreads = UnindexedFilesUpdater.getNumberOfIndexingThreads(); IndexingRequestToken indexingRequest = myProject.getService(ProjectIndexingDependenciesService.class).getLatestIndexingRequestToken(); IndexUpdateRunner indexUpdateRunner = new IndexUpdateRunner(myIndex, indexingRequest, numberOfIndexingThreads); List<IndexUpdateRunner.FileSet> fileSets = getExplicitlyRequestedFilesSets(); if (!fileSets.isEmpty()) { doIndexFiles(projectDumbIndexingHistory, progressIndicator, indexUpdateRunner, fileSets); } // Order is important: getRefreshedFiles may return some subset of getExplicitlyRequestedFilesSets files (e.g., new files) // We first index explicitly requested files, this will also mark indexed files as "up-to-date", then we index remaining dirty files fileSets = getRefreshedFiles(projectDumbIndexingHistory); if (!fileSets.isEmpty()) { doIndexFiles(projectDumbIndexingHistory, progressIndicator, indexUpdateRunner, fileSets); } }