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

Method MakeColumnDecoders

cpp/src/arrow/csv/reader.cc:535–553  ·  view source on GitHub ↗

Make column decoders from conversion schema

Source from the content-addressed store, hash-verified

533
534 // Make column decoders from conversion schema
535 Status MakeColumnDecoders(io::IOContext io_context) {
536 for (const auto& column : conversion_schema.columns) {
537 std::shared_ptr<ColumnDecoder> decoder;
538 if (column.is_missing) {
539 ARROW_ASSIGN_OR_RAISE(decoder,
540 ColumnDecoder::MakeNull(io_context.pool(), column.type));
541 } else if (column.type != nullptr) {
542 ARROW_ASSIGN_OR_RAISE(
543 decoder, ColumnDecoder::Make(io_context.pool(), column.type, column.index,
544 convert_options));
545 } else {
546 ARROW_ASSIGN_OR_RAISE(
547 decoder,
548 ColumnDecoder::Make(io_context.pool(), column.index, convert_options));
549 }
550 column_decoders.push_back(std::move(decoder));
551 }
552 return Status::OK();
553 }
554
555 ConvertOptions convert_options;
556 ConversionSchema conversion_schema;

Callers 1

MakeMethod · 0.80

Calls 6

MakeNullFunction · 0.85
push_backMethod · 0.80
ARROW_ASSIGN_OR_RAISEFunction · 0.50
MakeFunction · 0.50
OKFunction · 0.50
poolMethod · 0.45

Tested by

no test coverage detected