OmniSciDB  b24e664e58
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
RexSubQuery Class Reference

#include <RelAlgAbstractInterpreter.h>

+ Inheritance diagram for RexSubQuery:
+ Collaboration diagram for RexSubQuery:

Public Member Functions

 RexSubQuery (const std::shared_ptr< const RelAlgNode > ra)
 
 RexSubQuery (std::shared_ptr< SQLTypeInfo > type, std::shared_ptr< std::shared_ptr< const ExecutionResult >> result, const std::shared_ptr< const RelAlgNode > ra)
 
 RexSubQuery (const RexSubQuery &)=delete
 
RexSubQueryoperator= (const RexSubQuery &)=delete
 
 RexSubQuery (RexSubQuery &&)=delete
 
RexSubQueryoperator= (RexSubQuery &&)=delete
 
const SQLTypeInfogetType () const
 
std::shared_ptr< const
ExecutionResult
getExecutionResult () const
 
const RelAlgNodegetRelAlg () const
 
std::string toString () const override
 
std::unique_ptr< RexSubQuerydeepCopy () const
 
void setExecutionResult (const std::shared_ptr< const ExecutionResult > result)
 
- Public Member Functions inherited from Rex
virtual ~Rex ()
 

Private Attributes

std::shared_ptr< SQLTypeInfotype_
 
std::shared_ptr
< std::shared_ptr< const
ExecutionResult > > 
result_
 
const std::shared_ptr< const
RelAlgNode
ra_
 

Detailed Description

Definition at line 259 of file RelAlgAbstractInterpreter.h.

Constructor & Destructor Documentation

RexSubQuery::RexSubQuery ( const std::shared_ptr< const RelAlgNode ra)
inline

Definition at line 261 of file RelAlgAbstractInterpreter.h.

262  : type_(new SQLTypeInfo(kNULLT, false))
263  , result_(new std::shared_ptr<const ExecutionResult>(nullptr))
264  , ra_(ra) {}
const std::shared_ptr< const RelAlgNode > ra_
std::shared_ptr< std::shared_ptr< const ExecutionResult > > result_
std::shared_ptr< SQLTypeInfo > type_
SQLTypeInfoCore< ArrayContextTypeSizer, ExecutorTypePackaging, DateTimeFacilities > SQLTypeInfo
Definition: sqltypes.h:852
RexSubQuery::RexSubQuery ( std::shared_ptr< SQLTypeInfo type,
std::shared_ptr< std::shared_ptr< const ExecutionResult >>  result,
const std::shared_ptr< const RelAlgNode ra 
)
inline

Definition at line 267 of file RelAlgAbstractInterpreter.h.

270  : type_(type), result_(result), ra_(ra) {}
const std::shared_ptr< const RelAlgNode > ra_
std::shared_ptr< std::shared_ptr< const ExecutionResult > > result_
std::shared_ptr< SQLTypeInfo > type_
RexSubQuery::RexSubQuery ( const RexSubQuery )
delete
RexSubQuery::RexSubQuery ( RexSubQuery &&  )
delete

Member Function Documentation

std::unique_ptr< RexSubQuery > RexSubQuery::deepCopy ( ) const

Definition at line 54 of file RelAlgAbstractInterpreter.cpp.

54  {
55  return std::make_unique<RexSubQuery>(type_, result_, ra_->deepCopy());
56 }
const std::shared_ptr< const RelAlgNode > ra_
std::shared_ptr< std::shared_ptr< const ExecutionResult > > result_
std::shared_ptr< SQLTypeInfo > type_
std::shared_ptr<const ExecutionResult> RexSubQuery::getExecutionResult ( ) const
inline

Definition at line 285 of file RelAlgAbstractInterpreter.h.

References CHECK(), and result_.

285  {
286  CHECK(result_);
287  CHECK(result_.get());
288  return *(result_.get());
289  }
std::shared_ptr< std::shared_ptr< const ExecutionResult > > result_
CHECK(cgen_state)

+ Here is the call graph for this function:

const RelAlgNode* RexSubQuery::getRelAlg ( ) const
inline

Definition at line 291 of file RelAlgAbstractInterpreter.h.

References ra_.

291 { return ra_.get(); }
const std::shared_ptr< const RelAlgNode > ra_
const SQLTypeInfo& RexSubQuery::getType ( ) const
inline

Definition at line 280 of file RelAlgAbstractInterpreter.h.

References CHECK_NE, kNULLT, and type_.

280  {
281  CHECK_NE(kNULLT, type_->get_type());
282  return *(type_.get());
283  }
#define CHECK_NE(x, y)
Definition: Logger.h:199
std::shared_ptr< SQLTypeInfo > type_
RexSubQuery& RexSubQuery::operator= ( const RexSubQuery )
delete
RexSubQuery& RexSubQuery::operator= ( RexSubQuery &&  )
delete
void RexSubQuery::setExecutionResult ( const std::shared_ptr< const ExecutionResult result)

Definition at line 45 of file RelAlgAbstractInterpreter.cpp.

References CHECK(), CHECK_EQ, and run_benchmark_import::result.

46  {
47  auto row_set = result->getRows();
48  CHECK(row_set);
49  CHECK_EQ(size_t(1), row_set->colCount());
50  *(type_.get()) = row_set->getColType(0);
51  (*(result_.get())) = result;
52 }
#define CHECK_EQ(x, y)
Definition: Logger.h:198
std::shared_ptr< std::shared_ptr< const ExecutionResult > > result_
CHECK(cgen_state)
std::shared_ptr< SQLTypeInfo > type_

+ Here is the call graph for this function:

std::string RexSubQuery::toString ( ) const
inlineoverridevirtual

Implements Rex.

Definition at line 293 of file RelAlgAbstractInterpreter.h.

References to_string().

293  {
294  return "(RexSubQuery " + std::to_string(reinterpret_cast<const uint64_t>(this)) + ")";
295  }
std::string to_string(char const *&&v)

+ Here is the call graph for this function:

Member Data Documentation

const std::shared_ptr<const RelAlgNode> RexSubQuery::ra_
private

Definition at line 304 of file RelAlgAbstractInterpreter.h.

Referenced by getRelAlg().

std::shared_ptr<std::shared_ptr<const ExecutionResult> > RexSubQuery::result_
private

Definition at line 303 of file RelAlgAbstractInterpreter.h.

Referenced by getExecutionResult().

std::shared_ptr<SQLTypeInfo> RexSubQuery::type_
private

Definition at line 302 of file RelAlgAbstractInterpreter.h.

Referenced by getType().


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