Opens a new ZipFile to read from the specified
File object in the specified mode. The mode argument
must be either OPEN_READ or OPEN_READ | OPEN_DELETE.
First, if there is a security manager, its checkRead
method is called with the name argument as its argument to
ensure the read is allowed.
file | the ZIP file to be opened for reading | |
mode | the mode in which the file is to be opened | |
charset
| the charset to be used to decode the ZIP entry name and comment that are not encoded by using UTF-8 encoding (indicated by entry's general purpose flag). |
ZipException | if a ZIP format error has occurred | |
IOException | if an I/O error has occurred | |
SecurityException
| if a security manager exists and its checkRead
method doesn't allow read access to the file,or its
checkDelete method doesn't allow deleting the
file when the OPEN_DELETE flag is set | |
IllegalArgumentException | if the mode argument is invalid |
SecurityManager.checkRead(java.lang.String)
Diagram: ZipFile