PsiElement (@NotNull UsageInfo2UsageAdapter usage) { Ref<PsiElement> elementRef = new Ref<>(); ApplicationManager.getApplication().runReadAction(() -> { elementRef.set(usage.getElement()); }); return elementRef.get(); }