Search in sources :

Example 16 with LocalInspectionToolWrapper

use of com.intellij.codeInspection.ex.LocalInspectionToolWrapper in project intellij-community by JetBrains.

the class InspectionValidatorWrapper method runInspectionOnFile.

private static List<ProblemDescriptor> runInspectionOnFile(@NotNull PsiFile file, @NotNull LocalInspectionTool inspectionTool) {
    InspectionManager inspectionManager = InspectionManager.getInstance(file.getProject());
    GlobalInspectionContext context = inspectionManager.createNewGlobalContext(false);
    return InspectionEngine.runInspectionOnFile(file, new LocalInspectionToolWrapper(inspectionTool), context);
}
Also used : LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper)

Example 17 with LocalInspectionToolWrapper

use of com.intellij.codeInspection.ex.LocalInspectionToolWrapper in project intellij-community by JetBrains.

the class ShowIntentionsPass method collectIntentionsFromDoNotShowLeveledInspections.

/**
   * Can be invoked in EDT, each inspection should be fast
   */
private static void collectIntentionsFromDoNotShowLeveledInspections(@NotNull final Project project, @NotNull final PsiFile hostFile, PsiElement psiElement, final int offset, @NotNull final IntentionsInfo intentions) {
    if (psiElement != null) {
        if (!psiElement.isPhysical()) {
            VirtualFile virtualFile = hostFile.getVirtualFile();
            String text = hostFile.getText();
            LOG.error("not physical: '" + psiElement.getText() + "' @" + offset + psiElement.getTextRange() + " elem:" + psiElement + " (" + psiElement.getClass().getName() + ")" + " in:" + psiElement.getContainingFile() + " host:" + hostFile + "(" + hostFile.getClass().getName() + ")", new Attachment(virtualFile != null ? virtualFile.getPresentableUrl() : "null", text != null ? text : "null"));
        }
        if (DumbService.isDumb(project)) {
            return;
        }
        final List<LocalInspectionToolWrapper> intentionTools = new ArrayList<>();
        final InspectionProfile profile = InspectionProjectProfileManager.getInstance(project).getInspectionProfile();
        final InspectionToolWrapper[] tools = profile.getInspectionTools(hostFile);
        for (InspectionToolWrapper toolWrapper : tools) {
            if (toolWrapper instanceof LocalInspectionToolWrapper && !((LocalInspectionToolWrapper) toolWrapper).isUnfair()) {
                final HighlightDisplayKey key = HighlightDisplayKey.find(toolWrapper.getShortName());
                if (profile.isToolEnabled(key, hostFile) && HighlightDisplayLevel.DO_NOT_SHOW.equals(profile.getErrorLevel(key, hostFile))) {
                    intentionTools.add((LocalInspectionToolWrapper) toolWrapper);
                }
            }
        }
        if (!intentionTools.isEmpty()) {
            final List<PsiElement> elements = new ArrayList<>();
            PsiElement el = psiElement;
            while (el != null) {
                elements.add(el);
                if (el instanceof PsiFile)
                    break;
                el = el.getParent();
            }
            final Set<String> dialectIds = InspectionEngine.calcElementDialectIds(elements);
            final LocalInspectionToolSession session = new LocalInspectionToolSession(hostFile, 0, hostFile.getTextLength());
            final Processor<LocalInspectionToolWrapper> processor = toolWrapper -> {
                final LocalInspectionTool localInspectionTool = toolWrapper.getTool();
                final HighlightDisplayKey key = HighlightDisplayKey.find(toolWrapper.getShortName());
                final String displayName = toolWrapper.getDisplayName();
                final ProblemsHolder holder = new ProblemsHolder(InspectionManager.getInstance(project), hostFile, true) {

                    @Override
                    public void registerProblem(@NotNull ProblemDescriptor problemDescriptor) {
                        super.registerProblem(problemDescriptor);
                        if (problemDescriptor instanceof ProblemDescriptorBase) {
                            final TextRange range = ((ProblemDescriptorBase) problemDescriptor).getTextRange();
                            if (range != null && range.contains(offset)) {
                                final QuickFix[] fixes = problemDescriptor.getFixes();
                                if (fixes != null) {
                                    for (int k = 0; k < fixes.length; k++) {
                                        final IntentionAction intentionAction = QuickFixWrapper.wrap(problemDescriptor, k);
                                        final HighlightInfo.IntentionActionDescriptor actionDescriptor = new HighlightInfo.IntentionActionDescriptor(intentionAction, null, displayName, null, key, null, HighlightSeverity.INFORMATION);
                                        intentions.intentionsToShow.add(actionDescriptor);
                                    }
                                }
                            }
                        }
                    }
                };
                InspectionEngine.createVisitorAndAcceptElements(localInspectionTool, holder, true, session, elements, dialectIds, InspectionEngine.getDialectIdsSpecifiedForTool(toolWrapper));
                localInspectionTool.inspectionFinished(session, holder);
                return true;
            };
            JobLauncher.getInstance().invokeConcurrentlyUnderProgress(intentionTools, new DaemonProgressIndicator(), false, processor);
        }
    }
}
Also used : VirtualFile(com.intellij.openapi.vfs.VirtualFile) VirtualFile(com.intellij.openapi.vfs.VirtualFile) HighlightSeverity(com.intellij.lang.annotation.HighlightSeverity) Document(com.intellij.openapi.editor.Document) MarkupModelEx(com.intellij.openapi.editor.ex.MarkupModelEx) DocumentMarkupModel(com.intellij.openapi.editor.impl.DocumentMarkupModel) QuickFixWrapper(com.intellij.codeInspection.ex.QuickFixWrapper) RangeHighlighterEx(com.intellij.openapi.editor.ex.RangeHighlighterEx) EditorEx(com.intellij.openapi.editor.ex.EditorEx) HighlightingLevelManager(com.intellij.codeInsight.daemon.impl.analysis.HighlightingLevelManager) Logger(com.intellij.openapi.diagnostic.Logger) CommonProcessors(com.intellij.util.CommonProcessors) RangeMarker(com.intellij.openapi.editor.RangeMarker) DumbService(com.intellij.openapi.project.DumbService) HighlightDisplayKey(com.intellij.codeInsight.daemon.HighlightDisplayKey) IntentionHintComponent(com.intellij.codeInsight.intention.impl.IntentionHintComponent) Processors(com.intellij.util.Processors) Set(java.util.Set) TextRange(com.intellij.openapi.util.TextRange) LogicalPosition(com.intellij.openapi.editor.LogicalPosition) CleanupAllIntention(com.intellij.codeInspection.actions.CleanupAllIntention) Nullable(org.jetbrains.annotations.Nullable) ProgressIndicator(com.intellij.openapi.progress.ProgressIndicator) List(java.util.List) TextEditorHighlightingPass(com.intellij.codeHighlighting.TextEditorHighlightingPass) Processor(com.intellij.util.Processor) ApplicationManager(com.intellij.openapi.application.ApplicationManager) IntentionManagerSettings(com.intellij.codeInsight.intention.impl.config.IntentionManagerSettings) IntentionAction(com.intellij.codeInsight.intention.IntentionAction) NotNull(org.jetbrains.annotations.NotNull) InspectionProjectProfileManager(com.intellij.profile.codeInspection.InspectionProjectProfileManager) TemplateManagerImpl(com.intellij.codeInsight.template.impl.TemplateManagerImpl) JobLauncher(com.intellij.concurrency.JobLauncher) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) NonNls(org.jetbrains.annotations.NonNls) DaemonCodeAnalyzer(com.intellij.codeInsight.daemon.DaemonCodeAnalyzer) ContainerUtil(com.intellij.util.containers.ContainerUtil) ArrayList(java.util.ArrayList) PsiElement(com.intellij.psi.PsiElement) PsiWhiteSpace(com.intellij.psi.PsiWhiteSpace) IntentionManager(com.intellij.codeInsight.intention.IntentionManager) Project(com.intellij.openapi.project.Project) PsiFile(com.intellij.psi.PsiFile) Segment(com.intellij.openapi.util.Segment) InjectedLanguageUtil(com.intellij.psi.impl.source.tree.injected.InjectedLanguageUtil) PsiDocumentManager(com.intellij.psi.PsiDocumentManager) Iterator(java.util.Iterator) FileDocumentManager(com.intellij.openapi.fileEditor.FileDocumentManager) com.intellij.codeInspection(com.intellij.codeInspection) HighlightDisplayLevel(com.intellij.codeHighlighting.HighlightDisplayLevel) Editor(com.intellij.openapi.editor.Editor) java.awt(java.awt) ShowIntentionActionsHandler(com.intellij.codeInsight.intention.impl.ShowIntentionActionsHandler) InspectionToolWrapper(com.intellij.codeInspection.ex.InspectionToolWrapper) Pair(com.intellij.openapi.util.Pair) Attachment(com.intellij.openapi.diagnostic.Attachment) HintManager(com.intellij.codeInsight.hint.HintManager) TemplateState(com.intellij.codeInsight.template.impl.TemplateState) HighlightDisplayKey(com.intellij.codeInsight.daemon.HighlightDisplayKey) ArrayList(java.util.ArrayList) Attachment(com.intellij.openapi.diagnostic.Attachment) PsiFile(com.intellij.psi.PsiFile) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) PsiElement(com.intellij.psi.PsiElement) TextRange(com.intellij.openapi.util.TextRange) IntentionAction(com.intellij.codeInsight.intention.IntentionAction) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) InspectionToolWrapper(com.intellij.codeInspection.ex.InspectionToolWrapper)

