OmniSciDB  16c4e035a1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
table_functions::anonymous_namespace{TableFunctionsFactory.cpp} Namespace Reference

Functions

SQLTypeInfo ext_arg_pointer_type_to_type_info (const ExtArgumentType ext_arg_type)
 
SQLTypeInfo ext_arg_type_to_type_info_output (const ExtArgumentType ext_arg_type)
 
std::string drop_suffix_impl (const std::string &str)
 

Function Documentation

std::string table_functions::anonymous_namespace{TableFunctionsFactory.cpp}::drop_suffix_impl ( const std::string &  str)

Definition at line 400 of file TableFunctionsFactory.cpp.

References CHECK_GT.

Referenced by table_functions::TableFunctionsFactory::get_table_funcs(), and table_functions::TableFunction::getName().

400  {
401  const auto idx = str.find("__");
402  if (idx == std::string::npos) {
403  return str;
404  }
405  CHECK_GT(idx, std::string::size_type(0));
406  return str.substr(0, idx);
407 }
#define CHECK_GT(x, y)
Definition: Logger.h:223

+ Here is the caller graph for this function:

SQLTypeInfo table_functions::anonymous_namespace{TableFunctionsFactory.cpp}::ext_arg_pointer_type_to_type_info ( const ExtArgumentType  ext_arg_type)

Definition at line 30 of file TableFunctionsFactory.cpp.

References ColumnBool, ColumnDouble, ColumnFloat, ColumnInt16, ColumnInt32, ColumnInt64, ColumnInt8, ColumnListBool, ColumnListDouble, ColumnListFloat, ColumnListInt16, ColumnListInt32, ColumnListInt64, ColumnListInt8, generate_column_list_type(), generate_column_type(), kBIGINT, kBOOLEAN, kDOUBLE, kFLOAT, kINT, kNULLT, kSMALLINT, kTINYINT, LOG, PBool, PDouble, PFloat, PInt16, PInt32, PInt64, PInt8, ExtensionFunctionsWhitelist::toString(), UNREACHABLE, and logger::WARNING.

Referenced by table_functions::TableFunction::getInputSQLType().

30  {
31  switch (ext_arg_type) {
33  return SQLTypeInfo(kTINYINT, false);
35  return SQLTypeInfo(kSMALLINT, false);
37  return SQLTypeInfo(kINT, false);
39  return SQLTypeInfo(kBIGINT, false);
41  return SQLTypeInfo(kFLOAT, false);
43  return SQLTypeInfo(kDOUBLE, false);
45  return SQLTypeInfo(kBOOLEAN, false);
51  return generate_column_type(kINT);
74  default:
75  LOG(WARNING) << "ext_arg_pointer_type_to_type_info: ExtArgumentType `"
77  << "` conversion to SQLTypeInfo not implemented.";
78  UNREACHABLE();
79  }
80  UNREACHABLE();
81  return SQLTypeInfo(kNULLT, false);
82 }
#define LOG(tag)
Definition: Logger.h:205
auto generate_column_type(const SQLTypes subtype)
Definition: sqltypes.h:1101
#define UNREACHABLE()
Definition: Logger.h:255
auto generate_column_list_type(const SQLTypes subtype)
Definition: sqltypes.h:1115
static std::string toString(const std::vector< ExtensionFunction > &ext_funcs, std::string tab="")
Definition: sqltypes.h:45

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

SQLTypeInfo table_functions::anonymous_namespace{TableFunctionsFactory.cpp}::ext_arg_type_to_type_info_output ( const ExtArgumentType  ext_arg_type)

Definition at line 84 of file TableFunctionsFactory.cpp.

References Bool, ColumnBool, ColumnDouble, ColumnFloat, ColumnInt16, ColumnInt32, ColumnInt64, ColumnInt8, ColumnListBool, ColumnListDouble, ColumnListFloat, ColumnListInt16, ColumnListInt32, ColumnListInt64, ColumnListInt8, ColumnListTextEncodingDict, ColumnTextEncodingDict, Double, Float, Int16, Int32, Int64, Int8, kBIGINT, kBOOLEAN, kDOUBLE, kENCODING_DICT, kFLOAT, kINT, kNULLT, kSMALLINT, kTEXT, kTINYINT, LOG, PBool, PDouble, PFloat, PInt16, PInt32, PInt64, PInt8, TextEncodingDict, ExtensionFunctionsWhitelist::toString(), UNREACHABLE, and logger::WARNING.

Referenced by table_functions::TableFunction::getOutputSQLType().

84  {
85  switch (ext_arg_type) {
90  return SQLTypeInfo(kTINYINT, false);
95  return SQLTypeInfo(kSMALLINT, false);
100  return SQLTypeInfo(kINT, false);
105  return SQLTypeInfo(kBIGINT, false);
110  return SQLTypeInfo(kFLOAT, false);
115  return SQLTypeInfo(kDOUBLE, false);
120  return SQLTypeInfo(kBOOLEAN, false);
124  return SQLTypeInfo(kTEXT, false, kENCODING_DICT);
125  default:
126  LOG(WARNING) << "ext_arg_pointer_type_to_type_info: ExtArgumentType `"
128  << "` conversion to SQLTypeInfo not implemented.";
129  UNREACHABLE();
130  }
131  UNREACHABLE();
132  return SQLTypeInfo(kNULLT, false);
133 }
#define LOG(tag)
Definition: Logger.h:205
#define UNREACHABLE()
Definition: Logger.h:255
Definition: sqltypes.h:52
static std::string toString(const std::vector< ExtensionFunction > &ext_funcs, std::string tab="")
Definition: sqltypes.h:45

+ Here is the call graph for this function:

+ Here is the caller graph for this function: