public void flushGroup() throws IOException {
        if (prevValueLength >= 0) {
          WritableUtils.writeVLong(valLenBuffer, prevValueLength);
          if (runLength > 0) {
            WritableUtils.writeVLong(valLenBuffer, ~runLength);
          }
          runLength = -1;
          prevValueLength = -1;
        }
      }
Write KeyBuffer/ValueBuffer pairs to a RCFile. RCFile's format is
compatible with SequenceFile's.
ql/src/java/org/apache/hadoop/hive/ql/io/RCFile.java