OmniSciDB  c0231cc57d
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
ColumnVarsVisitor Class Reference

#include <QueryPlanDagCache.h>

+ Inheritance diagram for ColumnVarsVisitor:
+ Collaboration diagram for ColumnVarsVisitor:

Protected Member Functions

std::vector< const
Analyzer::ColumnVar * > 
visitColumnVar (const Analyzer::ColumnVar *column) const override
 
std::vector< const
Analyzer::ColumnVar * > 
visitColumnVarTuple (const Analyzer::ExpressionTuple *expr_tuple) const override
 
std::vector< const
Analyzer::ColumnVar * > 
aggregateResult (const std::vector< const Analyzer::ColumnVar * > &aggregate, const std::vector< const Analyzer::ColumnVar * > &next_result) const override
 
- Protected Member Functions inherited from ScalarExprVisitor< std::vector< const Analyzer::ColumnVar * > >
virtual std::vector< const
Analyzer::ColumnVar * > 
visitVar (const Analyzer::Var *) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitConstant (const Analyzer::Constant *) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitUOper (const Analyzer::UOper *uoper) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitBinOper (const Analyzer::BinOper *bin_oper) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitGeoExpr (const Analyzer::GeoExpr *geo_expr) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitInValues (const Analyzer::InValues *in_values) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitInIntegerSet (const Analyzer::InIntegerSet *in_integer_set) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitCharLength (const Analyzer::CharLengthExpr *char_length) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitKeyForString (const Analyzer::KeyForStringExpr *key_for_string) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitSampleRatio (const Analyzer::SampleRatioExpr *sample_ratio) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitStringOper (const Analyzer::StringOper *string_oper) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitCardinality (const Analyzer::CardinalityExpr *cardinality) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitLikeExpr (const Analyzer::LikeExpr *like) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitRegexpExpr (const Analyzer::RegexpExpr *regexp) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitWidthBucket (const Analyzer::WidthBucketExpr *width_bucket_expr) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitCaseExpr (const Analyzer::CaseExpr *case_) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitDatetruncExpr (const Analyzer::DatetruncExpr *datetrunc) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitExtractExpr (const Analyzer::ExtractExpr *extract) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitFunctionOperWithCustomTypeHandling (const Analyzer::FunctionOperWithCustomTypeHandling *func_oper) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitArrayOper (Analyzer::ArrayExpr const *array_expr) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitGeoUOper (const Analyzer::GeoUOper *geo_expr) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitGeoBinOper (const Analyzer::GeoBinOper *geo_expr) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitFunctionOper (const Analyzer::FunctionOper *func_oper) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitWindowFunction (const Analyzer::WindowFunction *window_func) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitDatediffExpr (const Analyzer::DatediffExpr *datediff) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitDateaddExpr (const Analyzer::DateaddExpr *dateadd) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitLikelihood (const Analyzer::LikelihoodExpr *likelihood) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitOffsetInFragment (const Analyzer::OffsetInFragment *) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitAggExpr (const Analyzer::AggExpr *agg) const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
visitRangeJoinOper (const Analyzer::RangeOper *range_oper) const
 
virtual void visitBegin () const
 
virtual std::vector< const
Analyzer::ColumnVar * > 
defaultResult () const
 

Additional Inherited Members

- Public Member Functions inherited from ScalarExprVisitor< std::vector< const Analyzer::ColumnVar * > >
std::vector< const
Analyzer::ColumnVar * > 
visit (const Analyzer::Expr *expr) const
 

Detailed Description

Definition at line 43 of file QueryPlanDagCache.h.

Member Function Documentation

std::vector<const Analyzer::ColumnVar*> ColumnVarsVisitor::aggregateResult ( const std::vector< const Analyzer::ColumnVar * > &  aggregate,
const std::vector< const Analyzer::ColumnVar * > &  next_result 
) const
inlineoverrideprotectedvirtual

Reimplemented from ScalarExprVisitor< std::vector< const Analyzer::ColumnVar * > >.

Definition at line 64 of file QueryPlanDagCache.h.

References run_benchmark_import::result.

66  {
67  auto result = aggregate;
68  for (const auto col_var : next_result) {
69  result.push_back(col_var);
70  }
71  return result;
72  }
std::vector<const Analyzer::ColumnVar*> ColumnVarsVisitor::visitColumnVar ( const Analyzer::ColumnVar column) const
inlineoverrideprotectedvirtual

Reimplemented from ScalarExprVisitor< std::vector< const Analyzer::ColumnVar * > >.

Definition at line 46 of file QueryPlanDagCache.h.

47  {
48  return {column};
49  }
std::vector<const Analyzer::ColumnVar*> ColumnVarsVisitor::visitColumnVarTuple ( const Analyzer::ExpressionTuple expr_tuple) const
inlineoverrideprotectedvirtual

Reimplemented from ScalarExprVisitor< std::vector< const Analyzer::ColumnVar * > >.

Definition at line 51 of file QueryPlanDagCache.h.

References Analyzer::ExpressionTuple::getTuple(), run_benchmark_import::result, and ScalarExprVisitor< T >::visit().

52  {
53  ColumnVarsVisitor visitor;
54  std::vector<const Analyzer::ColumnVar*> result;
55  for (size_t i = 0; i < expr_tuple->getTuple().size(); ++i) {
56  const auto col_vars = visitor.visit(expr_tuple->getTuple()[i].get());
57  for (const auto col_var : col_vars) {
58  result.push_back(col_var);
59  }
60  }
61  return result;
62  }
T visit(const Analyzer::Expr *expr) const
const std::vector< std::shared_ptr< Analyzer::Expr > > & getTuple() const
Definition: Analyzer.h:252

+ Here is the call graph for this function:


The documentation for this class was generated from the following file: