Represents a table in vkdb.
More...
#include <table.h>
|
|
| Table ()=delete |
| | Deleted default constructor.
|
| |
| | Table (const FilePath &db_path, const TableName &name) |
| | Construct a new Table object.
|
| |
|
| Table (Table &&) noexcept=default |
| | Move-construct a new Table object.
|
| |
|
Table & | operator= (Table &&) noexcept=default |
| | Move-assign a new Table object.
|
| |
|
| Table (const Table &)=delete |
| | Deleted copy constructor.
|
| |
|
Table & | operator= (const Table &)=delete |
| | Deleted copy assignment operator.
|
| |
|
| ~Table () noexcept=default |
| | Destroy the Table object.
|
| |
| Table & | setTagColumns (const TagColumns &tag_columns) noexcept |
| | Set the TagColumns object.
|
| |
| Table & | addTagColumn (const TagKey &tag_column) |
| | Add a tag column.
|
| |
| Table & | removeTagColumn (const TagKey &tag_column) |
| | Remove a tag column.
|
| |
| void | clear () const noexcept |
| | Clear the table.
|
| |
| FriendlyQueryBuilder< double > | query () noexcept |
| | Get a FriendlyQueryBuilder object.
|
| |
| TableName | name () const noexcept |
| | Get the name of the table.
|
| |
| TagColumns | tagColumns () const noexcept |
| | Get the TagColumns object.
|
| |
| FilePath | path () const noexcept |
| | Get the path to the table directory.
|
| |
Represents a table in vkdb.
Definition at line 32 of file table.h.
◆ Table()
| vkdb::Table::Table |
( |
const FilePath & | db_path, |
|
|
const TableName & | name ) |
|
explicit |
Construct a new Table object.
Loads the table if it exists.
- Parameters
-
| db_path | Path to the database directory. |
| name | Name of the table. |
- Exceptions
-
| std::runtime_error | If loading the table fails. |
Definition at line 6 of file table.cpp.
◆ addTagColumn()
| Table & vkdb::Table::addTagColumn |
( |
const TagKey & | tag_column | ) |
|
Add a tag column.
- Parameters
-
- Returns
- Table& Reference to the table.
- Exceptions
-
| std::runtime_error | If the table has previously been populated with data or the tag column already exists. |
Definition at line 18 of file table.cpp.
◆ clear()
| void vkdb::Table::clear |
( |
| ) |
const |
|
noexcept |
Clear the table.
Clears the table directory.
Definition at line 54 of file table.cpp.
◆ name()
| TableName vkdb::Table::name |
( |
| ) |
const |
|
nodiscardnoexcept |
Get the name of the table.
- Returns
- TableName Name of the table.
Definition at line 63 of file table.cpp.
◆ path()
| FilePath vkdb::Table::path |
( |
| ) |
const |
|
nodiscardnoexcept |
Get the path to the table directory.
- Returns
- FilePath Path to the directory.
Definition at line 71 of file table.cpp.
◆ query()
◆ removeTagColumn()
| Table & vkdb::Table::removeTagColumn |
( |
const TagKey & | tag_column | ) |
|
Remove a tag column.
- Parameters
-
- Returns
- Table& Reference to the table.
- Exceptions
-
| std::runtime_error | If the table has previously been populated with data or the tag column does not exist. |
Definition at line 36 of file table.cpp.
◆ setTagColumns()
| Table & vkdb::Table::setTagColumns |
( |
const TagColumns & | tag_columns | ) |
|
|
noexcept |
Set the TagColumns object.
- Parameters
-
- Returns
- Table& Reference to the table.
Definition at line 13 of file table.cpp.
◆ tagColumns()
| TagColumns vkdb::Table::tagColumns |
( |
| ) |
const |
|
nodiscardnoexcept |
Get the TagColumns object.
- Returns
- TagColumns Tag columns.
Definition at line 67 of file table.cpp.
The documentation for this class was generated from the following files:
- /home/runner/work/vkdb/vkdb/include/database/vkdb/table.h
- /home/runner/work/vkdb/vkdb/src/database/table.cpp