Class GZIPOutputStream
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
java.util.zip.DeflaterOutputStream
java.util.zip.GZIPOutputStream
- All Implemented Interfaces:
AutoCloseable
-
Field Summary
FieldsFields inherited from class DeflaterOutputStream
buf, defFields inherited from class FilterOutputStream
out -
Constructor Summary
ConstructorsConstructorDescriptionGZIPOutputStream(OutputStream arg0) GZIPOutputStream(OutputStream arg0, boolean arg1) GZIPOutputStream(OutputStream arg0, int arg1) GZIPOutputStream(OutputStream arg0, int arg1, boolean arg2) -
Method Summary
Methods inherited from class DeflaterOutputStream
deflate, flush, writeMethods inherited from class OutputStream
write
-
Field Details
-
crc
-
-
Constructor Details
-
GZIPOutputStream
- Throws:
IOException
-
GZIPOutputStream
- Throws:
IOException
-
GZIPOutputStream
- Throws:
IOException
-
GZIPOutputStream
- Throws:
IOException
-
-
Method Details
-
write
Description copied from class:OutputStreamWrites len bytes from the specified byte array starting at offset off to this output stream. The general contract for write(b, off, len) is that some of the bytes in the array b are written to the output stream in order; elementb[off]is the first byte written andb[off+len-1]is the last byte written by this operation. The write method of OutputStream calls the write method of one argument on each of the bytes to be written out. Subclasses are encouraged to override this method and provide a more efficient implementation. If b is null, a NullPointerException is thrown. If off is negative, or len is negative, or off+len is greater than the length of the array b, then an IndexOutOfBoundsException is thrown.- Overrides:
writein classDeflaterOutputStream- Throws:
IOException
-
finish
- Overrides:
finishin classDeflaterOutputStream- Throws:
IOException
-
close
Description copied from class:OutputStreamCloses this output stream and releases any system resources associated with this stream. The general contract of close is that it closes the output stream. A closed stream cannot perform output operations and cannot be reopened. The close method of OutputStream does nothing.- Specified by:
closein interfaceAutoCloseable- Overrides:
closein classDeflaterOutputStream- Throws:
IOException
-