JDK-6838333 : New I/O: Update file system API to jsr203/nio2-b101
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.nio
  • Affected Version: 7
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2009-05-07
  • Updated: 2017-05-16
  • Resolved: 2009-07-17
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7
7 b64Fixed
Related Reports
Duplicate :  
Description
This bug tracks updates to the JSR-203 spec that have accumulated since the integration into jdk7 b50.

- The FileRef interface has gone astray from its original goals and should be corrected. It should be a simple interface that allows the file to be opened for reading or writing, and provide access to associated metadata. It can be implemented by Path and java.net.URL.

- The conditions for when Path#toAbsolutePath throws a security exception are not clear and should be clarified.

- Path defines both delete() and delete(boolean). The latter method would be cleaner if replaced by a deleteIfNotexists method.

- Path#newDirectoryStream(String) declares a bogus UOE.

- Path#copyTo should make it clear that last-modified-time is only copied if supported by file system.

- Paths.get(URI) and FileSystemProvider should make it clear that the FileSystem can be created on-demand

- BasicFileAttributes#linkCount should be removed.

- PosixFilePermissions#toString should make it clear that the returned String is parsable by fromString.

- lookupPrincipalByGroupName returns a GroupPrincipal (spec currently states a user principal).

- API doesn't have the equivalent of File#mkdirs. This is trivially added as Files#createDirectories.

- DirectoryStreamFilters is not as useful as originally thought; it can be removed.

- FileAction/Files#withDirectory is not as useful as originally thought; it can be removed.

- SecureDirectoryStream#newDirectoryStream has a boolean to indicate if links should be followed. This should be changed to LinkOption... and the filter removed.

Comments
EVALUATION See description.
07-05-2009