public void resetBuf(int size) {
      this.buf = new byte[size];
      this.pos = size;
    }
Base implementation for {@link Codec.Decoder}.
hbase-common/src/main/java/org/apache/hadoop/hbase/codec/BaseDecoder.java