Column Store
Public Member Functions | Private Attributes | List of all members
Parser::Table Class Reference

#include <Table.h>

Collaboration diagram for Parser::Table:
Collaboration graph

Public Member Functions

void set_table_name (std::string table_n)
 
void set_primary_key (std::string pk)
 
void add_column (std::string column_name, std::string data_type, int size=0)
 
void add_foreign_key (std::string from, std::string table, std::string to)
 
std::string get_table_name ()
 
std::string get_primary_key ()
 
std::vector< foreign_key > & get_foreign_keys ()
 
std::vector< Parser::Column > & get_columns ()
 
Parser::Columnoperator[] (int i)
 
Parser::Columnget_column (std::string name)
 
Parser::Columnoperator[] (std::string name)
 

Private Attributes

std::string table_name
 
std::unordered_map< std::string, int > column_map
 
std::vector< Parser::Columncolumns
 
std::string primary_key
 
std::vector< foreign_keyforeign_keys
 

Member Function Documentation

◆ add_column()

void Parser::Table::add_column ( std::string  column_name,
std::string  data_type,
int  size = 0 
)
Here is the caller graph for this function:

◆ add_foreign_key()

void Parser::Table::add_foreign_key ( std::string  from,
std::string  table,
std::string  to 
)
Here is the caller graph for this function:

◆ get_column()

Parser::Column& Parser::Table::get_column ( std::string  name)
inline

◆ get_columns()

std::vector<Parser::Column>& Parser::Table::get_columns ( )
inline
Here is the caller graph for this function:

◆ get_foreign_keys()

std::vector<foreign_key>& Parser::Table::get_foreign_keys ( )
inline

◆ get_primary_key()

std::string Parser::Table::get_primary_key ( )
inline

◆ get_table_name()

std::string Parser::Table::get_table_name ( )
inline
Here is the caller graph for this function:

◆ operator[]() [1/2]

Parser::Column& Parser::Table::operator[] ( int  i)
inline

◆ operator[]() [2/2]

Parser::Column& Parser::Table::operator[] ( std::string  name)
inline

◆ set_primary_key()

void Parser::Table::set_primary_key ( std::string  pk)
inline
Here is the caller graph for this function:

◆ set_table_name()

void Parser::Table::set_table_name ( std::string  table_n)
inline
Here is the caller graph for this function:

Member Data Documentation

◆ column_map

std::unordered_map<std::string, int> Parser::Table::column_map
private

◆ columns

std::vector<Parser::Column> Parser::Table::columns
private

◆ foreign_keys

std::vector<foreign_key> Parser::Table::foreign_keys
private

◆ primary_key

std::string Parser::Table::primary_key
private

◆ table_name

std::string Parser::Table::table_name
private

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