I've noticed that ZipFileStore#supportsFileAttributeView(String)
doesn't throw NullPointerException when 'null' is passed as an
argument.
public boolean supportsFileAttributeView(String name) {
return "basic".equals(name) || "zip".equals(name) ||
(("owner".equals(name) || "posix".equals(name)) && zfs.supportPosix);
}
Package level javadoc for {{java.nio.file}} package mentions that NullPointerException is expected from all methods which pass {{null}}:
>Unless otherwise noted, passing a null argument to a constructor or method in any class or interface in this package will cause a NullPointerException to be thrown.
Other JDK implementations of FileStore throw NPE in this method in case of null.
doesn't throw NullPointerException when 'null' is passed as an
argument.
public boolean supportsFileAttributeView(String name) {
return "basic".equals(name) || "zip".equals(name) ||
(("owner".equals(name) || "posix".equals(name)) && zfs.supportPosix);
}
Package level javadoc for {{java.nio.file}} package mentions that NullPointerException is expected from all methods which pass {{null}}:
>Unless otherwise noted, passing a null argument to a constructor or method in any class or interface in this package will cause a NullPointerException to be thrown.
Other JDK implementations of FileStore throw NPE in this method in case of null.
- relates to
-
JDK-8222276 (zipfs) Refactoring and cleanups to prepare for JDK-8213031
-
- Closed
-