#include <table_doc.hpp>
Type of supported items
Enumerator |
---|
IntegerType |
int
|
FloatType |
float
|
DoubleType |
double
|
StringType |
std::string
|
InvalidType |
Not supported table item type.
|
hds::TableDoc::TableDoc |
( |
const std::string & |
name = std::string() | ) |
|
Default constructor with it's name provided.
virtual hds::TableDoc::~TableDoc |
( |
| ) |
|
|
inlinevirtual |
virtual bool hds::TableDoc::canInsertRow |
( |
const size_t |
| ) |
const |
|
inlinevirtual |
Check whether row can be inserted.
- Parameters
-
cur_row | Index of row the new one to be added before. |
- Returns
- true if row can be inserted, otherwise false.
virtual bool hds::TableDoc::canRemoveRow |
( |
const size_t |
| ) |
const |
|
inlinevirtual |
Check whether row can be removed.
- Parameters
-
- Returns
- true if row can be removed, otherwise false.
virtual size_t hds::TableDoc::colsNum |
( |
| ) |
const |
|
pure virtual |
Get current number of columns.
virtual const HdrItem& hds::TableDoc::hdrItem |
( |
const size_t |
col | ) |
const |
|
pure virtual |
Get header item for provided column.
virtual bool hds::TableDoc::insertRow |
( |
const size_t |
cur_row | ) |
|
|
pure virtual |
Insert new row into the document. All new items should have theirs default types and values.
- Parameters
-
cur_row | Index of row the new one to be added before. If cur_row is out of range new one should appended at the end of the table. |
- Returns
- true if added correctly or false on error.
virtual const AbstractItem& hds::TableDoc::item |
( |
const size_t |
row, |
|
|
const size_t |
col |
|
) |
| const |
|
pure virtual |
Get item for provided column and row.
- Returns
- required item or item of invalid type on error, e.g.
- Parameters
-
row | or |
col | is out of range. |
const std::string& hds::TableDoc::name |
( |
| ) |
const |
Get name of the document.
virtual bool hds::TableDoc::removeRow |
( |
const size_t |
row | ) |
|
|
pure virtual |
Remove one row with provided index.
- Parameters
-
- Returns
- true if row removed correctly or false on error.
virtual size_t hds::TableDoc::rowsNum |
( |
| ) |
const |
|
pure virtual |
Get current number of rows.
virtual bool hds::TableDoc::setItem |
( |
const size_t |
row, |
|
|
const size_t |
col, |
|
|
const AbstractItem & |
item |
|
) |
| |
|
pure virtual |
Set item for provided column and row.
- Returns
- false if indexes are out of range or item can't be set.
The documentation for this class was generated from the following file:
- /net/opt/univers/ubp-i-15.3-centos7-x64.urij/include/hds_widgets/table_doc.hpp