Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
duckdb::LogicalExpressionGet Class Reference

LogicalExpressionGet represents a scan operation over a set of to-be-executed expressions. More...

Inheritance diagram for duckdb::LogicalExpressionGet:
Collaboration diagram for duckdb::LogicalExpressionGet:

Public Member Functions

 LogicalExpressionGet (idx_t table_index, vector< LogicalType > types, vector< vector< unique_ptr< Expression > > > expressions)
vector< ColumnBinding > GetColumnBindings () override
void Serialize (Serializer &serializer) const override
idx_t EstimateCardinality (ClientContext &context) override
vector< idx_t > GetTableIndex () const override
 Returns the set of table indexes of this operator.
string GetName () const override
Public Member Functions inherited from duckdb::LogicalOperator
 LogicalOperator (LogicalOperatorType type)
 LogicalOperator (LogicalOperatorType type, vector< unique_ptr< Expression > > expressions)
virtual idx_t GetRootIndex ()
void PrintColumnBindings ()
void ResolveOperatorTypes ()
 Resolve the types of the logical operator and its children.
virtual InsertionOrderPreservingMap< string > ParamsToString () const
virtual string ToString (ExplainFormat format=ExplainFormat::DEFAULT) const
DUCKDB_API void Print ()
virtual void Verify (ClientContext &context)
 Debug method: verify that the integrity of expressions & child nodes are maintained.
void AddChild (unique_ptr< LogicalOperator > child)
void SetEstimatedCardinality (idx_t _estimated_cardinality)
void SetParamsEstimatedCardinality (InsertionOrderPreservingMap< string > &result) const
virtual unique_ptr< LogicalOperator > Copy (ClientContext &context) const
virtual bool RequireOptimizer () const
virtual bool SupportSerialization () const
 Allows LogicalOperators to opt out of serialization.
virtual bool HasProjectionMap () const
template<class TARGET>
TARGET & Cast ()
template<class TARGET>
const TARGET & Cast () const

Static Public Member Functions

static unique_ptr< LogicalOperator > Deserialize (Deserializer &deserializer)
Static Public Member Functions inherited from duckdb::LogicalOperator
static string ColumnBindingsToString (const vector< ColumnBinding > &bindings)
static vector< ColumnBinding > GenerateColumnBindings (idx_t table_idx, idx_t column_count)
static vector< LogicalType > MapTypes (const vector< LogicalType > &types, const vector< idx_t > &projection_map)
static vector< ColumnBinding > MapBindings (const vector< ColumnBinding > &types, const vector< idx_t > &projection_map)
static unique_ptr< LogicalOperator > Deserialize (Deserializer &deserializer)

Public Attributes

idx_t table_index
 The table index in the current bind context.
vector< LogicalType > expr_types
 The types of the expressions.
vector< vector< unique_ptr< Expression > > > expressions
 The set of expressions.
Public Attributes inherited from duckdb::LogicalOperator
LogicalOperatorType type
 The type of the logical operator.
vector< unique_ptr< LogicalOperator > > children
 The set of children of the operator.
vector< unique_ptr< Expression > > expressions
 The set of expressions contained within the operator, if any.
vector< LogicalType > types
 The types returned by this logical operator. Set by calling LogicalOperator::ResolveTypes.
idx_t estimated_cardinality
 Estimated Cardinality.
bool has_estimated_cardinality

Static Public Attributes

static constexpr const LogicalOperatorType TYPE = LogicalOperatorType::LOGICAL_EXPRESSION_GET

Protected Member Functions

void ResolveTypes () override
 Resolve types for this specific operator.

Detailed Description

LogicalExpressionGet represents a scan operation over a set of to-be-executed expressions.

Constructor & Destructor Documentation

◆ LogicalExpressionGet()

