3#include <iron_query/expr.hpp>
4#include <iron_query/operator_precedence.hpp>
63 explicit Condition(std::shared_ptr<const impl::Node> node);
65 std::shared_ptr<const impl::Node> node_;
A boolean-valued SQL predicate, e.g. the result of a comparison, LIKE/IN/BETWEEN/IS [NOT] NULL,...
Definition condition.hpp:25
Condition operator||(const Condition &other) const
this OR other.
Condition operator!() const
NOT this.
friend Condition operator>=(const Expr &a, const Expr &b)
a >= b.
friend Condition operator==(const Expr &a, const Expr &b)
a = b.
std::string Extract(OperatorPrecedence precedence) const
Renders the condition as SQL text, parenthesizing it if its top-level operator does not bind at least...
friend Condition operator<(const Expr &a, const Expr &b)
a < b.
friend Condition operator!=(const Expr &a, const Expr &b)
a != b.
Condition operator&&(const Condition &other) const
this AND other.
static Condition FromRaw(std::string s)
Wraps a trusted, developer-written SQL predicate verbatim. Never pass untrusted/dynamic data here.
friend Condition operator<=(const Expr &a, const Expr &b)
a <= b.
std::string ToString() const
Renders the condition as a standalone, unparenthesized SQL fragment.
friend Condition operator>(const Expr &a, const Expr &b)
a > b.
Arbitrary SQL expression.
Definition expr.hpp:46
OperatorPrecedence
Relative binding strength of SQL operators, used by iron_query::Expr::Extract to decide whether a sub...
Definition operator_precedence.hpp:10