mirror of
https://github.com/corda/corda.git
synced 2025-01-07 13:38:47 +00:00
add ZipFile(File) constructor and ZipFile.close
This commit is contained in:
parent
114bf777bb
commit
aeafb52bcb
@ -10,6 +10,7 @@
|
||||
|
||||
package java.util.zip;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.RandomAccessFile;
|
||||
import java.io.InputStream;
|
||||
import java.io.IOException;
|
||||
@ -54,6 +55,10 @@ public class ZipFile {
|
||||
}
|
||||
}
|
||||
|
||||
public ZipFile(File file) throws IOException {
|
||||
this(file.getAbsolutePath());
|
||||
}
|
||||
|
||||
public int size() {
|
||||
return index.size();
|
||||
}
|
||||
@ -177,6 +182,10 @@ public class ZipFile {
|
||||
return get2(w, p + 28);
|
||||
}
|
||||
|
||||
public void close() throws IOException {
|
||||
file.close();
|
||||
}
|
||||
|
||||
private static class Window {
|
||||
private final RandomAccessFile file;
|
||||
public final byte[] data;
|
||||
|
Loading…
Reference in New Issue
Block a user