Class DeflateCompressor
java.lang.Object
org.apache.pekko.http.scaladsl.coding.Compressor
org.apache.pekko.http.scaladsl.coding.DeflateCompressor
- Direct Known Subclasses:
- GzipCompressor
Internal API
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionfinal org.apache.pekko.util.ByteStringcompress(org.apache.pekko.util.ByteString input) Compresses the given input and returns compressed data.final org.apache.pekko.util.ByteStringcompressAndFinish(org.apache.pekko.util.ByteString input) Combines `compress` + `finish`final org.apache.pekko.util.ByteStringcompressAndFlush(org.apache.pekko.util.ByteString input) Combines `compress` + `flush`protected org.apache.pekko.util.ByteStringcompressWithBuffer(org.apache.pekko.util.ByteString input, byte[] buffer) static intprotected Deflaterdeflater()static org.apache.pekko.util.ByteStringdrainDeflater(Deflater deflater, byte[] buffer, org.apache.pekko.util.ByteStringBuilder result) final org.apache.pekko.util.ByteStringfinish()Closes this compressed stream and return the remaining compressed data.protected org.apache.pekko.util.ByteStringfinishWithBuffer(byte[] buffer) final org.apache.pekko.util.ByteStringflush()Flushes any output data and returns the currently remaining compressed data.protected org.apache.pekko.util.ByteStringflushWithBuffer(byte[] buffer) static int
- 
Constructor Details- 
DeflateCompressorpublic DeflateCompressor(int compressionLevel) 
- 
DeflateCompressorpublic DeflateCompressor()
 
- 
- 
Method Details- 
MinBufferSizepublic static int MinBufferSize()
- 
DefaultCompressionLevelpublic static int DefaultCompressionLevel()
- 
drainDeflaterpublic static org.apache.pekko.util.ByteString drainDeflater(Deflater deflater, byte[] buffer, org.apache.pekko.util.ByteStringBuilder result) 
- 
deflater
- 
compressAndFlushpublic final org.apache.pekko.util.ByteString compressAndFlush(org.apache.pekko.util.ByteString input) Description copied from class:CompressorCombines `compress` + `flush`- Specified by:
- compressAndFlushin class- Compressor
 
- 
compressAndFinishpublic final org.apache.pekko.util.ByteString compressAndFinish(org.apache.pekko.util.ByteString input) Description copied from class:CompressorCombines `compress` + `finish`- Specified by:
- compressAndFinishin class- Compressor
 
- 
compresspublic final org.apache.pekko.util.ByteString compress(org.apache.pekko.util.ByteString input) Description copied from class:CompressorCompresses the given input and returns compressed data. The implementation can and will choose to buffer output data to improve compression. UseflushorcompressAndFlushto make sure that all input data has been compressed and pending output data has been returned.- Specified by:
- compressin class- Compressor
- Parameters:
- input- (undocumented)
- Returns:
- (undocumented)
 
- 
flushpublic final org.apache.pekko.util.ByteString flush()Description copied from class:CompressorFlushes any output data and returns the currently remaining compressed data.- Specified by:
- flushin class- Compressor
- Returns:
- (undocumented)
 
- 
finishpublic final org.apache.pekko.util.ByteString finish()Description copied from class:CompressorCloses this compressed stream and return the remaining compressed data. After calling this method, this Compressor cannot be used any further.- Specified by:
- finishin class- Compressor
- Returns:
- (undocumented)
 
- 
compressWithBufferprotected org.apache.pekko.util.ByteString compressWithBuffer(org.apache.pekko.util.ByteString input, byte[] buffer) 
- 
flushWithBufferprotected org.apache.pekko.util.ByteString flushWithBuffer(byte[] buffer) 
- 
finishWithBufferprotected org.apache.pekko.util.ByteString finishWithBuffer(byte[] buffer) 
 
-