boolean (String word, final VirtualFile file, boolean inDumbMode) { assertEquals(inDumbMode, DumbService.isDumb(getProject())); assertTrue(FileBasedIndex.isIndexAccessDuringDumbModeEnabled()); final IdIndexEntry wordHash = new IdIndexEntry(word, true); final GlobalSearchScope scope = GlobalSearchScope.allScope(getProject()); final FileBasedIndex fileBasedIndex = FileBasedIndex.getInstance(); final AtomicBoolean found = new AtomicBoolean(false); Runnable runnable = () -> found.set(fileBasedIndex.getContainingFiles(IdIndex.NAME, wordHash, scope).contains(file)); if (inDumbMode) { fileBasedIndex.ignoreDumbMode(DumbModeAccessType.RAW_INDEX_DATA_ACCEPTABLE, runnable); } else { runnable.run(); } return found.get(); }