duckdb::LogicalExpressionGet::LogicalExpressionGet ( idx_t table_index,
vector< LogicalType > types,
vector< vector< unique_ptr< Expression > > > expressions )
inline
204424 : LogicalOperator(LogicalOperatorType::LOGICAL_EXPRESSION_GET), table_index(table_index),
204425 expr_types(std::move(types)), expressions(std::move(expressions)) {
204426 }
vector< LogicalType > expr_types
The types of the expressions.
Definition duckdb.cpp:204431
vector< vector< unique_ptr< Expression > > > expressions
The set of expressions.
Definition duckdb.cpp:204433
idx_t table_index
The table index in the current bind context.
Definition duckdb.cpp:204429
vector< LogicalType > types
The types returned by this logical operator. Set by calling LogicalOperator::ResolveTypes.
Definition duckdb.hpp:21266

Member Function Documentation

◆ GetColumnBindings()

vector< ColumnBinding > duckdb::LogicalExpressionGet::GetColumnBindings ( )
inlineoverridevirtual

Reimplemented from duckdb::LogicalOperator.

204436 {
204437 return GenerateColumnBindings(table_index, expr_types.size());
204438 }

◆ Serialize()

void duckdb::LogicalExpressionGet::Serialize ( Serializer & serializer) const
overridevirtual

Reimplemented from duckdb::LogicalOperator.

416780 {
416781 LogicalOperator::Serialize(serializer);
416782 serializer.WritePropertyWithDefault<idx_t>(200, "table_index", table_index);
416783 serializer.WritePropertyWithDefault<vector<LogicalType>>(201, "expr_types", expr_types);
416784 serializer.WritePropertyWithDefault<vector<vector<unique_ptr<Expression>>>>(202, "expressions", expressions);
416785}
uint64_t idx_t
a saner size_t for loop indices etc
Definition duckdb.hpp:237

◆ Deserialize()

unique_ptr< LogicalOperator > duckdb::LogicalExpressionGet::Deserialize ( Deserializer & deserializer)
static
416787 {
416788 auto table_index = deserializer.ReadPropertyWithDefault<idx_t>(200, "table_index");
416789 auto expr_types = deserializer.ReadPropertyWithDefault<vector<LogicalType>>(201, "expr_types");
416790 auto expressions = deserializer.ReadPropertyWithDefault<vector<vector<unique_ptr<Expression>>>>(202, "expressions");
416791 auto result = duckdb::unique_ptr<LogicalExpressionGet>(new LogicalExpressionGet(table_index, std::move(expr_types), std::move(expressions)));
416792 return std::move(result);
416793}

◆ EstimateCardinality()

idx_t duckdb::LogicalExpressionGet::EstimateCardinality ( ClientContext & context)
inlineoverridevirtual

Reimplemented from duckdb::LogicalOperator.

204442 {
204443 return expressions.size();
204444 }

◆ GetTableIndex()

vector< idx_t > duckdb::LogicalExpressionGet::GetTableIndex ( ) const
overridevirtual

Returns the set of table indexes of this operator.

Reimplemented from duckdb::LogicalOperator.

382102 {
382103 return vector<idx_t> {table_index};
382104}

◆ GetName()

string duckdb::LogicalExpressionGet::GetName ( ) const
overridevirtual

Reimplemented from duckdb::LogicalOperator.

382106 {
382107#ifdef DEBUG
382109 return LogicalOperator::GetName() + StringUtil::Format(" #%llu", table_index);
382110 }
382111#endif
382112 return LogicalOperator::GetName();
382113}
static string Format(const string fmt_str, ARGS... params)
Format a string using printf semantics.
Definition duckdb.hpp:4002
static bool debug_print_bindings
Whether to print bindings when printing the plan (debug mode only).
Definition duckdb.hpp:40040

◆ ResolveTypes()

void duckdb::LogicalExpressionGet::ResolveTypes ( )
inlineoverrideprotectedvirtual

Resolve types for this specific operator.

Implements duckdb::LogicalOperator.

204449 {
204450 // types are resolved in the constructor
204451 this->types = expr_types;
204452 }

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