void (@NotNull PsiReferenceRegistrar registrar) { UastReferenceRegistrar .registerUastReferenceProvider(registrar, injectionHostUExpression() .sourcePsiFilter(psi -> PsiUtil.isPluginProject(psi.getProject())) .methodCallParameter(0, psiMethod() .withName(string().oneOf("get", "is", "intValue", "doubleValue", "stringValue", "getColor")) .definedInClass(PsiJavaPatterns.psiClass().withQualifiedName(string().oneOf( Registry.class.getName(), RegistryManager.class.getName() )))), new UastInjectionHostReferenceProvider() { @Override public boolean acceptsTarget(@NotNull PsiElement target) { return PropertyReferenceBase.isPropertyPsi(target); } @Override public PsiReference @NotNull [] getReferencesForInjectionHost(@NotNull UExpression uExpression, @NotNull PsiLanguageInjectionHost host, @NotNull ProcessingContext context) { return new PsiReference[]{new RegistryKeyIdReference(host)}; } }, PsiReferenceRegistrar.DEFAULT_PRIORITY); }