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

Method WriteTable

cpp/src/arrow/ipc/writer.cc:1157–1174  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1155}
1156
1157Status RecordBatchWriter::WriteTable(const Table& table, int64_t max_chunksize) {
1158 TableBatchReader reader(table);
1159
1160 if (max_chunksize > 0) {
1161 reader.set_chunksize(max_chunksize);
1162 }
1163
1164 std::shared_ptr<RecordBatch> batch;
1165 while (true) {
1166 RETURN_NOT_OK(reader.ReadNext(&batch));
1167 if (batch == nullptr) {
1168 break;
1169 }
1170 RETURN_NOT_OK(WriteRecordBatch(*batch));
1171 }
1172
1173 return Status::OK();
1174}
1175
1176Status RecordBatchWriter::WriteTable(const Table& table) { return WriteTable(table, -1); }
1177

Callers 14

WriteMethod · 0.45
WriteIpcDataFunction · 0.45
WriteIpcDataFunction · 0.45
WriteTableFunction · 0.45
ARROW_ASSIGN_OR_RAISEFunction · 0.45
WriteInBatchesFunction · 0.45
GenInitialFileFunction · 0.45
RunMainFunction · 0.45
RunMainFunction · 0.45
writeTableMethod · 0.45

Calls 5

set_chunksizeMethod · 0.80
WriteRecordBatchFunction · 0.70
WriteTableFunction · 0.70
OKFunction · 0.50
ReadNextMethod · 0.45

Tested by 2

WriteIpcDataFunction · 0.36
WriteIpcDataFunction · 0.36