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

Function MakeChunker

cpp/src/arrow/csv/chunker.cc:374–398  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

372} // namespace
373
374std::unique_ptr<Chunker> MakeChunker(const ParseOptions& options) {
375 std::shared_ptr<BoundaryFinder> delimiter;
376 if (!options.newlines_in_values) {
377 delimiter = MakeNewlineBoundaryFinder();
378 } else {
379 if (options.quoting) {
380 if (options.escaping) {
381 delimiter = std::make_shared<
382 LexingBoundaryFinder<internal::SpecializedOptions<true, true>>>(options);
383 } else {
384 delimiter = std::make_shared<
385 LexingBoundaryFinder<internal::SpecializedOptions<true, false>>>(options);
386 }
387 } else {
388 if (options.escaping) {
389 delimiter = std::make_shared<
390 LexingBoundaryFinder<internal::SpecializedOptions<false, true>>>(options);
391 } else {
392 delimiter = std::make_shared<
393 LexingBoundaryFinder<internal::SpecializedOptions<false, false>>>(options);
394 }
395 }
396 }
397 return std::make_unique<Chunker>(std::move(delimiter));
398}
399
400} // namespace csv
401} // namespace arrow

Callers 10

MakeChunkerMethod · 0.70
AssertSkipMethod · 0.70
TEST_PFunction · 0.70
InitAfterFirstBufferMethod · 0.70
ReadMethod · 0.70
ReadAsyncMethod · 0.70
InitMethod · 0.70
BenchmarkCSVChunkingFunction · 0.70
ConvertPySequenceFunction · 0.50
ParseToStructTypeFunction · 0.50

Calls 1

Tested by 3

MakeChunkerMethod · 0.56
AssertSkipMethod · 0.56
TEST_PFunction · 0.56