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

Function MakeChunker

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

Source from the content-addressed store, hash-verified

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