@Override
  public byte[] toBytes(int offset, int length) {
    checkRefCount();
    byte[] output = new byte[length];
    this.get(offset, output, 0, length);
    return output;
  }
Copy the content from this MBB to a byte[] based on the given offset and length the position
from where the copy should start the length upto which the copy has to be done
@return byte[] with the copied contents from this MBB.
hbase-common/src/main/java/org/apache/hadoop/hbase/nio/MultiByteBuff.java