Code example for DeflaterOutputStream

Methods: close

0
    { 
      // A duplicate close is just a NO-OP as with all other output streams. 
      return; 
    } 
 
    deflaterOutputStream.close();
    item.setRawData(outputStream.toByteArray(), size, crc32.getValue());
 
    closed = true;
    outputStream = null;
    deflaterOutputStream = null;
  } 
 
  public void write(final byte[] b)
      throws IOException 
  { 
    if (closed)
    { 
      throw new IOException("Already closed");
    } 
    deflaterOutputStream.write(b);