public @Nullable PsiElement getPsiElement(final Object element) {
    if (element instanceof PsiElement) {
      return (PsiElement)element;
    }
    return null;
  }
public @Nullable PsiElement getPsiElement(final Object element)