private int getTodoCountImpl(@NotNull VirtualFile file, IndexPattern @NotNull ... indexPatterns) {
    if (file instanceof VirtualFileWindow) return -1;

    Map<TodoIndexEntry, Integer> data = getTodoMap(myProject, file);
    if (data == null || data.isEmpty()) return 0;

    int result = 0;
    for (IndexPattern pattern : indexPatterns) {
      result += data.getOrDefault(new TodoIndexEntry(pattern.getPatternString(), pattern.isCaseSensitive()), 0);
    }
    return result;
  }
private int getTodoCountImpl(@NotNull VirtualFile file, IndexPattern @NotNull ... indexPatterns)