| 1280 | |
| 1281 | template <typename DType> |
| 1282 | void DeltaBitPackEncoder<DType>::PutSpaced(const T* src, int num_values, |
| 1283 | const uint8_t* valid_bits, |
| 1284 | int64_t valid_bits_offset) { |
| 1285 | if (valid_bits != NULLPTR) { |
| 1286 | PARQUET_ASSIGN_OR_THROW(auto buffer, ::arrow::AllocateBuffer(num_values * sizeof(T), |
| 1287 | this->memory_pool())); |
| 1288 | T* data = buffer->template mutable_data_as<T>(); |
| 1289 | int num_valid_values = ::arrow::util::internal::SpacedCompress<T>( |
| 1290 | src, num_values, valid_bits, valid_bits_offset, data); |
| 1291 | Put(data, num_valid_values); |
| 1292 | } else { |
| 1293 | Put(src, num_values); |
| 1294 | } |
| 1295 | } |
| 1296 | |
| 1297 | // ---------------------------------------------------------------------- |
| 1298 | // DELTA_LENGTH_BYTE_ARRAY encoder |
no outgoing calls