Summary
Add support for explicit creation of ZipFileSystem instances via the "environment" parameters.
Problem
Zip/Jar files are often expected to be used as archives, and as such it may be surprising if contents are modified as a side effect of other actions. To facilitate a robust mechanism for avoiding accidental "write back" to Zip/Jar files by applications, there should be a mechanism for mounting them in a read-only state.
Solution
Add a new "readOnly" environmental parameter to allow anyone explicitly creating zip file system instance to specify that they want it to be read-only.
Specification
src/jdk.zipfs/share/classes/module-info.java
* <tr>
* <th scope="row">readOnly</th>
* <td>{@link java.lang.String} or {@link java.lang.Boolean}</td>
* <td>false</td>
* <td>
* If the value is {@code true}, the ZIP file system will be read-only.
* </td>
* </tr>
- csr of
-
JDK-8350880 (zipfs) Add support for read-only zip file systems
-
- Open
-