OmniSciDB  06b3bd477c
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ArrowResultSet.cpp File Reference
#include "QueryEngine/ArrowResultSet.h"
#include <arrow/api.h>
#include <arrow/io/memory.h>
#include <arrow/ipc/api.h>
#include "QueryEngine/Descriptors/RelAlgExecutionDescriptor.h"
#include "Shared/ArrowUtil.h"
+ Include dependency graph for ArrowResultSet.cpp:

Go to the source code of this file.




SQLTypeInfo anonymous_namespace{ArrowResultSet.cpp}::type_from_arrow_field (const arrow::Field &field)
std::unique_ptr< ArrowResultSetresult_set_arrow_loopback (const ExecutionResult &results)
std::unique_ptr< ArrowResultSetresult_set_arrow_loopback (const ExecutionResult *results, const std::shared_ptr< ResultSet > &rows)

Function Documentation

std::unique_ptr<ArrowResultSet> result_set_arrow_loopback ( const ExecutionResult results)

Definition at line 256 of file ArrowResultSet.cpp.

References ExecutionResult::getRows(), and ExecutionResult::getTargetsMeta().

257  {
258  // NOTE(wesm): About memory ownership
260  // After calling ReadRecordBatch, the buffers inside arrow::RecordBatch now
261  // share ownership of the memory in serialized_arrow_output.records (zero
262  // copy). Not necessary to retain these buffers. Same is true of any
263  // dictionaries contained in serialized_arrow_output.schema; the arrays
264  // reference that memory (zero copy).
265  return std::make_unique<ArrowResultSet>(results.getRows(), results.getTargetsMeta());
266 }
const std::vector< TargetMetaInfo > & getTargetsMeta() const
const std::shared_ptr< ResultSet > & getRows() const

+ Here is the call graph for this function:

std::unique_ptr<ArrowResultSet> result_set_arrow_loopback ( const ExecutionResult results,
const std::shared_ptr< ResultSet > &  rows 

Definition at line 268 of file ArrowResultSet.cpp.

References ExecutionResult::getTargetsMeta().

270  {
271  return results ? std::make_unique<ArrowResultSet>(rows, results->getTargetsMeta())
272  : std::make_unique<ArrowResultSet>(rows);
273 }
const std::vector< TargetMetaInfo > & getTargetsMeta() const

+ Here is the call graph for this function: