OmniSciDB
a5dc49c757
|
#include <cstdlib>
#include <ctime>
#include <map>
#include <mutex>
#include <arrow/api.h>
#include <arrow/io/api.h>
#include <boost/algorithm/string.hpp>
#include <boost/variant.hpp>
#include "Shared/SqlTypesLayout.h"
#include "Shared/ThreadController.h"
#include "Shared/sqltypes.h"
#include "arrow/util/decimal.h"
Go to the source code of this file.
Namespaces | |
anonymous_namespace{ArrowImporter.h} | |
Macros | |
#define | exprtype(expr) std::decay_t<decltype(expr)> |
#define | NUMERIC_CASE(tid, src_type, var_type) |
#define | STRING_CASE(tid, src_type) |
Typedefs | |
using | anonymous_namespace{ArrowImporter.h}::VarValue = boost::variant< bool, float, double, int64_t, std::string, void *, arrow::Decimal128 > |
template<typename T > | |
using | anonymous_namespace{ArrowImporter.h}::enable_if_integral = typename std::enable_if_t< std::is_integral< T >::value, T > |
template<typename T > | |
using | anonymous_namespace{ArrowImporter.h}::enable_if_integral_not_bool = typename std::enable_if_t< std::is_integral< T >::value &&!std::is_same< T, bool >::value, T > |
template<typename T > | |
using | anonymous_namespace{ArrowImporter.h}::enable_if_floating = typename std::enable_if_t< std::is_floating_point< T >::value, T > |
Functions | |
template<typename T = ArrowImporterException> | |
void | arrow_throw_if (const bool cond, const std::string &message) |
std::string | anonymous_namespace{ArrowImporter.h}::error_context (const ColumnDescriptor *cd, import_export::BadRowsTracker *const bad_rows_tracker) |
template<typename SrcType , typename DstType > | |
VarValue | anonymous_namespace{ArrowImporter.h}::get_numeric_value (const arrow::Array &array, const int64_t idx) |
template<typename SrcType > | |
VarValue | anonymous_namespace{ArrowImporter.h}::get_string_value (const arrow::Array &array, const int64_t idx) |
auto | anonymous_namespace{ArrowImporter.h}::value_getter (const arrow::Array &array, const ColumnDescriptor *cd, import_export::BadRowsTracker *const bad_rows_tracker) |
void | anonymous_namespace{ArrowImporter.h}::type_conversion_error (const std::string pt, const ColumnDescriptor *cd, import_export::BadRowsTracker *const bad_rows_tracker) |
template<typename DATA_TYPE , typename VALUE_TYPE > | |
void | anonymous_namespace{ArrowImporter.h}::data_conversion_error (const VALUE_TYPE v, const ColumnDescriptor *cd, import_export::BadRowsTracker *const bad_rows_tracker) |
void | anonymous_namespace{ArrowImporter.h}::data_conversion_error (const std::string &v, const ColumnDescriptor *cd, import_export::BadRowsTracker *const bad_rows_tracker) |
template<typename DATA_TYPE > | |
auto & | anonymous_namespace{ArrowImporter.h}::operator<< (DataBuffer< DATA_TYPE > &data, const VarValue &var) |
Variables | |
constexpr int64_t | anonymous_namespace{ArrowImporter.h}::kMillisecondsInSecond = 1000LL |
constexpr int64_t | anonymous_namespace{ArrowImporter.h}::kMicrosecondsInSecond = 1000LL * 1000LL |
constexpr int64_t | anonymous_namespace{ArrowImporter.h}::kNanosecondsinSecond = 1000LL * 1000LL * 1000LL |
constexpr int32_t | anonymous_namespace{ArrowImporter.h}::kSecondsInDay = 86400 |
static const std::map < std::pair< int32_t, arrow::TimeUnit::type > , std::pair< SQLOps, int64_t > > | anonymous_namespace{ArrowImporter.h}::_precision_scale_lookup |
#define exprtype | ( | expr | ) | std::decay_t<decltype(expr)> |
Definition at line 75 of file ArrowImporter.h.
Referenced by anonymous_namespace{ArrowImporter.h}::operator<<().
#define NUMERIC_CASE | ( | tid, | |
src_type, | |||
var_type | |||
) |
Definition at line 97 of file ArrowImporter.h.
Referenced by anonymous_namespace{ArrowImporter.h}::value_getter().
#define STRING_CASE | ( | tid, | |
src_type | |||
) |
Definition at line 100 of file ArrowImporter.h.
Referenced by anonymous_namespace{ArrowImporter.h}::value_getter().
|
inline |
Definition at line 42 of file ArrowImporter.h.
References logger::ERROR, LOG, and heavydb.dtypes::T.
Referenced by import_export::TypedImportBuffer::add_arrow_values(), anonymous_namespace{ArrowImporter.h}::ArrowValue< arrow::Decimal128 >::ArrowValue(), anonymous_namespace{ArrowImporter.h}::data_conversion_error(), anonymous_namespace{ArrowImporter.h}::type_conversion_error(), and anonymous_namespace{ArrowImporter.h}::value_getter().