Class ZstdCompressor
java.lang.Object
org.apache.hadoop.hbase.io.compress.zstd.ZstdCompressor
- All Implemented Interfaces:
CanReinit,org.apache.hadoop.io.compress.Compressor
@Private
public class ZstdCompressor
extends Object
implements CanReinit, org.apache.hadoop.io.compress.Compressor
Hadoop compressor glue for zstd-jni.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected intprotected longprotected longprotected com.github.luben.zstd.ZstdCompressCtxprotected com.github.luben.zstd.ZstdDictCompressprotected intprotected booleanprotected booleanprotected ByteBufferprotected intprotected ByteBuffer -
Constructor Summary
ConstructorsConstructorDescriptionZstdCompressor(int level, int bufferSize) ZstdCompressor(int level, int bufferSize, byte[] dictionary) -
Method Summary
Modifier and TypeMethodDescriptionintcompress(byte[] b, int off, int len) voidend()voidfinish()booleanfinished()longlong(package private) static intmaxCompressedLength(int len) booleanvoidreinit(org.apache.hadoop.conf.Configuration conf) voidreset()voidsetDictionary(byte[] b, int off, int len) voidsetInput(byte[] b, int off, int len)
-
Field Details
-
level
-
bufferSize
-
inBuf
-
outBuf
-
finish
-
finished
-
bytesRead
-
bytesWritten
-
dictId
-
dict
-
ctx
-
-
Constructor Details
-
ZstdCompressor
ZstdCompressor(int level, int bufferSize, byte[] dictionary) -
ZstdCompressor
ZstdCompressor(int level, int bufferSize)
-
-
Method Details
-
compress
- Specified by:
compressin interfaceorg.apache.hadoop.io.compress.Compressor- Throws:
IOException
-
end
- Specified by:
endin interfaceorg.apache.hadoop.io.compress.Compressor
-
finish
- Specified by:
finishin interfaceorg.apache.hadoop.io.compress.Compressor
-
finished
- Specified by:
finishedin interfaceorg.apache.hadoop.io.compress.Compressor
-
getBytesRead
- Specified by:
getBytesReadin interfaceorg.apache.hadoop.io.compress.Compressor
-
getBytesWritten
- Specified by:
getBytesWrittenin interfaceorg.apache.hadoop.io.compress.Compressor
-
needsInput
- Specified by:
needsInputin interfaceorg.apache.hadoop.io.compress.Compressor
-
reinit
-
reset
- Specified by:
resetin interfaceorg.apache.hadoop.io.compress.Compressor
-
setDictionary
- Specified by:
setDictionaryin interfaceorg.apache.hadoop.io.compress.Compressor
-
setInput
- Specified by:
setInputin interfaceorg.apache.hadoop.io.compress.Compressor
-
maxCompressedLength
-