Class SnappyFramedOutputStream

java.lang.Object
java.io.OutputStream
io.airlift.compress.snappy.SnappyFramedOutputStream
All Implemented Interfaces:
Closeable, Flushable, AutoCloseable

public final class SnappyFramedOutputStream extends OutputStream
Implements the x-snappy-framed as an OutputStream.
  • Field Details

    • MAX_BLOCK_SIZE

      public static final int MAX_BLOCK_SIZE
      We place an additional restriction that the uncompressed data in a chunk must be no longer than 65536 bytes. This allows consumers to easily use small fixed-size buffers.
      See Also:
    • DEFAULT_BLOCK_SIZE

      public static final int DEFAULT_BLOCK_SIZE
      See Also:
    • DEFAULT_MIN_COMPRESSION_RATIO

      public static final double DEFAULT_MIN_COMPRESSION_RATIO
      See Also:
  • Constructor Details

    • SnappyFramedOutputStream

      public SnappyFramedOutputStream(OutputStream out) throws IOException
      Creates a Snappy output stream to write data to the specified underlying output stream.
      Parameters:
      out - the underlying output stream
      Throws:
      IOException
    • SnappyFramedOutputStream

      public SnappyFramedOutputStream(OutputStream out, boolean writeChecksums, int blockSize, double minCompressionRatio) throws IOException
      Throws:
      IOException
  • Method Details