Absolute Path of PsiClass

How would I go about finding the absolute path of a PsiClass? I see that there is a getContainingFile method, but I'm not seeing any way to get an absolute path. I'm sure I'm just missing something veyr simple.

Thanks!

0

    VirtualFile file = yourPsiClass.getContainingFile().getOriginalFile().getVirtualFile();
    if (file != null && file.isInLocalFileSystem()) {
      return file.getCanonicalPath();
    }

0

请先登录再写评论。