private static ExtendedCell createChunkCell(ByteBuffer buf, int offset, int len, int tagsLen,
    long sequenceId) {
    // TODO : write the seqid here. For writing seqId we should create a new cell type so
    // that seqId is not used as the state
    if (tagsLen == 0) {
      // When tagsLen is 0, make a NoTagsByteBufferKeyValue version. This is an optimized class
      // which directly return tagsLen as 0. So we avoid parsing many length components in
      // reading the tagLength stored in the backing buffer. The Memstore addition of every Cell
      // call getTagsLength().
      return new NoTagByteBufferChunkKeyValue(buf, offset, len, sequenceId);
    } else {
      return new ByteBufferChunkKeyValue(buf, offset, len, sequenceId);
    }
  }
Clone the passed cell by copying its data into the passed buf and create a cell with a chunkid
out of it
@see #copyToChunkCell(Cell, ByteBuffer, int, int)
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/MemStoreLABImpl.java