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

Method MakeRecordBatch

cpp/src/arrow/c/bridge.cc:1564–1579  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1562 }
1563
1564 Result<std::shared_ptr<RecordBatch>> MakeRecordBatch(std::shared_ptr<Schema> schema) {
1565 DCHECK_NE(data_, nullptr);
1566 if (data_->GetNullCount() != 0) {
1567 return Status::Invalid(
1568 "ArrowArray struct has non-zero null count, "
1569 "cannot be imported as RecordBatch");
1570 }
1571 if (data_->offset != 0) {
1572 return Status::Invalid(
1573 "ArrowArray struct has non-zero offset, "
1574 "cannot be imported as RecordBatch");
1575 }
1576 return RecordBatch::Make(std::move(schema), data_->length,
1577 std::move(data_->child_data), import_->device_type_,
1578 import_->device_sync_);
1579 }
1580
1581 Status ImportChild(const ArrayImporter* parent, struct ArrowArray* src) {
1582 if (ArrowArrayIsReleased(src)) {

Callers 2

ImportRecordBatchFunction · 0.80
ImportDeviceRecordBatchFunction · 0.80

Calls 3

GetNullCountMethod · 0.80
InvalidFunction · 0.50
MakeFunction · 0.50

Tested by

no test coverage detected