Class ArrowResultSet

class ArrowResultSet

Public Functions

ArrowResultSet(const std::shared_ptr<ResultSet> &rows, const std::vector<TargetMetaInfo> &targets_meta, const ExecutorDeviceType device_type = ExecutorDeviceType::CPU)
ArrowResultSet(const std::shared_ptr<ResultSet> &rows, const std::vector<TargetMetaInfo> &targets_meta, const ExecutorDeviceType device_type, const size_t min_result_size_for_bulk_dictionary_fetch, const double max_dictionary_to_result_size_ratio_for_bulk_dictionary_fetch)
ArrowResultSet(const std::shared_ptr<ResultSet> &rows, const ExecutorDeviceType device_type = ExecutorDeviceType::CPU)
std::vector<TargetValue> getRowAt(const size_t index) const
std::vector<TargetValue> getNextRow(const bool translate_strings, const bool decimal_to_double) const
size_t colCount() const
SQLTypeInfo getColType(const size_t col_idx) const
bool definitelyHasNoRows() const
size_t rowCount() const
size_t entryCount() const
bool isEmpty() const

Public Members

ArrowResultSet::device_type{}ArrowResultSetRowIterator rowIterator(size_t from_index, bool translate_strings, bool decimal_to_double) const {ArrowResultSetRowIterator iter(this); for (size_t i = 0; i < from_index; i++) { ++iter; } return iter; }ArrowResultSetRowIterator rowIterator(bool translate_strings, bool decimal_to_double) const { return rowIterator(0, translate_strings, decimal_to_double); } std::vector<std::string> getDictionaryStrings(const size_t col_idx) const

Public Static Functions

void deallocateArrowResultBuffer(const ArrowResult &result, const ExecutorDeviceType device_type, const size_t device_id, std::shared_ptr<Data_Namespace::DataMgr> &data_mgr)

Private Functions

void resultSetArrowLoopback(const ExecutorDeviceType device_type = ExecutorDeviceType::CPU)
void resultSetArrowLoopback(const ExecutorDeviceType device_type, const size_t min_result_size_for_bulk_dictionary_fetch, const double max_dictionary_to_result_size_ratio_for_bulk_dictionary_fetch)
template<typename Type, typename ArrayType>
void appendValue(std::vector<TargetValue> &row, const arrow::Array &column, const Type null_val, const size_t idx) const

Private Members

std::shared_ptr<ArrowResult> results_
std::shared_ptr<ResultSet> rows_
std::vector<TargetMetaInfo> targets_meta_
std::shared_ptr<arrow::RecordBatch> record_batch_
arrow::ipc::DictionaryMemo dictionary_memo_
std::vector<std::shared_ptr<arrow::Array>> columns_
size_t crt_row_idx_
std::vector<TargetMetaInfo> column_metainfo_