| 1 | #pragma once | 
|---|---|
| 2 | |
| 3 | #include <Interpreters/IInterpreter.h> | 
| 4 | #include <Parsers/IAST_fwd.h> | 
| 5 | |
| 6 | |
| 7 | namespace DB | 
| 8 | { | 
| 9 | |
| 10 | class Context; | 
| 11 | |
| 12 | |
| 13 | /** Just call method "optimize" for table. | 
| 14 | */ | 
| 15 | class InterpreterOptimizeQuery : public IInterpreter | 
| 16 | { | 
| 17 | public: | 
| 18 | InterpreterOptimizeQuery(const ASTPtr & query_ptr_, Context & context_) | 
| 19 | : query_ptr(query_ptr_), context(context_) | 
| 20 | { | 
| 21 | } | 
| 22 | |
| 23 | BlockIO execute() override; | 
| 24 | |
| 25 | private: | 
| 26 | ASTPtr query_ptr; | 
| 27 | Context & context; | 
| 28 | }; | 
| 29 | |
| 30 | |
| 31 | } | 
| 32 | 
