@Override
  public PyDocumentationSettings.ServiceState fun(@NotNull Pair<Module, Collection<VirtualFile>> pair) {
    Module module = pair.first;
    if (module.isDisposed()) {
      return null;
    }
    ApplicationManager.getApplication().assertIsNonDispatchThread();

    for (VirtualFile file : pair.second) {
      DocStringFormat docFormat = ReadAction.compute(() -> checkDocString(file, module));    // detect docstring type
      if (docFormat != PyDocumentationSettings.DEFAULT_DOC_STRING_FORMAT) {
        LOG.debug("Docstring format '" + docFormat + "' was detected from content of the file '" + file.getPath() + "'");
        return new PyDocumentationSettings.ServiceState(docFormat);
      }
    }
    return null;
  }
@Override
  public PyDocumentationSettings.ServiceState fun(@NotNull Pair<Module, Collection<VirtualFile>> pair)