Package org.xerial.snappy
Class SnappyHadoopCompatibleOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- org.xerial.snappy.SnappyOutputStream
-
- org.xerial.snappy.SnappyHadoopCompatibleOutputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.io.Flushable,java.lang.AutoCloseable
public class SnappyHadoopCompatibleOutputStream extends SnappyOutputStream
-
-
Field Summary
-
Fields inherited from class org.xerial.snappy.SnappyOutputStream
DEFAULT_BLOCK_SIZE, inputBuffer, MAX_BLOCK_SIZE, MIN_BLOCK_SIZE, out, outputBuffer
-
-
Constructor Summary
Constructors Constructor Description SnappyHadoopCompatibleOutputStream(java.io.OutputStream out)SnappyHadoopCompatibleOutputStream(java.io.OutputStream out, int blockSize)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidwriteBlockPreemble()Optionally write a preemble before a block.protected intwriteHeader()-
Methods inherited from class org.xerial.snappy.SnappyOutputStream
close, compressInput, dumpOutput, flush, rawWrite, write, write, write, write, write, write, write, write, write, write, write, write, writeCurrentDataSize
-
-
-
-
Method Detail
-
writeHeader
protected int writeHeader()
- Overrides:
writeHeaderin classSnappyOutputStream
-
writeBlockPreemble
protected void writeBlockPreemble()
Description copied from class:SnappyOutputStreamOptionally write a preemble before a block. Hadoop requires the actual block data size being written. This base implementation does nothing. Derive implementation can callwriteCurrentDataSize().- Overrides:
writeBlockPreemblein classSnappyOutputStream
-
-