private static @Nullable SyntheticLibrary syntheticLibrary(@NotNull Project project,
                                                             @NotNull ProjectFileIndex fileIndex,
                                                             @NotNull VirtualFile vFile) {
    VirtualFile sourceRoot = fileIndex.getSourceRootForFile(vFile);
    if (sourceRoot == null) {
      return null;
    }

    for (AdditionalLibraryRootsProvider provider : AdditionalLibraryRootsProvider.EP_NAME.getExtensions()) {
      for (SyntheticLibrary library : provider.getAdditionalProjectLibraries(project)) {
        if (!library.getSourceRoots().contains(sourceRoot)) {
          continue;
        }

        Condition<VirtualFile> excludeFileCondition = library.getUnitedExcludeCondition();
        if (excludeFileCondition == null || !excludeFileCondition.value(vFile)) {
          return library;
        }
      }
    }

    return null;
  }
private static @Nullable SyntheticLibrary syntheticLibrary(@NotNull Project project,
                                                             @NotNull ProjectFileIndex fileIndex,
                                                             @NotNull VirtualFile vFile)