Injection (@NotNull PsiElement context) { if (!(context instanceof PsiLanguageInjectionHost host) || !((PsiLanguageInjectionHost)context).isValidHost()) return null; for (LanguageInjectionSupport support : InjectorUtils.getActiveInjectionSupports()) { if (!support.isApplicableTo(host)) continue; if (!support.useDefaultInjector(host)) continue; for (BaseInjection injection : Configuration.getProjectInstance(context.getProject()).getInjections(support.getId())) { if (!injection.acceptsPsiElement(host)) continue; return injection; } } return null; }