MCPcopy Create free account
hub / github.com/apache/arrow / TransferHalfFloat

Function TransferHalfFloat

cpp/src/parquet/arrow/reader_internal.cc:846–855  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

844}
845
846Status TransferHalfFloat(RecordReader* reader, MemoryPool* pool,
847 const std::shared_ptr<Field>& field, Datum* out) {
848 static const auto binary_type = ::arrow::fixed_size_binary(2);
849 // Read as a FixedSizeBinaryArray - then, view as a HalfFloatArray
850 std::shared_ptr<ChunkedArray> chunked_array;
851 RETURN_NOT_OK(
852 TransferBinary(reader, pool, field->WithType(binary_type), &chunked_array));
853 ARROW_ASSIGN_OR_RAISE(*out, chunked_array->View(field->type()));
854 return Status::OK();
855}
856
857// Decode a little-endian 96-bit FLBA(12) TIMESTAMP value into a 64-bit Arrow timestamp.
858// Values that do not fit in the int64 range either error or clamp to the minimum or

Callers 1

TransferColumnDataFunction · 0.85

Calls 7

fixed_size_binaryFunction · 0.85
TransferBinaryFunction · 0.85
WithTypeMethod · 0.80
ARROW_ASSIGN_OR_RAISEFunction · 0.70
OKFunction · 0.50
ViewMethod · 0.45
typeMethod · 0.45

Tested by

no test coverage detected