private static void addFileNamePattern(@NotNull List<? super EventPair<?>> data, @NotNull VirtualFile file) {
    FileType fileType = file.getFileType();
    FileTypeManager fileTypeManager = FileTypeManager.getInstance();
    if (!(fileTypeManager instanceof FileTypeManagerImpl)) {
      return;
    }
    List<FileNameMatcher> fileNameMatchers = ((FileTypeManagerImpl)fileTypeManager).getStandardMatchers(fileType);
    Optional<FileNameMatcher> fileNameMatcher = fileNameMatchers.stream().filter(x -> x.acceptsCharSequence(file.getName())).findFirst();
    fileNameMatcher.ifPresent(matcher -> data.add(FILE_NAME_PATTERN_FIELD.with(matcher.getPresentableString())));
  }
private static void addFileNamePattern(@NotNull List<? super EventPair<?>> data, @NotNull VirtualFile file)