Boolean (PsiElement element, @NotNull StringSearcher searcher, int start, @NotNull ProgressIndicator progress, InjectedLanguageManager injectedLanguageManager, @NotNull TextOccurenceProcessor processor) { if (!(element instanceof PsiLanguageInjectionHost)) return null; if (injectedLanguageManager == null) return null; List<Pair<PsiElement, TextRange>> list = injectedLanguageManager.getInjectedPsiFiles(element); if (list == null) return null; boolean hasMatchedRange = false; for (Pair<PsiElement, TextRange> pair : list) { if (!pair.second.containsRange(start, start + searcher.getPatternLength())) continue; hasMatchedRange = true; final PsiElement injected = pair.getFirst(); if (!processElementsContainingWordInElement(processor, injected, searcher, false, progress)) return Boolean.FALSE; } return hasMatchedRange ? Boolean.TRUE : null; }