Class HadoopSnappyCompressionOutputStream

java.lang.Object
java.io.OutputStream
org.pentaho.di.core.compress.CompressionOutputStream
org.pentaho.di.core.compress.hadoopsnappy.HadoopSnappyCompressionOutputStream
All Implemented Interfaces:
Closeable, Flushable, AutoCloseable

public class HadoopSnappyCompressionOutputStream extends CompressionOutputStream
  • Constructor Details

  • Method Details

    • getSnappyOutputStream

      public static OutputStream getSnappyOutputStream(OutputStream out) throws Exception
      Gets an OutputStream that uses the snappy codec and wraps the supplied base output stream.
      Parameters:
      the - buffer size for the codec to use (in bytes)
      out - the base output stream to wrap around
      Returns:
      a OutputStream that uses the Snappy codec
      Throws:
      Exception - if snappy is not available or an error occurs during reflection
    • getSnappyOutputStream

      public static OutputStream getSnappyOutputStream(int bufferSize, OutputStream out) throws Exception
      Gets an OutputStream that uses the snappy codec and wraps the supplied base output stream.
      Parameters:
      the - buffer size for the codec to use (in bytes)
      out - the base output stream to wrap around
      Returns:
      a OutputStream that uses the Snappy codec
      Throws:
      Exception - if snappy is not available or an error occurs during reflection