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

Function GetKeyValueMetadata

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

Source from the content-addressed store, hash-verified

1281} // namespace
1282
1283Result<std::shared_ptr<KeyValueMetadata>> GetKeyValueMetadata(
1284 const KVVector* fb_metadata) {
1285 if (fb_metadata == nullptr) {
1286 return nullptr;
1287 }
1288
1289 auto metadata = std::make_shared<KeyValueMetadata>();
1290
1291 metadata->reserve(fb_metadata->size());
1292 for (const auto pair : *fb_metadata) {
1293 CHECK_FLATBUFFERS_NOT_NULL(pair->key(), "custom_metadata.key");
1294 CHECK_FLATBUFFERS_NOT_NULL(pair->value(), "custom_metadata.value");
1295 metadata->Append(pair->key()->str(), pair->value()->str());
1296 }
1297
1298 return metadata;
1299}
1300
1301Result<std::shared_ptr<Buffer>> WriteSchemaMessage(const Schema& schema,
1302 const DictionaryFieldMapper& mapper,

Callers 8

ARROW_ASSIGN_OR_RAISEFunction · 0.85
ReadRecordBatchInternalFunction · 0.85
ReadFooterAsyncMethod · 0.85
OpenMethod · 0.85
FieldFromFlatbufferFunction · 0.85
GetSchemaFunction · 0.85

Calls 6

strMethod · 0.80
reserveMethod · 0.45
sizeMethod · 0.45
keyMethod · 0.45
valueMethod · 0.45
AppendMethod · 0.45

Tested by

no test coverage detected