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

Function MakeStreamingReader

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

Source from the content-addressed store, hash-verified

1128}
1129
1130Future<std::shared_ptr<StreamingReader>> MakeStreamingReader(
1131 io::IOContext io_context, std::shared_ptr<io::InputStream> input,
1132 Executor* cpu_executor, const ReadOptions& read_options,
1133 const ParseOptions& parse_options, const ConvertOptions& convert_options) {
1134 RETURN_NOT_OK(parse_options.Validate());
1135 RETURN_NOT_OK(read_options.Validate());
1136 RETURN_NOT_OK(convert_options.Validate());
1137 std::shared_ptr<StreamingReaderImpl> reader;
1138 reader = std::make_shared<StreamingReaderImpl>(
1139 io_context, input, read_options, parse_options, convert_options,
1140 /*count_rows=*/!read_options.use_threads || cpu_executor->GetCapacity() == 1);
1141 return reader->Init(cpu_executor).Then([reader] {
1142 return std::dynamic_pointer_cast<StreamingReader>(reader);
1143 });
1144}
1145
1146/////////////////////////////////////////////////////////////////////////
1147// Row count implementation

Callers 2

MakeMethod · 0.85
MakeAsyncMethod · 0.85

Calls 4

ThenMethod · 0.80
ValidateMethod · 0.45
GetCapacityMethod · 0.45
InitMethod · 0.45

Tested by

no test coverage detected