OmniSciDB  04ee39c94c
Parser::InExpr Class Referenceabstract

#include <ParserNode.h>

+ Inheritance diagram for Parser::InExpr:
+ Collaboration diagram for Parser::InExpr:

Public Member Functions

 InExpr (bool n, Expr *a)
 
bool get_is_not () const
 
const Exprget_arg () const
 
std::shared_ptr< Analyzer::Expranalyze (const Catalog_Namespace::Catalog &catalog, Analyzer::Query &query, TlistRefType allow_tlist_ref=TLIST_NONE) const override=0
 
std::string to_string () const override
 
- Public Member Functions inherited from Parser::Node
virtual ~Node ()
 

Protected Attributes

bool is_not
 
std::unique_ptr< Exprarg
 

Additional Inherited Members

- Public Types inherited from Parser::Expr
enum  TlistRefType { TLIST_NONE, TLIST_REF, TLIST_COPY }
 

Detailed Description

Definition at line 364 of file ParserNode.h.

Constructor & Destructor Documentation

◆ InExpr()

Parser::InExpr::InExpr ( bool  n,
Expr a 
)
inline

Definition at line 366 of file ParserNode.h.

366 : is_not(n), arg(a) {}
std::unique_ptr< Expr > arg
Definition: ParserNode.h:377

Member Function Documentation

◆ analyze()

std::shared_ptr<Analyzer::Expr> Parser::InExpr::analyze ( const Catalog_Namespace::Catalog catalog,
Analyzer::Query query,
TlistRefType  allow_tlist_ref = TLIST_NONE 
) const
overridepure virtual

Implements Parser::Expr.

Implemented in Parser::InValues, and Parser::InSubquery.

◆ get_arg()

const Expr* Parser::InExpr::get_arg ( ) const
inline

Definition at line 368 of file ParserNode.h.

References anonymous_namespace{UpdateMetadataTest.cpp}::query, and to_string().

368 { return arg.get(); }
std::unique_ptr< Expr > arg
Definition: ParserNode.h:377
+ Here is the call graph for this function:

◆ get_is_not()

bool Parser::InExpr::get_is_not ( ) const
inline

Definition at line 367 of file ParserNode.h.

367 { return is_not; }

◆ to_string()

std::string Parser::InExpr::to_string ( ) const
overridevirtual

Implements Parser::Expr.

Reimplemented in Parser::InValues, and Parser::InSubquery.

Definition at line 1348 of file ParserNode.cpp.

1348  {
1349  std::string str = arg->to_string();
1350  if (is_not) {
1351  str += " NOT IN ";
1352  } else {
1353  str += " IN ";
1354  }
1355  return str;
1356 }
std::unique_ptr< Expr > arg
Definition: ParserNode.h:377

Member Data Documentation

◆ arg

std::unique_ptr<Expr> Parser::InExpr::arg
protected

Definition at line 377 of file ParserNode.h.

◆ is_not

bool Parser::InExpr::is_not
protected

Definition at line 376 of file ParserNode.h.


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