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

Function RecordBatch__ReplaceSchemaMetadata

r/src/recordbatch.cpp:62–69  ·  view source on GitHub ↗

[[arrow::export]]

Source from the content-addressed store, hash-verified

60
61// [[arrow::export]]
62std::shared_ptr<arrow::RecordBatch> RecordBatch__ReplaceSchemaMetadata(
63 const std::shared_ptr<arrow::RecordBatch>& x, cpp11::strings metadata) {
64 auto vec_metadata = cpp11::as_cpp<std::vector<std::string>>(metadata);
65 auto names_metadata = cpp11::as_cpp<std::vector<std::string>>(metadata.names());
66 auto kv = std::shared_ptr<arrow::KeyValueMetadata>(
67 new arrow::KeyValueMetadata(names_metadata, vec_metadata));
68 return x->ReplaceSchemaMetadata(kv);
69}
70
71// [[arrow::export]]
72cpp11::list RecordBatch__columns(const std::shared_ptr<arrow::RecordBatch>& batch) {

Calls 1

ReplaceSchemaMetadataMethod · 0.45

Tested by

no test coverage detected