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

Method Begin

cpp/src/arrow/flight/transport_server.cc:215–228  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

213 ipc_options_(::arrow::ipc::IpcWriteOptions::Defaults()) {}
214
215 Status Begin(const std::shared_ptr<Schema>& schema,
216 const ipc::IpcWriteOptions& options) override {
217 if (batch_writer_) {
218 return Status::Invalid("This writer has already been started.");
219 }
220 ipc_options_ = options;
221 std::unique_ptr<ipc::internal::IpcPayloadWriter> payload_writer(
222 new TransportMessagePayloadWriter(stream_, &app_metadata_));
223
224 ARROW_ASSIGN_OR_RAISE(batch_writer_,
225 ipc::internal::OpenRecordBatchWriter(std::move(payload_writer),
226 schema, ipc_options_));
227 return Status::OK();
228 }
229
230 Status WriteRecordBatch(const RecordBatch& batch) override {
231 return WriteWithMetadata(batch, nullptr);

Callers

nothing calls this directly

Calls 4

OpenRecordBatchWriterFunction · 0.85
ARROW_ASSIGN_OR_RAISEFunction · 0.70
InvalidFunction · 0.50
OKFunction · 0.50

Tested by

no test coverage detected