看了JDK 7的API
getPath()
Converts this abstract pathname into a pathname string.
getCanonicalPath()
Returns the canonical pathname string of this abstract pathname.
getAbsolutePath()
Returns the absolute pathname string of this abstract pathname.
还是有些迷糊, 这三个方法都是将abstract pathname转换成了pathname string 但到底这三个方法有啥区别?
求指点,谢谢 |