taco-db  0.1.0
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
taco::TableDesc Class Reference

#include <catalog/TableDesc.h>

Public Member Functions

const SysTable_Table * GetTableEntry () const
 Returns the cached Table entry associated with this table descriptor. More...
 
const Schema * GetSchema () const
 Returns the cached table schema, which we guanrantee ‘IsLayoutComputed() == true’. More...
 

Static Public Member Functions

static TableDesc * Create (std::shared_ptr< const SysTable_Table > table, const std::vector< const SysTable_Column * > &columns)
 Creates a new table descriptor by building the schema object constructed from the columns (which performs lookups in the global catalog cache instance g_catcache). More...
 
static TableDesc * Create (std::shared_ptr< const SysTable_Table > table, std::unique_ptr< Schema > schema)
 This overload simply passes the arguments to the constructor. More...
 

Private Member Functions

 TableDesc (std::shared_ptr< const SysTable_Table > table, std::unique_ptr< Schema > schema)
 

Private Attributes

std::shared_ptr< const SysTable_Table > m_table
 
std::unique_ptr< Schema > m_schema
 

Constructor & Destructor Documentation

◆ TableDesc()

taco::TableDesc::TableDesc ( std::shared_ptr< const SysTable_Table >  table,
std::unique_ptr< Schema >  schema 
)
inlineprivate

Member Function Documentation

◆ Create() [1/2]

TableDesc * taco::TableDesc::Create ( std::shared_ptr< const SysTable_Table >  table,
const std::vector< const SysTable_Column * > &  columns 
)
static

Creates a new table descriptor by building the schema object constructed from the columns (which performs lookups in the global catalog cache instance g_catcache).

◆ Create() [2/2]

TableDesc * taco::TableDesc::Create ( std::shared_ptr< const SysTable_Table >  table,
std::unique_ptr< Schema >  schema 
)
static

This overload simply passes the arguments to the constructor.

◆ GetSchema()

const Schema* taco::TableDesc::GetSchema ( ) const
inline

Returns the cached table schema, which we guanrantee ‘IsLayoutComputed() == true’.

◆ GetTableEntry()

const SysTable_Table* taco::TableDesc::GetTableEntry ( ) const
inline

Returns the cached Table entry associated with this table descriptor.

Note that the table entry may be destructed as well if the table descriptor is destructed, so you must access the table entry while the table descriptor is still alive.

Member Data Documentation

◆ m_schema

std::unique_ptr<Schema> taco::TableDesc::m_schema
private

◆ m_table

std::shared_ptr<const SysTable_Table> taco::TableDesc::m_table
private

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