boolean (@NotNull String toolId, @NotNull InspectionProfileWrapper profileWrapper, @NotNull PsiFile psiFile) { InspectionToolWrapper<?, ?> tool = profileWrapper.getInspectionTool(toolId, psiFile); return tool instanceof LocalInspectionToolWrapper local && local.runForWholeFile(); }