iceberg-cpp
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Friends | List of all members
iceberg::MetadataTable Class Referenceabstract

A metadata table backed by a source Iceberg table. More...

#include <metadata_table.h>

Inheritance diagram for iceberg::MetadataTable:
iceberg::HistoryTable iceberg::RefsTable iceberg::SnapshotsTable

Public Types

using Kind = MetadataTableKind
 

Public Member Functions

virtual Kind kind () const noexcept=0
 Return this metadata table's kind.
 
virtual const std::shared_ptr< Schema > & schema () const =0
 Return the complete canonical schema of this metadata table.
 
const std::shared_ptr< const Table > & source_table () const
 Return the source table whose metadata is exposed.
 
virtual Result< std::unique_ptr< MetadataScanBuilder > > NewScan () const
 Capture the source metadata and create a scan builder.
 

Static Public Member Functions

static Result< std::unique_ptr< MetadataTable > > Make (std::shared_ptr< const Table > table, Kind kind)
 Create a metadata table; unsupported kinds return NotImplemented.
 
template<typename MetadataTableType >
requires std::derived_from<MetadataTableType, MetadataTable>
static Result< std::unique_ptr< MetadataTableType > > Make (std::shared_ptr< const Table > table)
 Create a specific metadata table from its concrete class.
 

Protected Member Functions

 MetadataTable (std::shared_ptr< const Table > source_table)
 
virtual Result< std::unique_ptr< MetadataScan > > MakeScan (internal::MetadataScanContext context) const =0
 Plan a scan using the captured metadata, projection, and snapshot selection.
 

Friends

class MetadataScanBuilder
 

Detailed Description

A metadata table backed by a source Iceberg table.

Member Function Documentation

◆ kind()

virtual Kind iceberg::MetadataTable::kind ( ) const
pure virtualnoexcept

Return this metadata table's kind.

Implemented in iceberg::HistoryTable, iceberg::RefsTable, and iceberg::SnapshotsTable.

◆ MakeScan()

virtual Result< std::unique_ptr< MetadataScan > > iceberg::MetadataTable::MakeScan ( internal::MetadataScanContext  context) const
protectedpure virtual

Plan a scan using the captured metadata, projection, and snapshot selection.

Implemented in iceberg::HistoryTable, iceberg::RefsTable, and iceberg::SnapshotsTable.

◆ NewScan()

virtual Result< std::unique_ptr< MetadataScanBuilder > > iceberg::MetadataTable::NewScan ( ) const
virtual

Capture the source metadata and create a scan builder.

This metadata table must outlive the builder. Built scans retain their own inputs and can outlive both tables.

◆ schema()

virtual const std::shared_ptr< Schema > & iceberg::MetadataTable::schema ( ) const
pure virtual

Return the complete canonical schema of this metadata table.

Implemented in iceberg::HistoryTable, iceberg::RefsTable, and iceberg::SnapshotsTable.


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