Example 18 with LocalInspectionToolWrapper

use of com.intellij.codeInspection.ex.LocalInspectionToolWrapper in project intellij-community by JetBrains.

the class WholeFileLocalInspectionsPassFactory method createHighlightingPass.

@Override
@Nullable
public TextEditorHighlightingPass createHighlightingPass(@NotNull final PsiFile file, @NotNull final Editor editor) {
    final Long appliedModificationCount = myPsiModificationCount.get(file);
    if (appliedModificationCount != null && appliedModificationCount == PsiManager.getInstance(myProject).getModificationTracker().getModificationCount()) {
        //optimization
        return null;
    }
    if (!ProblemHighlightFilter.shouldHighlightFile(file)) {
        return null;
    }
    if (myFileToolsCache.containsKey(file) && !myFileToolsCache.get(file)) {
        return null;
    }
    ProperTextRange visibleRange = VisibleHighlightingPassFactory.calculateVisibleRange(editor);
    return new LocalInspectionsPass(file, editor.getDocument(), 0, file.getTextLength(), visibleRange, true, new DefaultHighlightInfoProcessor()) {

        @NotNull
        @Override
        List<LocalInspectionToolWrapper> getInspectionTools(@NotNull InspectionProfileWrapper profile) {
            List<LocalInspectionToolWrapper> tools = super.getInspectionTools(profile);
            List<LocalInspectionToolWrapper> result = tools.stream().filter(LocalInspectionToolWrapper::runForWholeFile).collect(Collectors.toList());
            myFileToolsCache.put(file, !result.isEmpty());
            return result;
        }

        @Override
        protected String getPresentableName() {
            return DaemonBundle.message("pass.whole.inspections");
        }

        @Override
        void inspectInjectedPsi(@NotNull List<PsiElement> elements, boolean onTheFly, @NotNull ProgressIndicator indicator, @NotNull InspectionManager iManager, boolean inVisibleRange, @NotNull List<LocalInspectionToolWrapper> wrappers) {
        // already inspected in LIP
        }

        @Override
        protected void applyInformationWithProgress() {
            super.applyInformationWithProgress();
            myPsiModificationCount.put(file, PsiManager.getInstance(myProject).getModificationTracker().getModificationCount());
        }
    };
}
Also used : InspectionProfileWrapper(com.intellij.codeInspection.ex.InspectionProfileWrapper) InspectionManager(com.intellij.codeInspection.InspectionManager) ProperTextRange(com.intellij.openapi.util.ProperTextRange) ProgressIndicator(com.intellij.openapi.progress.ProgressIndicator) List(java.util.List) NotNull(org.jetbrains.annotations.NotNull) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) Nullable(org.jetbrains.annotations.Nullable)

