small structure used to parse main content of a spreadsheet/database zone More...
#include <CWDbaseContent.hxx>
Classes | |
struct | Column |
struct which stores a column in CWDbaseContent More... | |
struct | Record |
struct which stores a record in CWDbaseContent More... | |
Public Member Functions | |
CWDbaseContent (MWAWParserStatePtr parserState, shared_ptr< CWStyleManager > styleManager, bool spreadsheet) | |
constructor More... | |
~CWDbaseContent () | |
destructor More... | |
bool | readContent () |
try to read the record structure More... | |
bool | getExtrema (Vec2i &min, Vec2i &max) const |
returns the dimension of the read data More... | |
bool | getRecordList (std::vector< int > &list) const |
returns the list of filled record (for database) More... | |
bool | send (Vec2i const &pos) |
try to send a cell content to the listener More... | |
void | setDatabaseFormats (std::vector< CWStyleManager::CellFormat > const &format) |
set the field format ( for database ) More... | |
Protected Member Functions | |
bool | readColumnList () |
try to read the columns list structure(CTAB) More... | |
bool | readColumn (int c) |
try to read the column structure(COLM): a list of chnk More... | |
bool | readRecordList (Vec2i const &where, Column &col) |
try to read a list of records(CHNK) More... | |
bool | readRecordSS (Vec2i const &where, long pos, Record &record) |
try to read a spreadsheet record More... | |
bool | readRecordSSV1 (Vec2i const &where, long pos, Record &record) |
try to read a spreadsheet record(v1-v3) More... | |
bool | readRecordDB (Vec2i const &where, long pos, Record &record) |
try to read a database record More... | |
void | send (double val, bool isNotaNumber, CWStyleManager::CellFormat const &format) |
send a double with a corresponding cell format More... | |
Protected Attributes | |
int | m_version |
the file version More... | |
bool | m_isSpreadsheet |
a bool to know if this is a spreadsheet or a database More... | |
MWAWParserStatePtr | m_parserState |
the parser state More... | |
shared_ptr< CWStyleManager > | m_styleManager |
the style manager More... | |
std::map< int, Column > | m_idColumnMap |
a map col id to column More... | |
std::vector < CWStyleManager::CellFormat > | m_dbFormatList |
the databse format More... | |
small structure used to parse main content of a spreadsheet/database zone
CWDbaseContent::CWDbaseContent | ( | MWAWParserStatePtr | parserState, |
shared_ptr< CWStyleManager > | styleManager, | ||
bool | spreadsheet | ||
) |
constructor
CWDbaseContent::~CWDbaseContent | ( | ) |
destructor
returns the dimension of the read data
bool CWDbaseContent::getRecordList | ( | std::vector< int > & | list | ) | const |
returns the list of filled record (for database)
|
protected |
try to read the column structure(COLM): a list of chnk
Referenced by readColumnList().
|
protected |
try to read the columns list structure(CTAB)
Referenced by readContent().
bool CWDbaseContent::readContent | ( | ) |
try to read the record structure
ARGHH: this zone is almost the only zone which count the header in sz ...
|
protected |
try to read a database record
Referenced by readRecordList().
try to read a list of records(CHNK)
Referenced by readColumn().
|
protected |
try to read a spreadsheet record
checkme: there does not seem to be alignment, but another variable before the result
Referenced by readRecordList().
|
protected |
try to read a spreadsheet record(v1-v3)
Referenced by readRecordSS().
bool CWDbaseContent::send | ( | Vec2i const & | pos | ) |
try to send a cell content to the listener
|
protected |
send a double with a corresponding cell format
void CWDbaseContent::setDatabaseFormats | ( | std::vector< CWStyleManager::CellFormat > const & | format | ) |
set the field format ( for database )
|
protected |
the databse format
Referenced by send(), and setDatabaseFormats().
|
protected |
a map col id to column
Referenced by getExtrema(), getRecordList(), readColumn(), and send().
|
protected |
a bool to know if this is a spreadsheet or a database
Referenced by getRecordList(), readColumn(), readColumnList(), readContent(), readRecordList(), send(), and setDatabaseFormats().
|
protected |
the parser state
Referenced by CWDbaseContent(), readColumn(), readColumnList(), readContent(), readRecordDB(), readRecordList(), readRecordSS(), readRecordSSV1(), and send().
|
protected |
the style manager
Referenced by readRecordSS(), readRecordSSV1(), and send().
|
protected |
the file version
Referenced by CWDbaseContent(), readRecordDB(), readRecordSS(), and send().