| 845 | } |
| 846 | |
| 847 | Status TransferHalfFloat(RecordReader* reader, MemoryPool* pool, |
| 848 | const std::shared_ptr<Field>& field, Datum* out) { |
| 849 | static const auto binary_type = ::arrow::fixed_size_binary(2); |
| 850 | // Read as a FixedSizeBinaryArray - then, view as a HalfFloatArray |
| 851 | std::shared_ptr<ChunkedArray> chunked_array; |
| 852 | RETURN_NOT_OK( |
| 853 | TransferBinary(reader, pool, field->WithType(binary_type), &chunked_array)); |
| 854 | ARROW_ASSIGN_OR_RAISE(*out, chunked_array->View(field->type())); |
| 855 | return Status::OK(); |
| 856 | } |
| 857 | |
| 858 | } // namespace |
| 859 |
no test coverage detected