| 327 | |
| 328 | template <> |
| 329 | inline void DataPageBuilder<BooleanType>::AppendValues(const ColumnDescriptor* d, |
| 330 | const std::vector<bool>& values, |
| 331 | Encoding::type encoding) { |
| 332 | if (encoding != Encoding::PLAIN) { |
| 333 | ParquetException::NYI("only plain encoding currently implemented"); |
| 334 | } |
| 335 | |
| 336 | auto encoder = MakeTypedEncoder<BooleanType>(Encoding::PLAIN, false, d); |
| 337 | dynamic_cast<BooleanEncoder*>(encoder.get()) |
| 338 | ->Put(values, static_cast<int>(values.size())); |
| 339 | std::shared_ptr<Buffer> buffer = encoder->FlushValues(); |
| 340 | PARQUET_THROW_NOT_OK(sink_->Write(buffer->data(), buffer->size())); |
| 341 | |
| 342 | num_values_ = std::max(static_cast<int32_t>(values.size()), num_values_); |
| 343 | encoding_ = encoding; |
| 344 | have_values_ = true; |
| 345 | } |
| 346 | |
| 347 | template <typename Type> |
| 348 | std::shared_ptr<DataPageV1> MakeDataPage( |
no test coverage detected