List of utility methods to do Byte Array Unzip
byte[] | decompress(byte[] data) decompress ByteArrayInputStream bais = new ByteArrayInputStream(data); ByteArrayOutputStream baos = new ByteArrayOutputStream(); decompress(bais, baos); data = baos.toByteArray(); try { baos.flush(); } catch (IOException e) { System.out.println(e.getMessage()); ... |
byte[] | decompress(byte[] data) decompress ByteArrayInputStream bais = new ByteArrayInputStream(data); ByteArrayOutputStream baos = new ByteArrayOutputStream(); decompress(bais, baos); data = baos.toByteArray(); try { baos.flush(); } catch (IOException e) { System.out.println(e.getMessage()); ... |
byte[] | decompress(byte[] paramArrayOfByte) decompress ByteArrayInputStream localByteArrayInputStream = new ByteArrayInputStream( paramArrayOfByte); GZIPInputStream localGZIPInputStream = new GZIPInputStream( localByteArrayInputStream); ByteArrayOutputStream localByteArrayOutputStream = new ByteArrayOutputStream(); byte[] arrayOfByte = new byte[1024]; for (;;) { int i = localGZIPInputStream.read(arrayOfByte, 0, 1024); ... |
byte[] | deflate(byte[] paramArrayOfByte) deflate return deflate(paramArrayOfByte, 0, paramArrayOfByte.length);
|
byte[] | deflate(byte[] paramArrayOfByte, int paramInt1, int paramInt2) deflate ByteArrayOutputStream localByteArrayOutputStream = new ByteArrayOutputStream(); DeflaterOutputStream localDeflaterOutputStream = new DeflaterOutputStream( localByteArrayOutputStream, new Deflater()); try { localDeflaterOutputStream.write(paramArrayOfByte, paramInt1, paramInt2); localDeflaterOutputStream.close(); return localByteArrayOutputStream.toByteArray(); ... |