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::BoundOrderByNode Struct Reference
Collaboration diagram for duckdb::BoundOrderByNode:

Public Member Functions

 BoundOrderByNode (OrderType type, OrderByNullType null_order, unique_ptr< Expression > expression)
 BoundOrderByNode (OrderType type, OrderByNullType null_order, unique_ptr< Expression > expression, unique_ptr< BaseStatistics > stats)
BoundOrderByNode Copy () const
bool Equals (const BoundOrderByNode &other) const
string GetOrderModifier () const
string ToString () const
void Serialize (Serializer &serializer) const

Static Public Member Functions

static BoundOrderByNode Deserialize (Deserializer &deserializer)

Public Attributes

OrderType type
OrderByNullType null_order
unique_ptr< Expression > expression
unique_ptr< BaseStatistics > stats

Static Public Attributes

static constexpr const ResultModifierType TYPE = ResultModifierType::ORDER_MODIFIER

Constructor & Destructor Documentation

◆ BoundOrderByNode() [1/2]

duckdb::BoundOrderByNode::BoundOrderByNode ( OrderType type,
OrderByNullType null_order,
unique_ptr< Expression > expression )
374991 : type(type), null_order(null_order), expression(std::move(expression)) {
374992}

◆ BoundOrderByNode() [2/2]

duckdb::BoundOrderByNode::BoundOrderByNode ( OrderType type,
OrderByNullType null_order,
unique_ptr< Expression > expression,
unique_ptr< BaseStatistics > stats )
374995 : type(type), null_order(null_order), expression(std::move(expression)), stats(std::move(stats)) {
374996}

Member Function Documentation

◆ Copy()

BoundOrderByNode duckdb::BoundOrderByNode::Copy ( ) const
374998 {
374999 if (stats) {
375000 return BoundOrderByNode(type, null_order, expression->Copy(), stats->ToUnique());
375001 } else {
375002 return BoundOrderByNode(type, null_order, expression->Copy());
375003 }
375004}

◆ Equals()

bool duckdb::BoundOrderByNode::Equals ( const BoundOrderByNode & other) const
375006 {
375007 if (type != other.type || null_order != other.null_order) {
375008 return false;
375009 }
375010 if (!expression->Equals(*other.expression)) {
375011 return false;
375012 }
375013
375014 return true;
375015}

◆ GetOrderModifier()

string duckdb::BoundOrderByNode::GetOrderModifier ( ) const
375017 {
375018 string modifier;
375019 modifier += (type == OrderType::ASCENDING) ? "ASC" : "DESC";
375020 modifier += " NULLS";
375021 modifier += (null_order == OrderByNullType::NULLS_FIRST) ? " FIRST" : " LAST";
375022 return modifier;
375023}

◆ ToString()

string duckdb::BoundOrderByNode::ToString ( ) const
375025 {
375026 auto str = expression->ToString();
375027 switch (type) {
375028 case OrderType::ASCENDING:
375029 str += " ASC";
375030 break;
375031 case OrderType::DESCENDING:
375032 str += " DESC";
375033 break;
375034 default:
375035 break;
375036 }
375037
375038 switch (null_order) {
375039 case OrderByNullType::NULLS_FIRST:
375040 str += " NULLS FIRST";
375041 break;
375042 case OrderByNullType::NULLS_LAST:
375043 str += " NULLS LAST";
375044 break;
375045 default:
375046 break;
375047 }
375048 return str;
375049}

◆ Serialize()

void duckdb::BoundOrderByNode::Serialize ( Serializer & serializer) const
417292 {
417293 serializer.WriteProperty<OrderType>(100, "type", type);
417294 serializer.WriteProperty<OrderByNullType>(101, "null_order", null_order);
417295 serializer.WritePropertyWithDefault<unique_ptr<Expression>>(102, "expression", expression);
417296}

◆ Deserialize()

BoundOrderByNode duckdb::BoundOrderByNode::Deserialize ( Deserializer & deserializer)
static
417298 {
417299 auto type = deserializer.ReadProperty<OrderType>(100, "type");
417300 auto null_order = deserializer.ReadProperty<OrderByNullType>(101, "null_order");
417301 auto expression = deserializer.ReadPropertyWithDefault<unique_ptr<Expression>>(102, "expression");
417302 BoundOrderByNode result(type, null_order, std::move(expression));
417303 return result;
417304}

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