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

The LocalStorage class holds appends that have not been committed yet. More...

Collaboration diagram for duckdb::LocalStorage:

Classes

struct  CommitState
 

Public Member Functions

 LocalStorage (ClientContext &context, DuckTransaction &transaction)
 
void InitializeScan (DataTable &table, CollectionScanState &state, optional_ptr< TableFilterSet > table_filters)
 Initialize a scan of the local storage.
 
void Scan (CollectionScanState &state, const vector< StorageIndex > &column_ids, DataChunk &result)
 Scan.
 
void InitializeParallelScan (DataTable &table, ParallelCollectionScanState &state)
 
bool NextParallelScan (ClientContext &context, DataTable &table, ParallelCollectionScanState &state, CollectionScanState &scan_state)
 
void InitializeAppend (LocalAppendState &state, DataTable &table)
 Begin appending to the local storage.
 
void InitializeStorage (LocalAppendState &state, DataTable &table)
 Initialize the storage and its indexes, but no row groups.
 
void LocalMerge (DataTable &table, OptimisticWriteCollection &collection)
 Merge a row group collection into the transaction-local storage.
 
PhysicalIndex CreateOptimisticCollection (DataTable &table, unique_ptr< OptimisticWriteCollection > collection)
 
OptimisticWriteCollectionGetOptimisticCollection (DataTable &table, const PhysicalIndex collection_index)
 Returns the optimistic row group collection corresponding to the index.
 
void ResetOptimisticCollection (DataTable &table, const PhysicalIndex collection_index)
 Resets the optimistic row group collection corresponding to the index.
 
OptimisticDataWriterGetOptimisticWriter (DataTable &table)
 Returns the optimistic writer.
 
idx_t Delete (DataTable &table, Vector &row_ids, idx_t count)
 Delete a set of rows from the local storage.
 
void Update (DataTable &table, Vector &row_ids, const vector< PhysicalIndex > &column_ids, DataChunk &data)
 Update a set of rows in the local storage.
 
void Commit (optional_ptr< StorageCommitState > commit_state)
 Commits the local storage, writing it to the WAL and completing the commit.
 
void Rollback ()
 Rollback the local storage.
 
bool ChangesMade () noexcept
 
idx_t EstimatedSize ()
 
void DropTable (DataTable &table)
 
bool Find (DataTable &table)
 
idx_t AddedRows (DataTable &table)
 
vector< PartitionStatisticsGetPartitionStats (DataTable &table) const
 
void AddColumn (DataTable &old_dt, DataTable &new_dt, ColumnDefinition &new_column, ExpressionExecutor &default_executor)
 
void DropColumn (DataTable &old_dt, DataTable &new_dt, const idx_t drop_column_index)
 
void ChangeType (DataTable &old_dt, DataTable &new_dt, idx_t changed_idx, const LogicalType &target_type, const vector< StorageIndex > &bound_columns, Expression &cast_expr)
 
void MoveStorage (DataTable &old_dt, DataTable &new_dt)
 
void FetchChunk (DataTable &table, const Vector &row_ids, idx_t count, const vector< StorageIndex > &col_ids, DataChunk &chunk, ColumnFetchState &fetch_state)
 
bool CanFetch (DataTable &table, const row_t row_id)
 Returns true, if the local storage contains the row id.
 
TableIndexListGetIndexes (ClientContext &context, DataTable &table)
 
optional_ptr< LocalTableStorageGetStorage (DataTable &table)
 
void VerifyNewConstraint (DataTable &parent, const BoundConstraint &constraint)
 
ClientContextGetClientContext () const
 

Static Public Member Functions

static LocalStorageGet (DuckTransaction &transaction)
 
static LocalStorageGet (ClientContext &context, AttachedDatabase &db)
 
static LocalStorageGet (ClientContext &context, Catalog &catalog)
 
static void Append (LocalAppendState &state, DataChunk &table_chunk, DataTableInfo &data_table_info)
 Append a chunk to the local storage.
 
static void FinalizeAppend (LocalAppendState &state)
 Finish appending to the local storage.
 

Private Member Functions

void Flush (DataTable &table, LocalTableStorage &storage, optional_ptr< StorageCommitState > commit_state)
 

Private Attributes

ClientContextcontext
 
DuckTransactiontransaction
 
LocalTableManager table_manager
 

Detailed Description

The LocalStorage class holds appends that have not been committed yet.

Member Function Documentation

◆ CreateOptimisticCollection()

PhysicalIndex duckdb::LocalStorage::CreateOptimisticCollection ( DataTable table,
unique_ptr< OptimisticWriteCollection collection 
)

Create an optimistic row group collection for this table. Returns the index into the optimistic_collections vector for newly created collection.

◆ GetClientContext()

ClientContext & duckdb::LocalStorage::GetClientContext ( ) const
inline
50945 {
50946 return context;
50947 }

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