Example 19 with LocalInspectionToolWrapper

use of com.intellij.codeInspection.ex.LocalInspectionToolWrapper in project intellij-community by JetBrains.

the class JavaAPIUsagesInspectionTest method doTest.

private void doTest() {
    final Java15APIUsageInspection usageInspection = new Java15APIUsageInspection();
    doTest("usage1.5/" + getTestName(true), new LocalInspectionToolWrapper(usageInspection), "java 1.5");
}
Also used : Java15APIUsageInspection(com.intellij.codeInspection.java15api.Java15APIUsageInspection) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper)

Example 20 with LocalInspectionToolWrapper

use of com.intellij.codeInspection.ex.LocalInspectionToolWrapper in project intellij-community by JetBrains.

the class DaemonRespondToChangesTest method configureLocalInspectionTools.

@Override
protected LocalInspectionTool[] configureLocalInspectionTools() {
    if (isStressTest() && !getTestName(false).equals("TypingCurliesClearsEndOfFileErrorsInPhp_ItIsPerformanceTestBecauseItRunsTooLong")) {
        // all possible inspections
        List<InspectionToolWrapper> all = InspectionToolRegistrar.getInstance().createTools();
        List<LocalInspectionTool> locals = new ArrayList<>();
        all.stream().filter(tool -> tool instanceof LocalInspectionToolWrapper).forEach(tool -> {
            LocalInspectionTool e = ((LocalInspectionToolWrapper) tool).getTool();
            locals.add(e);
        });
        return locals.toArray(new LocalInspectionTool[locals.size()]);
    }
    return new LocalInspectionTool[] { new FieldCanBeLocalInspection(), new RequiredAttributesInspectionBase(), new CheckDtdReferencesInspection(), new AccessStaticViaInstance() };
}
Also used : TypedAction(com.intellij.openapi.editor.actionSystem.TypedAction) UIUtil(com.intellij.util.ui.UIUtil) com.intellij.testFramework(com.intellij.testFramework) VirtualFile(com.intellij.openapi.vfs.VirtualFile) THashSet(gnu.trove.THashSet) DocumentMarkupModel(com.intellij.openapi.editor.impl.DocumentMarkupModel) ApplicationEx(com.intellij.openapi.application.ex.ApplicationEx) AccessToken(com.intellij.openapi.application.AccessToken) CompletionContributor(com.intellij.codeInsight.completion.CompletionContributor) com.intellij.lang(com.intellij.lang) PerformanceWatcher(com.intellij.diagnostic.PerformanceWatcher) EditorImpl(com.intellij.openapi.editor.impl.EditorImpl) CodeFoldingManager(com.intellij.codeInsight.folding.CodeFoldingManager) RangeHighlighter(com.intellij.openapi.editor.markup.RangeHighlighter) WriteCommandAction(com.intellij.openapi.command.WriteCommandAction) EditorActionManager(com.intellij.openapi.editor.actionSystem.EditorActionManager) Module(com.intellij.openapi.module.Module) TextEditor(com.intellij.openapi.fileEditor.TextEditor) GlobalSearchScope(com.intellij.psi.search.GlobalSearchScope) PlainTextFileType(com.intellij.openapi.fileTypes.PlainTextFileType) TextRange(com.intellij.openapi.util.TextRange) HighlighterTargetArea(com.intellij.openapi.editor.markup.HighlighterTargetArea) MarkupModel(com.intellij.openapi.editor.markup.MarkupModel) ConsoleView(com.intellij.execution.ui.ConsoleView) DeleteCatchFix(com.intellij.codeInsight.daemon.impl.quickfix.DeleteCatchFix) com.intellij.util(com.intellij.util) LightweightHint(com.intellij.ui.LightweightHint) ProjectManagerImpl(com.intellij.openapi.project.impl.ProjectManagerImpl) InspectionProjectProfileManager(com.intellij.profile.codeInspection.InspectionProjectProfileManager) ProperTextRange(com.intellij.openapi.util.ProperTextRange) java.util(java.util) ExternalResourceManagerExImpl(com.intellij.javaee.ExternalResourceManagerExImpl) com.intellij.openapi.editor(com.intellij.openapi.editor) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) EditorInfo(com.intellij.codeInsight.EditorInfo) Annotator(com.intellij.lang.annotation.Annotator) ThreadDumper(com.intellij.diagnostic.ThreadDumper) InspectionToolRegistrar(com.intellij.codeInspection.ex.InspectionToolRegistrar) CoreProgressManager(com.intellij.openapi.progress.impl.CoreProgressManager) Segment(com.intellij.openapi.util.Segment) TextConsoleBuilderFactory(com.intellij.execution.filters.TextConsoleBuilderFactory) AccessStaticViaInstance(com.intellij.codeInspection.accessStaticViaInstance.AccessStaticViaInstance) JavaLanguage(com.intellij.lang.java.JavaLanguage) DebugUtil(com.intellij.psi.impl.DebugUtil) StdFileTypes(com.intellij.openapi.fileTypes.StdFileTypes) Language(org.intellij.lang.annotations.Language) StringUtil(com.intellij.openapi.util.text.StringUtil) UnusedDeclarationInspectionBase(com.intellij.codeInspection.deadCode.UnusedDeclarationInspectionBase) ProjectManagerEx(com.intellij.openapi.project.ex.ProjectManagerEx) IOException(java.io.IOException) StorageUtilKt(com.intellij.configurationStore.StorageUtilKt) AbstractIntentionAction(com.intellij.codeInsight.intention.AbstractIntentionAction) Disposable(com.intellij.openapi.Disposable) InlineRefactoringActionHandler(com.intellij.refactoring.inline.InlineRefactoringActionHandler) File(java.io.File) java.awt(java.awt) AtomicLong(java.util.concurrent.atomic.AtomicLong) RequiredAttributesInspectionBase(com.intellij.codeInspection.htmlInspections.RequiredAttributesInspectionBase) Result(com.intellij.openapi.application.Result) InspectionToolWrapper(com.intellij.codeInspection.ex.InspectionToolWrapper) UndoManager(com.intellij.openapi.command.undo.UndoManager) LocalInspectionTool(com.intellij.codeInspection.LocalInspectionTool) ApplicationManagerEx(com.intellij.openapi.application.ex.ApplicationManagerEx) SimpleDataContext(com.intellij.openapi.actionSystem.impl.SimpleDataContext) HeavyProcessLatch(com.intellij.util.io.storage.HeavyProcessLatch) CheckDtdReferencesInspection(com.intellij.xml.util.CheckDtdReferencesInspection) GutterIconRenderer(com.intellij.openapi.editor.markup.GutterIconRenderer) ExternalAnnotator(com.intellij.lang.annotation.ExternalAnnotator) HighlightSeverity(com.intellij.lang.annotation.HighlightSeverity) PsiAwareTextEditorProvider(com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorProvider) MarkupModelEx(com.intellij.openapi.editor.ex.MarkupModelEx) AnnotationHolder(com.intellij.lang.annotation.AnnotationHolder) IdeActions(com.intellij.openapi.actionSystem.IdeActions) Nls(org.jetbrains.annotations.Nls) ConsoleViewContentType(com.intellij.execution.ui.ConsoleViewContentType) ProjectManager(com.intellij.openapi.project.ProjectManager) RangeHighlighterEx(com.intellij.openapi.editor.ex.RangeHighlighterEx) SaveAndSyncHandlerImpl(com.intellij.ide.SaveAndSyncHandlerImpl) Disposer(com.intellij.openapi.util.Disposer) EditorHintListener(com.intellij.codeInsight.hint.EditorHintListener) EditorEx(com.intellij.openapi.editor.ex.EditorEx) CommonDataKeys(com.intellij.openapi.actionSystem.CommonDataKeys) Method(java.lang.reflect.Method) LightQuickFixTestCase(com.intellij.codeInsight.daemon.quickFix.LightQuickFixTestCase) ProblemsHolder(com.intellij.codeInspection.ProblemsHolder) IntentionHintComponent(com.intellij.codeInsight.intention.impl.IntentionHintComponent) JavaFileType(com.intellij.ide.highlighter.JavaFileType) com.intellij.codeInsight.daemon(com.intellij.codeInsight.daemon) Collectors(java.util.stream.Collectors) com.intellij.codeHighlighting(com.intellij.codeHighlighting) Nullable(org.jetbrains.annotations.Nullable) ProgressIndicator(com.intellij.openapi.progress.ProgressIndicator) List(java.util.List) ApplicationManager(com.intellij.openapi.application.ApplicationManager) GeneralSettings(com.intellij.ide.GeneralSettings) IntentionAction(com.intellij.codeInsight.intention.IntentionAction) com.intellij.psi(com.intellij.psi) NotNull(org.jetbrains.annotations.NotNull) HintListener(com.intellij.ui.HintListener) WriteAction(com.intellij.openapi.application.WriteAction) DataContext(com.intellij.openapi.actionSystem.DataContext) NonNls(org.jetbrains.annotations.NonNls) AtomicBoolean(java.util.concurrent.atomic.AtomicBoolean) ContainerUtil(com.intellij.util.containers.ContainerUtil) AtomicReference(java.util.concurrent.atomic.AtomicReference) FileEditorManager(com.intellij.openapi.fileEditor.FileEditorManager) ProcessCanceledException(com.intellij.openapi.progress.ProcessCanceledException) RenameProcessor(com.intellij.refactoring.rename.RenameProcessor) InspectionProfile(com.intellij.codeInspection.InspectionProfile) IntentionManager(com.intellij.codeInsight.intention.IntentionManager) Project(com.intellij.openapi.project.Project) OpenFileDescriptor(com.intellij.openapi.fileEditor.OpenFileDescriptor) CodeInsightTestFixtureImpl(com.intellij.testFramework.fixtures.impl.CodeInsightTestFixtureImpl) FieldCanBeLocalInspection(com.intellij.codeInspection.varScopeCanBeNarrowed.FieldCanBeLocalInspection) TextEditorProvider(com.intellij.openapi.fileEditor.impl.text.TextEditorProvider) MarkupModelListener(com.intellij.openapi.editor.impl.event.MarkupModelListener) AbstractProjectComponent(com.intellij.openapi.components.AbstractProjectComponent) CommandProcessor(com.intellij.openapi.command.CommandProcessor) UnusedDeclarationInspection(com.intellij.codeInspection.deadCode.UnusedDeclarationInspection) FieldCanBeLocalInspection(com.intellij.codeInspection.varScopeCanBeNarrowed.FieldCanBeLocalInspection) AccessStaticViaInstance(com.intellij.codeInspection.accessStaticViaInstance.AccessStaticViaInstance) CheckDtdReferencesInspection(com.intellij.xml.util.CheckDtdReferencesInspection) RequiredAttributesInspectionBase(com.intellij.codeInspection.htmlInspections.RequiredAttributesInspectionBase) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper) InspectionToolWrapper(com.intellij.codeInspection.ex.InspectionToolWrapper) LocalInspectionTool(com.intellij.codeInspection.LocalInspectionTool) LocalInspectionToolWrapper(com.intellij.codeInspection.ex.LocalInspectionToolWrapper)

