1//===----------------------------------------------------------------------===//
2// DuckDB
3//
4// duckdb/planner/expression/bound_comparison_expression.hpp
5//
6//
7//===----------------------------------------------------------------------===//
8
9#pragma once
10
11#include "duckdb/planner/expression.hpp"
12
13namespace duckdb {
14
15class BoundComparisonExpression : public Expression {
16public:
17 static constexpr const ExpressionClass TYPE = ExpressionClass::BOUND_COMPARISON;
18
19public:
20 BoundComparisonExpression(ExpressionType type, unique_ptr<Expression> left, unique_ptr<Expression> right);
21
22 unique_ptr<Expression> left;
23 unique_ptr<Expression> right;
24
25public:
26 string ToString() const override;
27
28 bool Equals(const BaseExpression &other) const override;
29
30 unique_ptr<Expression> Copy() override;
31 void Serialize(FieldWriter &writer) const override;
32 static unique_ptr<Expression> Deserialize(ExpressionDeserializationState &state, FieldReader &reader);
33
34public:
35 static LogicalType BindComparison(LogicalType left_type, LogicalType right_type);
36};
37} // namespace duckdb
38