Class Compress
Index
Constructors
constructor
Creates a GZIP stream
Parameters
- opts: GzipOptions
The compression options
Optionalcb: FlateStreamHandlerThe callback to call whenever data is deflated
Returns Compress
- opts: GzipOptions
Creates a GZIP stream
Parameters
Optionalcb: FlateStreamHandlerThe callback to call whenever data is deflated
Returns Compress
Methods
flush
Flushes buffered uncompressed data. Useful to immediately retrieve the GZIPped output for small inputs.
Returns void
push
Pushes a chunk to be GZIPped
Parameters
- chunk: Uint8Array
The chunk to push
Optionalfinal: booleanWhether this is the last chunk
Returns void
- chunk: Uint8Array
Streaming GZIP compression