protected boolean hasProblems(@NotNull Project project, @NotNull Document document) {
    PsiFile file = PsiDocumentManager.getInstance(project).getPsiFile(document);

    return file != null && !isEmpty(checkFile(file, document, InspectionManager.getInstance(project), false));
  }
protected boolean hasProblems(@NotNull Project project, @NotNull Document document)