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::BaseTableRef Class Reference

Represents a TableReference to a base table in a catalog and schema. More...

Inheritance diagram for duckdb::BaseTableRef:
Collaboration diagram for duckdb::BaseTableRef:

Public Member Functions

 BaseTableRef (const TableDescription &description)
string ToString () const override
 Convert the object to a string.
bool Equals (const TableRef &other_p) const override
unique_ptr< TableRef > Copy () override
void Serialize (Serializer &serializer) const override
Public Member Functions inherited from duckdb::TableRef
 TableRef (TableReferenceType type)
void Print ()
void CopyProperties (TableRef &target) const
 Copy the properties of this table ref to the target.
template<class TARGET>
TARGET & Cast ()
template<class TARGET>
const TARGET & Cast () const

Static Public Member Functions

static unique_ptr< TableRef > Deserialize (Deserializer &source)
Static Public Member Functions inherited from duckdb::TableRef
static bool Equals (const unique_ptr< TableRef > &left, const unique_ptr< TableRef > &right)
static unique_ptr< TableRef > Deserialize (Deserializer &deserializer)

Public Attributes

string catalog_name
 The catalog name.
string schema_name
 The schema name.
string table_name
 The table name.
unique_ptr< AtClause > at_clause
 The timestamp/version at which to read this table entry (if any).
Public Attributes inherited from duckdb::TableRef
TableReferenceType type
string alias
unique_ptr< SampleOptions > sample
 Sample options (if any).
optional_idx query_location
 The location in the query (if any).
shared_ptr< ExternalDependency > external_dependency
 External dependencies of this table function.
vector< string > column_name_alias
 Aliases for the column names.

Static Public Attributes

static constexpr const TableReferenceType TYPE = TableReferenceType::BASE_TABLE
Static Public Attributes inherited from duckdb::TableRef
static constexpr const TableReferenceType TYPE = TableReferenceType::INVALID

Additional Inherited Members

Protected Member Functions inherited from duckdb::TableRef
string BaseToString (string result) const
string BaseToString (string result, const vector< string > &column_name_alias) const
string AliasToString (const vector< string > &column_name_alias) const
string SampleToString () const

Detailed Description

Represents a TableReference to a base table in a catalog and schema.

Constructor & Destructor Documentation

◆ BaseTableRef() [1/2]

duckdb::BaseTableRef::BaseTableRef ( )
inline
296750 : TableRef(TableReferenceType::BASE_TABLE), catalog_name(INVALID_CATALOG), schema_name(INVALID_SCHEMA) {
296751 }
string schema_name
The schema name.
Definition duckdb.cpp:296760
string catalog_name
The catalog name.
Definition duckdb.cpp:296758

◆ BaseTableRef() [2/2]

duckdb::BaseTableRef::BaseTableRef ( const TableDescription & description)
inlineexplicit
296753 : TableRef(TableReferenceType::BASE_TABLE), catalog_name(description.database), schema_name(description.schema),
296754 table_name(description.table) {
296755 }
string table_name
The table name.
Definition duckdb.cpp:296762
string schema
The schema of the table.
Definition duckdb.hpp:41356
string table
The name of the table.
Definition duckdb.hpp:41358
string database
The database of the table.
Definition duckdb.hpp:41354

Member Function Documentation

◆ ToString()

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

Convert the object to a string.

Implements duckdb::TableRef.

350253 {
350254 string result;
350255 result += catalog_name.empty() ? "" : (KeywordHelper::WriteOptionallyQuoted(catalog_name) + ".");
350256 result += schema_name.empty() ? "" : (KeywordHelper::WriteOptionallyQuoted(schema_name) + ".");
350258 result += AliasToString(column_name_alias);
350259 if (at_clause) {
350260 result += " " + at_clause->ToString();
350261 }
350262 result += SampleToString();
350263 return result;
350264}
unique_ptr< AtClause > at_clause
The timestamp/version at which to read this table entry (if any).
Definition duckdb.cpp:296764
static string WriteOptionallyQuoted(const string &text, char quote='"', bool allow_caps = true, KeywordCategory category = KeywordCategory::KEYWORD_NONE)
Writes a string that is optionally quoted + escaped so it can be used as an identifier.
Definition duckdb.cpp:338034
vector< string > column_name_alias
Aliases for the column names.
Definition duckdb.hpp:53744
Here is the call graph for this function:

◆ Equals()

bool duckdb::BaseTableRef::Equals ( const TableRef & other_p) const
overridevirtual

Reimplemented from duckdb::TableRef.

350266 {
350267 if (!TableRef::Equals(other_p)) {
350268 return false;
350269 }
350270 auto &other = other_p.Cast<BaseTableRef>();
350271 return other.catalog_name == catalog_name && other.schema_name == schema_name && other.table_name == table_name &&
350272 column_name_alias == other.column_name_alias && AtClause::Equals(at_clause.get(), other.at_clause.get());
350273}

◆ Copy()

unique_ptr< TableRef > duckdb::BaseTableRef::Copy ( )
overridevirtual

Implements duckdb::TableRef.

350275 {
350276 auto copy = make_uniq<BaseTableRef>();
350277
350278 copy->catalog_name = catalog_name;
350279 copy->schema_name = schema_name;
350280 copy->table_name = table_name;
350281 copy->column_name_alias = column_name_alias;
350282 copy->at_clause = at_clause ? at_clause->Copy() : nullptr;
350283 CopyProperties(*copy);
350284
350285 return std::move(copy);
350286}
void CopyProperties(TableRef &target) const
Copy the properties of this table ref to the target.
Definition duckdb.cpp:351228

◆ Serialize()

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

Reimplemented from duckdb::TableRef.

419650 {
419651 TableRef::Serialize(serializer);
419652 serializer.WritePropertyWithDefault<string>(200, "schema_name", schema_name);
419653 serializer.WritePropertyWithDefault<string>(201, "table_name", table_name);
419654 serializer.WritePropertyWithDefault<vector<string>>(202, "column_name_alias", column_name_alias);
419655 serializer.WritePropertyWithDefault<string>(203, "catalog_name", catalog_name);
419656 serializer.WritePropertyWithDefault<unique_ptr<AtClause>>(204, "at_clause", at_clause);
419657}

◆ Deserialize()

unique_ptr< TableRef > duckdb::BaseTableRef::Deserialize ( Deserializer & source)
static
419659 {
419660 auto result = duckdb::unique_ptr<BaseTableRef>(new BaseTableRef());
419661 deserializer.ReadPropertyWithDefault<string>(200, "schema_name", result->schema_name);
419662 deserializer.ReadPropertyWithDefault<string>(201, "table_name", result->table_name);
419663 deserializer.ReadPropertyWithDefault<vector<string>>(202, "column_name_alias", result->column_name_alias);
419664 deserializer.ReadPropertyWithDefault<string>(203, "catalog_name", result->catalog_name);
419665 deserializer.ReadPropertyWithDefault<unique_ptr<AtClause>>(204, "at_clause", result->at_clause);
419666 return std::move(result);
419667}

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