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

Public Member Functions

DUCKDB_API BaseQueryResult (QueryResultType type, StatementType statement_type, StatementProperties properties, vector< LogicalType > types, vector< string > names)
 Creates a successful query result with the specified names and types.
DUCKDB_API BaseQueryResult (QueryResultType type, ErrorData error)
 Creates an unsuccessful query result with error condition.
DUCKDB_API void ThrowError (const string &prepended_message="") const
DUCKDB_API void SetError (ErrorData error)
DUCKDB_API bool HasError () const
DUCKDB_API const ExceptionType & GetErrorType () const
DUCKDB_API const std::string & GetError () const
DUCKDB_API ErrorData & GetErrorObject ()
DUCKDB_API idx_t ColumnCount ()

Public Attributes

QueryResultType type
 The type of the result (MATERIALIZED or STREAMING).
StatementType statement_type
 The type of the statement that created this result.
StatementProperties properties
 Properties of the statement.
vector< LogicalType > types
 The SQL types of the result.
vector< string > names
 The names of the result.

Protected Attributes

bool success
 Whether or not execution was successful.
ErrorData error
 The error (in case execution was not successful).

Constructor & Destructor Documentation

◆ BaseQueryResult() [1/2]

duckdb::BaseQueryResult::BaseQueryResult ( QueryResultType type,
StatementType statement_type,
StatementProperties properties,
vector< LogicalType > types,
vector< string > names )

Creates a successful query result with the specified names and types.

296002 : type(type), statement_type(statement_type), properties(std::move(properties_p)), types(std::move(types_p)),
296003 names(std::move(names_p)), success(true) {
296004 D_ASSERT(types.size() == names.size());
296005}
StatementProperties properties
Properties of the statement.
Definition duckdb.hpp:19520
StatementType statement_type
The type of the statement that created this result.
Definition duckdb.hpp:19518
bool success
Whether or not execution was successful.
Definition duckdb.hpp:19537
vector< LogicalType > types
The SQL types of the result.
Definition duckdb.hpp:19522
QueryResultType type
The type of the result (MATERIALIZED or STREAMING).
Definition duckdb.hpp:19516
vector< string > names
The names of the result.
Definition duckdb.hpp:19524
Here is the caller graph for this function:

◆ BaseQueryResult() [2/2]

duckdb::BaseQueryResult::BaseQueryResult ( QueryResultType type,
ErrorData error )

Creates an unsuccessful query result with error condition.

296008 : type(type), success(false), error(std::move(error)) {
296009 // Assert that the error object is initialized
296010 D_ASSERT(this->error.HasError());
296011}
ErrorData error
The error (in case execution was not successful).
Definition duckdb.hpp:19539
Here is the call graph for this function:

◆ ~BaseQueryResult()

duckdb::BaseQueryResult::~BaseQueryResult ( )
virtual
296013 {
296014}

Member Function Documentation

◆ ThrowError()

void duckdb::BaseQueryResult::ThrowError ( const string & prepended_message = "") const
296016 {
296017 D_ASSERT(HasError());
296018 error.Throw(prepended_message);
296019}

◆ SetError()

void duckdb::BaseQueryResult::SetError ( ErrorData error)
296021 {
296022 success = !error.HasError();
296023 this->error = std::move(error);
296024}

◆ HasError()

bool duckdb::BaseQueryResult::HasError ( ) const
296026 {
296027 D_ASSERT(error.HasError() == !success);
296028 return !success;
296029}

◆ GetErrorType()

const ExceptionType & duckdb::BaseQueryResult::GetErrorType ( ) const
296031 {
296032 return error.Type();
296033}

◆ GetError()

const std::string & duckdb::BaseQueryResult::GetError ( ) const
296035 {
296036 D_ASSERT(HasError());
296037 return error.Message();
296038}

◆ GetErrorObject()

ErrorData & duckdb::BaseQueryResult::GetErrorObject ( )
296040 {
296041 return error;
296042}

◆ ColumnCount()

idx_t duckdb::BaseQueryResult::ColumnCount ( )
296044 {
296045 return types.size();
296046}

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