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

Function vec_to_arrow_Array

r/src/r_to_arrow.cpp:1337–1345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1335}
1336
1337std::shared_ptr<arrow::Array> vec_to_arrow_Array(
1338 SEXP x, const std::shared_ptr<arrow::DataType>& type, bool type_inferred) {
1339 auto chunked_array = vec_to_arrow_ChunkedArray(x, type, type_inferred);
1340 if (chunked_array->num_chunks() == 1) {
1341 return chunked_array->chunk(0);
1342 }
1343
1344 return ValueOrStop(arrow::Concatenate(chunked_array->chunks()));
1345}
1346
1347// TODO: most of this is very similar to MakeSimpleArray, just adapted to
1348// leverage concurrency. Maybe some refactoring needed.

Callers 3

CollectRecordBatchArraysFunction · 0.85
vec_to_ArrayFunction · 0.85

Calls 5

ValueOrStopFunction · 0.85
ConcatenateFunction · 0.85
num_chunksMethod · 0.45
chunksMethod · 0.45

Tested by

no test coverage detected