String () { final PsiDirectory psiDirectory = getParent(); if (psiDirectory != null) { final VirtualFile virtualFile = getVirtualFile(); if (virtualFile != null) { final VirtualFile root = ProjectFileIndex.getInstance(getProject()).getContentRootForFile(virtualFile); if (root != null) { final VirtualFile parent = virtualFile.getParent(); final VirtualFile rootParent = root.getParent(); if (rootParent != null && parent != null) { return VfsUtilCore.getRelativePath(parent, rootParent, File.separatorChar); } } } } return null; }