Method
unzipEntry
(ZipInputStream zin, File f)
Source from the content-addressed store, hash-verified
| 713 | |
| 714 | |
| 715 | static protected void unzipEntry(ZipInputStream zin, File f) throws IOException { |
| 716 | FileOutputStream out = new FileOutputStream(f); |
| 717 | byte[] b = new byte[512]; |
| 718 | int len; |
| 719 | while ((len = zin.read(b)) != -1) { |
| 720 | out.write(b, 0, len); |
| 721 | } |
| 722 | out.flush(); |
| 723 | out.close(); |
| 724 | } |
| 725 | |
| 726 | |
| 727 | static public byte[] gzipEncode(byte[] what) throws IOException { |
Tested by
no test coverage detected