public TimeValuePair composeTimeValuePair(int columnIndex) {
    if (columnIndex >= values.length || Objects.isNull(dataTypes[columnIndex])) {
      return null;
    }
    Object value = values[columnIndex];
    return Objects.nonNull(value)
        ? new TimeValuePair(time, TsPrimitiveType.getByType(dataTypes[columnIndex], value))
        : null;
  }
Make sure the dataTypes and values have been created before calling this.

@param buffer - ByteBuffer
@throws UnSupportedDataTypeException - If meets unsupported data type.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/planner/plan/node/write/InsertRowNode.java