OmniSciDB  c07336695a
ExtensionFunctionsWhitelist.cpp File Reference
#include "ExtensionFunctionsWhitelist.h"
#include <iostream>
#include "JsonAccessors.h"
#include "../Shared/StringTransform.h"
#include <boost/algorithm/string/join.hpp>
+ Include dependency graph for ExtensionFunctionsWhitelist.cpp:

Go to the source code of this file.




using SignatureMap = std::unordered_map< std::string, std::vector< ExtensionFunction > >


std::string anonymous_namespace{ExtensionFunctionsWhitelist.cpp}::serialize_type (const ExtArgumentType type)
SQLTypeInfo ext_arg_type_to_type_info (const ExtArgumentType ext_arg_type)
ExtArgumentType anonymous_namespace{ExtensionFunctionsWhitelist.cpp}::deserialize_type (const std::string &type_name)
std::string anonymous_namespace{ExtensionFunctionsWhitelist.cpp}::drop_suffix (const std::string &str)

Typedef Documentation

◆ SignatureMap

using SignatureMap = std::unordered_map<std::string, std::vector<ExtensionFunction> >

Definition at line 297 of file ExtensionFunctionsWhitelist.cpp.

Function Documentation

◆ ext_arg_type_to_type_info()

SQLTypeInfo ext_arg_type_to_type_info ( const ExtArgumentType  ext_arg_type)

Definition at line 153 of file ExtensionFunctionsWhitelist.cpp.

References Bool, Double, Float, Int16, Int32, Int64, Int8, kBIGINT, kBOOLEAN, kDOUBLE, kFLOAT, kINT, kNULLT, kSMALLINT, kTINYINT, LOG, anonymous_namespace{ExtensionFunctionsWhitelist.cpp}::serialize_type(), and logger::WARNING.

Referenced by bind_function(), CodeGenerator::codegenFunctionOperCastArgs(), ExtensionFunctionsWhitelist::get_ext_funcs(), and RelAlgTranslator::translateFunction().

153  {
154  /* This function is mostly used for scalar types.
155  For non-scalar types, NULL is returned as a placeholder.
156  */
157  switch (ext_arg_type) {
159  return SQLTypeInfo(kBOOLEAN, false);
161  return SQLTypeInfo(kTINYINT, false);
163  return SQLTypeInfo(kSMALLINT, false);
165  return SQLTypeInfo(kINT, false);
167  return SQLTypeInfo(kBIGINT, false);
169  return SQLTypeInfo(kFLOAT, false);
171  return SQLTypeInfo(kDOUBLE, false);
172  default:
173  LOG(WARNING) << "ExtArgumentType `" << serialize_type(ext_arg_type)
174  << "` cannot be converted to SQLTypeInfo. Returning nulltype.";
175  }
176  return SQLTypeInfo(kNULLT, false);
177 }
#define LOG(tag)
Definition: Logger.h:182
SQLTypeInfoCore< ArrayContextTypeSizer, ExecutorTypePackaging, DateTimeFacilities > SQLTypeInfo
Definition: sqltypes.h:819
Definition: sqltypes.h:47
+ Here is the call graph for this function:
+ Here is the caller graph for this function: