private void doClassify(@NotNull WorkspaceFileIndexEx workspaceFileIndex, @NotNull VirtualFile file) {
    WorkspaceFileInternalInfo fileInfo =
      workspaceFileIndex.getFileInfo(file, true, true, true, true, true);
    if (fileInfo == WorkspaceFileInternalInfo.NonWorkspace.IGNORED || fileInfo == WorkspaceFileInternalInfo.NonWorkspace.EXCLUDED) {
      //excluded files should be ignored by indexableSetContributors
      return;
    }
    WorkspaceFileSet fileSet = fileInfo.findFileSet((data -> true));
    if (fileSet == null) {
      filesFromIndexableSetContributors.add(file);
      return;
    }

    EntityPointer<?> entityPointer = WorkspaceFileSetRecognizer.INSTANCE.getEntityPointer(fileSet);
    if (entityPointer != null) {
      myEntityPointers.add(entityPointer);
      return;
    }

    Sdk sdk = WorkspaceFileSetRecognizer.INSTANCE.getSdk(fileSet);
    if (sdk != null) {
      sdks.add(sdk);
      return;
    }

    if (WorkspaceFileSetRecognizer.INSTANCE.isFromAdditionalLibraryRootsProvider(fileSet)) {
      filesFromAdditionalLibraryRootsProviders.add(file);
      return;
    }

    LibraryId libraryId = WorkspaceFileSetRecognizer.INSTANCE.getLibraryId(fileSet, entityStorage);
    if (libraryId != null) {
      libraryIds.add(libraryId);
      return;
    }

    LOG.error("File " + file + "is unclassifiable with fileSet " + fileSet);
  }
private void doClassify(@NotNull WorkspaceFileIndexEx workspaceFileIndex, @NotNull VirtualFile file)