OmniSciDB  c1a53651b2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Parser::UpdateStmt Class Reference

#include <ParserNode.h>

+ Inheritance diagram for Parser::UpdateStmt:
+ Collaboration diagram for Parser::UpdateStmt:

Public Member Functions

 UpdateStmt (std::string *t, std::list< Assignment * > *a, Expr *w)
 
const std::string * get_table () const
 
const std::list
< std::unique_ptr< Assignment > > & 
get_assignment_list () const
 
const Exprget_where_clause () const
 
void analyze (const Catalog_Namespace::Catalog &catalog, Analyzer::Query &query) const override
 
- Public Member Functions inherited from Parser::Node
virtual ~Node ()
 

Private Attributes

std::unique_ptr< std::string > table_
 
std::list< std::unique_ptr
< Assignment > > 
assignment_list_
 
std::unique_ptr< Exprwhere_clause_
 

Detailed Description

Definition at line 2122 of file ParserNode.h.

Constructor & Destructor Documentation

Parser::UpdateStmt::UpdateStmt ( std::string *  t,
std::list< Assignment * > *  a,
Expr w 
)
inline

Definition at line 2124 of file ParserNode.h.

References anonymous_namespace{Utm.h}::a, assignment_list_, and CHECK.

2125  : table_(t), where_clause_(w) {
2126  CHECK(a);
2127  for (const auto e : *a) {
2128  assignment_list_.emplace_back(e);
2129  }
2130  delete a;
2131  }
std::list< std::unique_ptr< Assignment > > assignment_list_
Definition: ParserNode.h:2142
std::unique_ptr< std::string > table_
Definition: ParserNode.h:2141
constexpr double a
Definition: Utm.h:32
std::unique_ptr< Expr > where_clause_
Definition: ParserNode.h:2143
#define CHECK(condition)
Definition: Logger.h:291

Member Function Documentation

void Parser::UpdateStmt::analyze ( const Catalog_Namespace::Catalog catalog,
Analyzer::Query query 
) const
overridevirtual

Implements Parser::DMLStmt.

Definition at line 2740 of file ParserNode.cpp.

2741  {
2742  throw std::runtime_error("UPDATE statement not supported yet.");
2743 }
const std::list<std::unique_ptr<Assignment> >& Parser::UpdateStmt::get_assignment_list ( ) const
inline

Definition at line 2133 of file ParserNode.h.

References assignment_list_.

2133  {
2134  return assignment_list_;
2135  }
std::list< std::unique_ptr< Assignment > > assignment_list_
Definition: ParserNode.h:2142
const std::string* Parser::UpdateStmt::get_table ( ) const
inline

Definition at line 2132 of file ParserNode.h.

References table_.

2132 { return table_.get(); }
std::unique_ptr< std::string > table_
Definition: ParserNode.h:2141
const Expr* Parser::UpdateStmt::get_where_clause ( ) const
inline

Definition at line 2136 of file ParserNode.h.

References where_clause_.

2136 { return where_clause_.get(); }
std::unique_ptr< Expr > where_clause_
Definition: ParserNode.h:2143

Member Data Documentation

std::list<std::unique_ptr<Assignment> > Parser::UpdateStmt::assignment_list_
private

Definition at line 2142 of file ParserNode.h.

Referenced by get_assignment_list(), and UpdateStmt().

std::unique_ptr<std::string> Parser::UpdateStmt::table_
private

Definition at line 2141 of file ParserNode.h.

Referenced by get_table().

std::unique_ptr<Expr> Parser::UpdateStmt::where_clause_
private

Definition at line 2143 of file ParserNode.h.

Referenced by get_where_clause().


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