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::RecursiveCTENode Class Reference
Inheritance diagram for duckdb::RecursiveCTENode:
Collaboration diagram for duckdb::RecursiveCTENode:

Public Member Functions

string ToString () const override
 Convert the query node to a string.
bool Equals (const QueryNode *other) const override
unique_ptr< QueryNode > Copy () const override
 Create a copy of this SelectNode.
void Serialize (Serializer &serializer) const override
Public Member Functions inherited from duckdb::QueryNode
 QueryNode (QueryNodeType type)
string ResultModifiersToString () const
void AddDistinct ()
 Adds a distinct modifier to the query node.
template<class TARGET>
TARGET & Cast ()
template<class TARGET>
const TARGET & Cast () const

Static Public Member Functions

static unique_ptr< QueryNode > Deserialize (Deserializer &source)
Static Public Member Functions inherited from duckdb::QueryNode
static unique_ptr< QueryNode > Deserialize (Deserializer &deserializer)

Public Attributes

string ctename
bool union_all
unique_ptr< QueryNode > left
 The left side of the set operation.
unique_ptr< QueryNode > right
 The right side of the set operation.
vector< string > aliases
 Aliases of the recursive CTE node.
vector< unique_ptr< ParsedExpression > > key_targets
 targets for key variants
Public Attributes inherited from duckdb::QueryNode
QueryNodeType type
 The type of the query node, either SetOperation or Select.
vector< unique_ptr< ResultModifier > > modifiers
 The set of result modifiers associated with this query node.
CommonTableExpressionMap cte_map
 CTEs (used by SelectNode and SetOperationNode).

Static Public Attributes

static constexpr const QueryNodeType TYPE = QueryNodeType::RECURSIVE_CTE_NODE

Additional Inherited Members

Protected Member Functions inherited from duckdb::QueryNode
void CopyProperties (QueryNode &other) const
 Copy base QueryNode properties from another expression to this one, used in Copy method.

Constructor & Destructor Documentation

◆ RecursiveCTENode()

duckdb::RecursiveCTENode::RecursiveCTENode ( )
inline
340557 : QueryNode(QueryNodeType::RECURSIVE_CTE_NODE) {
340558 }

Member Function Documentation

◆ ToString()

string duckdb::RecursiveCTENode::ToString ( ) const
overridevirtual

Convert the query node to a string.

Implements duckdb::QueryNode.

347991 {
347992 string result;
347993 result = cte_map.ToString();
347994 result += "(" + left->ToString() + ")";
347995 result += " UNION ";
347996 if (union_all) {
347997 result += " ALL ";
347998 }
347999 result += "(" + right->ToString() + ")";
348000 return result;
348001}
CommonTableExpressionMap cte_map
CTEs (used by SelectNode and SetOperationNode).
Definition duckdb.hpp:53582
unique_ptr< QueryNode > left
The left side of the set operation.
Definition duckdb.cpp:340563
unique_ptr< QueryNode > right
The right side of the set operation.
Definition duckdb.cpp:340565

◆ Equals()

bool duckdb::RecursiveCTENode::Equals ( const QueryNode * other) const
overridevirtual

Reimplemented from duckdb::QueryNode.

348003 {
348004 if (!QueryNode::Equals(other_p)) {
348005 return false;
348006 }
348007 if (this == other_p) {
348008 return true;
348009 }
348010 auto &other = other_p->Cast<RecursiveCTENode>();
348011
348012 if (other.union_all != union_all) {
348013 return false;
348014 }
348015
348016 if (!ParsedExpression::ListEquals(key_targets, other.key_targets)) {
348017 return false;
348018 }
348019
348020 if (!left->Equals(other.left.get())) {
348021 return false;
348022 }
348023 if (!right->Equals(other.right.get())) {
348024 return false;
348025 }
348026 return true;
348027}
vector< unique_ptr< ParsedExpression > > key_targets
targets for key variants
Definition duckdb.cpp:340569

◆ Copy()

unique_ptr< QueryNode > duckdb::RecursiveCTENode::Copy ( ) const
overridevirtual

Create a copy of this SelectNode.

Implements duckdb::QueryNode.

348029 {
348030 auto result = make_uniq<RecursiveCTENode>();
348031 result->ctename = ctename;
348032 result->union_all = union_all;
348033 result->left = left->Copy();
348034 result->right = right->Copy();
348035 result->aliases = aliases;
348036
348037 for (auto &key : key_targets) {
348038 result->key_targets.push_back(key->Copy());
348039 }
348040
348041 this->CopyProperties(*result);
348042 return std::move(result);
348043}
void CopyProperties(QueryNode &other) const
Copy base QueryNode properties from another expression to this one, used in Copy method.
Definition duckdb.cpp:348602
vector< string > aliases
Aliases of the recursive CTE node.
Definition duckdb.cpp:340567
Here is the call graph for this function:

◆ Serialize()

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

Serializes a QueryNode to a stand-alone binary blob Deserializes a blob back into a QueryNode

Reimplemented from duckdb::QueryNode.

419095 {
419096 QueryNode::Serialize(serializer);
419097 serializer.WritePropertyWithDefault<string>(200, "cte_name", ctename);
419098 serializer.WritePropertyWithDefault<bool>(201, "union_all", union_all, false);
419099 serializer.WritePropertyWithDefault<unique_ptr<QueryNode>>(202, "left", left);
419100 serializer.WritePropertyWithDefault<unique_ptr<QueryNode>>(203, "right", right);
419101 serializer.WritePropertyWithDefault<vector<string>>(204, "aliases", aliases);
419102 serializer.WritePropertyWithDefault<vector<unique_ptr<ParsedExpression>>>(205, "key_targets", key_targets);
419103}

◆ Deserialize()

unique_ptr< QueryNode > duckdb::RecursiveCTENode::Deserialize ( Deserializer & source)
static
419105 {
419106 auto result = duckdb::unique_ptr<RecursiveCTENode>(new RecursiveCTENode());
419107 deserializer.ReadPropertyWithDefault<string>(200, "cte_name", result->ctename);
419108 deserializer.ReadPropertyWithExplicitDefault<bool>(201, "union_all", result->union_all, false);
419109 deserializer.ReadPropertyWithDefault<unique_ptr<QueryNode>>(202, "left", result->left);
419110 deserializer.ReadPropertyWithDefault<unique_ptr<QueryNode>>(203, "right", result->right);
419111 deserializer.ReadPropertyWithDefault<vector<string>>(204, "aliases", result->aliases);
419112 deserializer.ReadPropertyWithDefault<vector<unique_ptr<ParsedExpression>>>(205, "key_targets", result->key_targets);
419113 return std::move(result);
419114}

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