SpellcheckingStrategy (@NotNull PsiElement element, @NotNull Language language) { for (SpellcheckingStrategy strategy : LanguageSpellchecking.INSTANCE.allForLanguage(language)) { if (strategy.isMyContext(element)) { return strategy; } } return null; }