Class SnappyCompressor

java.lang.Object
org.apache.hadoop.hbase.io.compress.xerial.SnappyCompressor
All Implemented Interfaces:
CanReinit, org.apache.hadoop.io.compress.Compressor

@Private public class SnappyCompressor extends Object implements CanReinit, org.apache.hadoop.io.compress.Compressor
Hadoop compressor glue for Xerial Snappy.
  • Field Details

  • Constructor Details

  • Method Details

    • compress

      public int compress(byte[] b, int off, int len) throws IOException
      Specified by:
      compress in interface org.apache.hadoop.io.compress.Compressor
      Throws:
      IOException
    • end

      public void end()
      Specified by:
      end in interface org.apache.hadoop.io.compress.Compressor
    • finish

      public void finish()
      Specified by:
      finish in interface org.apache.hadoop.io.compress.Compressor
    • finished

      public boolean finished()
      Specified by:
      finished in interface org.apache.hadoop.io.compress.Compressor
    • getBytesRead

      public long getBytesRead()
      Specified by:
      getBytesRead in interface org.apache.hadoop.io.compress.Compressor
    • getBytesWritten

      public long getBytesWritten()
      Specified by:
      getBytesWritten in interface org.apache.hadoop.io.compress.Compressor
    • needsInput

      public boolean needsInput()
      Specified by:
      needsInput in interface org.apache.hadoop.io.compress.Compressor
    • reinit

      public void reinit(org.apache.hadoop.conf.Configuration conf)
      Specified by:
      reinit in interface CanReinit
      Specified by:
      reinit in interface org.apache.hadoop.io.compress.Compressor
    • reset

      public void reset()
      Specified by:
      reset in interface org.apache.hadoop.io.compress.Compressor
    • setDictionary

      public void setDictionary(byte[] b, int off, int len)
      Specified by:
      setDictionary in interface org.apache.hadoop.io.compress.Compressor
    • setInput

      public void setInput(byte[] b, int off, int len)
      Specified by:
      setInput in interface org.apache.hadoop.io.compress.Compressor
    • maxCompressedLength

      int maxCompressedLength(int len)