1 | //===----------------------------------------------------------------------===// |
---|---|
2 | // DuckDB |
3 | // |
4 | // duckdb/main/relation/table_relation.hpp |
5 | // |
6 | // |
7 | //===----------------------------------------------------------------------===// |
8 | |
9 | #pragma once |
10 | |
11 | #include "duckdb/main/relation.hpp" |
12 | #include "duckdb/main/table_description.hpp" |
13 | |
14 | namespace duckdb { |
15 | |
16 | class TableRelation : public Relation { |
17 | public: |
18 | TableRelation(const std::shared_ptr<ClientContext> &context, unique_ptr<TableDescription> description); |
19 | |
20 | unique_ptr<TableDescription> description; |
21 | |
22 | public: |
23 | unique_ptr<QueryNode> GetQueryNode() override; |
24 | |
25 | const vector<ColumnDefinition> &Columns() override; |
26 | string ToString(idx_t depth) override; |
27 | string GetAlias() override; |
28 | |
29 | unique_ptr<TableRef> GetTableRef() override; |
30 | |
31 | void Update(const string &update, const string &condition = string()) override; |
32 | void Delete(const string &condition = string()) override; |
33 | }; |
34 | |
35 | } // namespace duckdb |
36 |