void (final @NotNull List<? extends PsiClass> classes) { for (PsiMethod method : myClass.getMethods()) { List<HierarchicalMethodSignature> superSignatures = method.getHierarchicalMethodSignature().getSuperSignatures(); for (HierarchicalMethodSignature superSignature : superSignatures) { PsiClass containingClass = superSignature.getMethod().getContainingClass(); if (containingClass == null) continue; for (PsiClass classToAnalyze : classes) { if (InheritanceUtil.isInheritorOrSelf(classToAnalyze, containingClass, true)) { PsiIdentifier identifier = method.getNameIdentifier(); if (identifier != null) { addOccurrence(identifier); break; } } } } } if (myReadUsages.isEmpty()) { if (ApplicationManager.getApplication().isUnitTestMode()) return; String name; if (classes.size() == 1) { final ItemPresentation presentation = classes.get(0).getPresentation(); name = presentation != null ? presentation.getPresentableText() : ""; } else { name = ""; } myHintText = JavaBundle.message("no.methods.overriding.0.are.found", classes.size(), name); } else { addOccurrence(myTarget); final int methodCount = myReadUsages.size()-1; // exclude 'target' keyword myStatusText = JavaBundle.message("status.bar.overridden.methods.highlighted.message", methodCount, HighlightUsagesHandler.getShortcutText()); } }