OmniSciDB
a5dc49c757
|
#include <StringOpInfo.h>
Public Member Functions | |
StringOpInfo (const SqlStringOpKind op_kind, const SQLTypeInfo &return_ti, const LiteralArgMap &literal_arg_map) | |
const SqlStringOpKind & | getOpKind () const |
const LiteralArgMap & | getLiteralArgMap () const |
size_t | numLiterals () const |
bool | hasVarStringLiteral () const |
bool | intLiteralArgAtIdxExists (const size_t index) const |
bool | stringLiteralArgAtIdxExists (const size_t index) const |
size_t | numNonVariableLiterals () const |
const SQLTypeInfo & | getReturnType () const |
bool | hasNullLiteralArg () const |
std::string | getStringLiteral (const size_t index) const |
int64_t | getIntLiteral (const size_t index) const |
std::string | toString () const |
Static Private Member Functions | |
static bool | isLiteralArgNull (const SQLTypes datum_type, const Datum &datum) |
static size_t | calcNumNullLiteralArgs (const LiteralArgMap &literal_arg_map) |
Private Attributes | |
const SqlStringOpKind | op_kind_ |
const SQLTypeInfo | return_ti_ |
const LiteralArgMap | literal_arg_map_ |
const size_t | num_null_literals_ |
Friends | |
std::ostream & | operator<< (std::ostream &stream, const StringOpInfo &string_op_info) |
Definition at line 32 of file StringOpInfo.h.
|
inline |
Definition at line 34 of file StringOpInfo.h.
|
staticprivate |
Definition at line 135 of file StringOpInfo.cpp.
References isLiteralArgNull().
int64_t StringOps_Namespace::StringOpInfo::getIntLiteral | ( | const size_t | index | ) | const |
Definition at line 103 of file StringOpInfo.cpp.
References CHECK, extract_int_type_from_datum(), IS_INTEGER, isLiteralArgNull(), and literal_arg_map_.
Referenced by StringOps_Namespace::gen_string_op().
|
inline |
Definition at line 44 of file StringOpInfo.h.
References literal_arg_map_.
|
inline |
Definition at line 42 of file StringOpInfo.h.
References op_kind_.
Referenced by StringOps_Namespace::gen_string_op(), and StringOps_Namespace::operator<<().
|
inline |
Definition at line 58 of file StringOpInfo.h.
References return_ti_.
Referenced by StringOps_Namespace::gen_string_op(), and StringOps_Namespace::operator<<().
std::string StringOps_Namespace::StringOpInfo::getStringLiteral | ( | const size_t | index | ) | const |
Definition at line 94 of file StringOpInfo.cpp.
References CHECK, IS_STRING, isLiteralArgNull(), and literal_arg_map_.
Referenced by StringOps_Namespace::gen_string_op().
|
inline |
Definition at line 60 of file StringOpInfo.h.
References num_null_literals_.
Referenced by StringOps_Namespace::apply_string_op_to_literals(), and StringOps_Namespace::gen_string_op().
|
inline |
Definition at line 48 of file StringOpInfo.h.
References stringLiteralArgAtIdxExists().
Referenced by StringOps_Namespace::apply_numeric_op_to_literals(), StringOps_Namespace::apply_string_op_to_literals(), StringOps_Namespace::gen_string_op(), and numNonVariableLiterals().
bool StringOps_Namespace::StringOpInfo::intLiteralArgAtIdxExists | ( | const size_t | index | ) | const |
Definition at line 76 of file StringOpInfo.cpp.
References CHECK, IS_INTEGER, and literal_arg_map_.
Referenced by StringOps_Namespace::gen_string_op().
|
staticprivate |
Definition at line 120 of file StringOpInfo.cpp.
References Datum::bigintval, CHECK, IS_INTEGER, SQLTypeInfo::is_null(), IS_STRING, kNULLT, and Datum::stringval.
Referenced by calcNumNullLiteralArgs(), getIntLiteral(), getStringLiteral(), and StringOps_Namespace::operator<<().
|
inline |
Definition at line 46 of file StringOpInfo.h.
References literal_arg_map_.
Referenced by StringOps_Namespace::gen_string_op().
|
inline |
Definition at line 54 of file StringOpInfo.h.
References hasVarStringLiteral(), and literal_arg_map_.
Referenced by StringOps_Namespace::gen_string_op().
bool StringOps_Namespace::StringOpInfo::stringLiteralArgAtIdxExists | ( | const size_t | index | ) | const |
Definition at line 85 of file StringOpInfo.cpp.
References CHECK, IS_STRING, and literal_arg_map_.
Referenced by hasVarStringLiteral().
std::string StringOps_Namespace::StringOpInfo::toString | ( | ) | const |
Definition at line 114 of file StringOpInfo.cpp.
|
friend |
Definition at line 24 of file StringOpInfo.cpp.
|
private |
Definition at line 78 of file StringOpInfo.h.
Referenced by getIntLiteral(), getLiteralArgMap(), getStringLiteral(), intLiteralArgAtIdxExists(), numLiterals(), numNonVariableLiterals(), StringOps_Namespace::operator<<(), and stringLiteralArgAtIdxExists().
|
private |
Definition at line 79 of file StringOpInfo.h.
Referenced by hasNullLiteralArg().
|
private |
Definition at line 76 of file StringOpInfo.h.
Referenced by getOpKind().
|
private |
Definition at line 77 of file StringOpInfo.h.
Referenced by getReturnType().