1 | //===----------------------------------------------------------------------===// |
---|---|
2 | // DuckDB |
3 | // |
4 | // duckdb/planner/operator/logical_projection.hpp |
5 | // |
6 | // |
7 | //===----------------------------------------------------------------------===// |
8 | |
9 | #pragma once |
10 | |
11 | #include "duckdb/planner/logical_operator.hpp" |
12 | |
13 | namespace duckdb { |
14 | |
15 | //! LogicalProjection represents the projection list in a SELECT clause |
16 | class LogicalProjection : public LogicalOperator { |
17 | public: |
18 | static constexpr const LogicalOperatorType TYPE = LogicalOperatorType::LOGICAL_PROJECTION; |
19 | |
20 | public: |
21 | LogicalProjection(idx_t table_index, vector<unique_ptr<Expression>> select_list); |
22 | |
23 | idx_t table_index; |
24 | |
25 | public: |
26 | vector<ColumnBinding> GetColumnBindings() override; |
27 | void Serialize(FieldWriter &writer) const override; |
28 | static unique_ptr<LogicalOperator> Deserialize(LogicalDeserializationState &state, FieldReader &reader); |
29 | vector<idx_t> GetTableIndex() const override; |
30 | string GetName() const override; |
31 | |
32 | protected: |
33 | void ResolveTypes() override; |
34 | }; |
35 | } // namespace duckdb |
36 |