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

Function WriteDictionaryMessage

cpp/src/arrow/ipc/metadata_internal.cc:1373–1387  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1371}
1372
1373Result<std::shared_ptr<Buffer>> WriteDictionaryMessage(
1374 int64_t id, bool is_delta, int64_t length, int64_t body_length,
1375 const std::shared_ptr<const KeyValueMetadata>& custom_metadata,
1376 const std::vector<FieldMetadata>& nodes, const std::vector<BufferMetadata>& buffers,
1377 const std::vector<int64_t>& variadic_buffer_counts, const IpcWriteOptions& options) {
1378 FBB fbb;
1379 RecordBatchOffset record_batch;
1380 RETURN_NOT_OK(MakeRecordBatch(fbb, length, body_length, nodes, buffers,
1381 variadic_buffer_counts, options, &record_batch));
1382 auto dictionary_batch =
1383 flatbuf::CreateDictionaryBatch(fbb, id, record_batch, is_delta).Union();
1384 return WriteFBMessage(fbb, flatbuf::MessageHeader::MessageHeader_DictionaryBatch,
1385 dictionary_batch, body_length, options.metadata_version,
1386 custom_metadata, options.memory_pool);
1387}
1388
1389static flatbuffers::Offset<flatbuffers::Vector<const flatbuf::Block*>>
1390FileBlocksToFlatbuffer(FBB& fbb, const std::vector<FileBlock>& blocks) {

Callers 1

SerializeMetadataMethod · 0.85

Calls 3

CreateDictionaryBatchFunction · 0.85
WriteFBMessageFunction · 0.85
MakeRecordBatchFunction · 0.70

Tested by

no test coverage detected