public static List<TCell> cellFromHBase(Cell[] in) {
    List<TCell> list = null;
    if (in != null) {
      list = new ArrayList<>(in.length);
      for (int i = 0; i < in.length; i++) {
        list.add(new TCell(ByteBuffer.wrap(CellUtil.cloneValue(in[i])), in[i].getTimestamp()));
      }
    } else {
      list = new ArrayList<>(0);
    }
    return list;
  }
This utility method creates a list of Thrift TCell "struct" based on an Hbase Cell array. The
empty list is returned if the input is null.
@param in Hbase Cell array
@return Thrift TCell array
hbase-thrift/src/main/java/org/apache/hadoop/hbase/thrift/ThriftUtilities.java