String (final PsiElement element, final String name) { if (element instanceof NavigationItem) { final ItemPresentation presentation = ((NavigationItem)element).getPresentation(); return presentation != null ? presentation.getLocationString():null; } return null; }