Aggregations

LocalInspectionToolWrapper (com.intellij.codeInspection.ex.LocalInspectionToolWrapper)26 NotNull (org.jetbrains.annotations.NotNull)11 InspectionToolWrapper (com.intellij.codeInspection.ex.InspectionToolWrapper)6 Nullable (org.jetbrains.annotations.Nullable)6 GlobalInspectionToolWrapper (com.intellij.codeInspection.ex.GlobalInspectionToolWrapper)4 ProgressIndicator (com.intellij.openapi.progress.ProgressIndicator)4 RefElement (com.intellij.codeInspection.reference.RefElement)3 TextRange (com.intellij.openapi.util.TextRange)3 List (java.util.List)3 AnalysisScope (com.intellij.analysis.AnalysisScope)2 IntentionAction (com.intellij.codeInsight.intention.IntentionAction)2 IntentionManager (com.intellij.codeInsight.intention.IntentionManager)2 IntentionHintComponent (com.intellij.codeInsight.intention.impl.IntentionHintComponent)2 InspectionManager (com.intellij.codeInspection.InspectionManager)2 LocalInspectionTool (com.intellij.codeInspection.LocalInspectionTool)2 ProblemDescriptor (com.intellij.codeInspection.ProblemDescriptor)2 RedundantCastInspection (com.intellij.codeInspection.redundantCast.RedundantCastInspection)2 RefEntity (com.intellij.codeInspection.reference.RefEntity)2 RefManagerImpl (com.intellij.codeInspection.reference.RefManagerImpl)2 RefVisitor (com.intellij.codeInspection.reference.RefVisitor)2