NIO Path method to get canonicalized pathname of a non-existing file

Wang Weijun weijun.wang at oracle.com
Tue Oct 18 15:07:40 UTC 2016


With java.io.File, one can call getCanonicalPath() to resolve symlinks (of a directory) even if the file does not exist. With the NIO Path, it seems toRealPath() only works for an existing file, is there a similar method to do this?

Thanks
Max



More information about the nio-dev mailing list