The almost abstract base class for grid tables.
A grid table is responsible for storing the grid data and, indirectly, grid
cell attributes. The data can be stored in the way most convenient for the
application but has to be provided in string form to grid.Grid
.
Default class constructor. |
|
Return the attribute for the given cell. |
|
Returns the number of columns in the table. |
|
Returns the number of rows in the table. |
|
Returns the “raw” value for the cell content. |
|
Returns the cell content for the specified row and column. |
|
sets the cell content for the specified row and column. |
XLSTable
(gridlib.GridTableBase)¶The almost abstract base class for grid tables.
A grid table is responsible for storing the grid data and, indirectly, grid
cell attributes. The data can be stored in the way most convenient for the
application but has to be provided in string form to grid.Grid
.
__init__
(self, grid, cells, rows, cols)¶Default class constructor.
grid – an instance of grid.Grid
;
cells – a Python dictionary. For every key (row, col), the
corresponding value is an instance of XLSCell
;
rows – the number of rows in the table;
cols – the number of columns in the table.
GetAttr
(self, row, col, kind)¶Return the attribute for the given cell.
row – the row in which this cell lives;
col – the column in which this cell lives;
kind – the kind of the attribute to return.
GetNumberCols
(self)¶Returns the number of columns in the table.
GetNumberRows
(self)¶Returns the number of rows in the table.
GetRawValue
(self, row, col)¶Returns the “raw” value for the cell content.
row – the row in which this cell lives;
col – the column in which this cell lives.
GetValue
(self, row, col)¶Returns the cell content for the specified row and column.
row – the row in which this cell lives;
col – the column in which this cell lives.
SetValue
(self, row, col, value)¶sets the cell content for the specified row and column.
row – the row in which this cell lives;
col – the column in which this cell lives;
value – the new value to assign to the specified cell.