added criteria_evaluator and extended all criteria classes with missing methods
This commit is contained in:
@@ -13,6 +13,10 @@
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
|
||||
namespace matador::utils {
|
||||
class value;
|
||||
}
|
||||
|
||||
namespace matador::sql {
|
||||
|
||||
class connection_impl;
|
||||
@@ -53,6 +57,8 @@ public:
|
||||
|
||||
[[nodiscard]] const std::string& to_string(bool val) const;
|
||||
|
||||
[[nodiscard]] std::string to_sql_string(const utils::value &val) const ;
|
||||
|
||||
void bool_strings(const std::string &true_string, const std::string &false_string);
|
||||
|
||||
/**
|
||||
@@ -150,7 +156,10 @@ private:
|
||||
{dialect_token::WHERE, "WHERE"},
|
||||
{dialect_token::AND, "AND"},
|
||||
{dialect_token::OR, "OR"},
|
||||
{dialect_token::NOT, "NOT"},
|
||||
{dialect_token::LIKE, "LIKE"},
|
||||
{dialect_token::BETWEEN, "BETWEEN"},
|
||||
{dialect_token::IN, "IN"},
|
||||
{dialect_token::ORDER_BY, "ORDER BY"},
|
||||
{dialect_token::GROUP_BY, "GROUP BY"},
|
||||
{dialect_token::ASC, "ASC"},
|
||||
@@ -171,6 +180,8 @@ private:
|
||||
{dialect_token::STRING_QUOTE, "'"},
|
||||
{dialect_token::BEGIN_BINARY_DATA, "X'"},
|
||||
{dialect_token::END_BINARY_DATA, "'"},
|
||||
{dialect_token::BEGIN_STRING_DATA, "'"},
|
||||
{dialect_token::END_STRING_DATA, "'"},
|
||||
{dialect_token::NONE, ""}
|
||||
};
|
||||
|
||||
|
||||
@@ -28,7 +28,10 @@ enum class dialect_token : uint8_t {
|
||||
WHERE_CLAUSE,
|
||||
AND,
|
||||
OR,
|
||||
NOT,
|
||||
LIKE,
|
||||
BETWEEN,
|
||||
IN,
|
||||
ORDER_BY,
|
||||
GROUP_BY,
|
||||
ASC,
|
||||
@@ -49,6 +52,8 @@ enum class dialect_token : uint8_t {
|
||||
STRING_QUOTE,
|
||||
BEGIN_BINARY_DATA,
|
||||
END_BINARY_DATA,
|
||||
BEGIN_STRING_DATA,
|
||||
END_STRING_DATA,
|
||||
NONE
|
||||
};
|
||||
}
|
||||
|
||||
@@ -14,8 +14,7 @@ namespace matador::sql {
|
||||
|
||||
class sql_error;
|
||||
|
||||
class statement_impl
|
||||
{
|
||||
class statement_impl {
|
||||
protected:
|
||||
explicit statement_impl(query_context query, size_t start_bind_pos);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user