RagTimeSpreadsheet Class Reference

the main class to read the spreadsheet part of ragTime file More...

#include <RagTimeSpreadsheet.hxx>

Public Member Functions

 RagTimeSpreadsheet (RagTimeParser &parser)
 constructor More...
 
virtual ~RagTimeSpreadsheet ()
 destructor More...
 
int version () const
 returns the file version More...
 

Protected Member Functions

bool getDateTimeFormat (int dtId, std::string &dtFormat) const
 returns the ith date format or "" More...
 
bool readNumericFormat (MWAWEntry &entry)
 try to read the numeric/date format table zone: FoTa More...
 
bool readResource (MWAWEntry &entry)
 try to read a SpXX resource More...
 
bool readRsrcSpDo (MWAWEntry &entry)
 try to read the SpDo zone (a spreadsheet zone with id=0) More...
 
bool readRsrcSpDI (MWAWEntry &entry)
 try to read the SpDI zone (a spreadsheet zone zone with id=0) More...
 
bool readSpreadsheet (MWAWEntry &entry)
 try to read a spreadsheet zone: v3-... More...
 
bool readSpreadsheetZone9 (MWAWEntry const &entry, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read a the last spreadsheet zone More...
 
bool readSpreadsheetSimpleStructure (MWAWEntry const &entry, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read a simple structured spreadsheet zone More...
 
bool readSpreadsheetComplexStructure (MWAWEntry const &entry, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read a complex structured spreadsheet zone More...
 
bool readSpreadsheetCellContent (RagTimeSpreadsheetInternal::Cell &cell, long endPos)
 try to read a spreadsheet cells content More...
 
bool readSpreadsheetCellDimension (MWAWVec2i const &cellPos, long endPos, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read a spreadsheet cells dimension More...
 
bool readSpreadsheetCellFormat (MWAWVec2i const &cellPos, long endPos, RagTimeSpreadsheetInternal::Cell &cell)
 try to read a spreadsheet cell's format More...
 
bool readPositionsList (MWAWEntry const &entry, std::vector< long > &posList, long &lastDataPos)
 try to read a list of position More...
 
bool readBlockHeader (MWAWEntry const &entry, RagTimeSpreadsheetInternal::ComplexBlock &block)
 try to read a complex bock header More...
 
bool readSpreadsheetV2 (MWAWEntry &entry)
 try to read spreadsheet zone ( a big zone):v2 More...
 
bool readSpreadsheetCellsV2 (MWAWEntry &entry, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read spreadsheet cells :v2 More...
 
bool readSpreadsheetExtraV2 (MWAWEntry &entry, RagTimeSpreadsheetInternal::Spreadsheet &sheet)
 try to read spreadsheet end zone (positions, ...) :v2 More...
 
bool send (int zId, MWAWPosition const &pos)
 send a spreadsheet corresponding to zId More...
 
void flushExtra ()
 flush extra data More...
 
bool readSpreadsheetCellV2 (RagTimeSpreadsheetInternal::Cell &cell, long endPos)
 try to read a cell :v2 More...
 
bool readFormulaV2 (MWAWVec2i const &cellPos, std::vector< MWAWCellContent::FormulaInstruction > &formula, long endPos, std::string &extra)
 try to read a formula More...
 
bool readFormula (MWAWVec2i const &cellPos, std::vector< MWAWCellContent::FormulaInstruction > &formula, long endPos, std::string &extra)
 try to read a formula: v3... More...
 
bool readCellInFormulaV2 (MWAWVec2i const &pos, bool canBeList, MWAWCellContent::FormulaInstruction &instr, long endPos, std::string &extra)
 try to read a cell in a formula More...
 
bool readCellInFormula (MWAWVec2i const &pos, bool canBeList, MWAWCellContent::FormulaInstruction &instr, long endPos, std::string &extra)
 try to read a cell in a formula More...
 
bool send (RagTimeSpreadsheetInternal::Spreadsheet &sheet, MWAWSpreadsheetListenerPtr listener)
 send a spreadsheet to a listener More...
 

Protected Attributes

MWAWParserStatePtr m_parserState
 the parser state More...
 
std::shared_ptr< RagTimeSpreadsheetInternal::Statem_state
 the state More...
 
RagTimeParserm_mainParser
 the main parser; More...
 

Private Member Functions

 RagTimeSpreadsheet (RagTimeSpreadsheet const &orig)=delete
 
RagTimeSpreadsheetoperator= (RagTimeSpreadsheet const &orig)=delete
 

Friends

class RagTimeParser
 

Detailed Description

the main class to read the spreadsheet part of ragTime file

Constructor & Destructor Documentation

◆ RagTimeSpreadsheet() [1/2]

RagTimeSpreadsheet::RagTimeSpreadsheet ( RagTimeParser parser)
explicit

constructor

◆ ~RagTimeSpreadsheet()

RagTimeSpreadsheet::~RagTimeSpreadsheet ( )
virtual

destructor

◆ RagTimeSpreadsheet() [2/2]

RagTimeSpreadsheet::RagTimeSpreadsheet ( RagTimeSpreadsheet const &  orig)
privatedelete

Member Function Documentation

◆ flushExtra()

void RagTimeSpreadsheet::flushExtra ( )
protected

flush extra data

◆ getDateTimeFormat()

bool RagTimeSpreadsheet::getDateTimeFormat ( int  dtId,
std::string &  dtFormat 
) const
protected

returns the ith date format or ""

◆ operator=()

RagTimeSpreadsheet& RagTimeSpreadsheet::operator= ( RagTimeSpreadsheet const &  orig)
privatedelete

◆ readBlockHeader()

bool RagTimeSpreadsheet::readBlockHeader ( MWAWEntry const &  entry,
RagTimeSpreadsheetInternal::ComplexBlock block 
)
protected

try to read a complex bock header

Referenced by readSpreadsheetComplexStructure().

◆ readCellInFormula()

bool RagTimeSpreadsheet::readCellInFormula ( MWAWVec2i const &  pos,
bool  canBeList,
MWAWCellContent::FormulaInstruction instr,
long  endPos,
std::string &  extra 
)
protected

try to read a cell in a formula

Referenced by readFormula().

◆ readCellInFormulaV2()

bool RagTimeSpreadsheet::readCellInFormulaV2 ( MWAWVec2i const &  pos,
bool  canBeList,
MWAWCellContent::FormulaInstruction instr,
long  endPos,
std::string &  extra 
)
protected

try to read a cell in a formula

Referenced by readFormulaV2().

◆ readFormula()

bool RagTimeSpreadsheet::readFormula ( MWAWVec2i const &  cellPos,
std::vector< MWAWCellContent::FormulaInstruction > &  formula,
long  endPos,
std::string &  extra 
)
protected

try to read a formula: v3...

Referenced by readSpreadsheetComplexStructure().

◆ readFormulaV2()

bool RagTimeSpreadsheet::readFormulaV2 ( MWAWVec2i const &  cellPos,
std::vector< MWAWCellContent::FormulaInstruction > &  formula,
long  endPos,
std::string &  extra 
)
protected

try to read a formula

Referenced by readSpreadsheetCellV2().

◆ readNumericFormat()

bool RagTimeSpreadsheet::readNumericFormat ( MWAWEntry entry)
protected

try to read the numeric/date format table zone: FoTa

◆ readPositionsList()

bool RagTimeSpreadsheet::readPositionsList ( MWAWEntry const &  entry,
std::vector< long > &  posList,
long &  lastDataPos 
)
protected

try to read a list of position

Referenced by readSpreadsheetComplexStructure().

◆ readResource()

bool RagTimeSpreadsheet::readResource ( MWAWEntry entry)
protected

try to read a SpXX resource

◆ readRsrcSpDI()

bool RagTimeSpreadsheet::readRsrcSpDI ( MWAWEntry entry)
protected

try to read the SpDI zone (a spreadsheet zone zone with id=0)

Referenced by readResource().

◆ readRsrcSpDo()

bool RagTimeSpreadsheet::readRsrcSpDo ( MWAWEntry entry)
protected

try to read the SpDo zone (a spreadsheet zone with id=0)

Referenced by readResource().

◆ readSpreadsheet()

bool RagTimeSpreadsheet::readSpreadsheet ( MWAWEntry entry)
protected

try to read a spreadsheet zone: v3-...

◆ readSpreadsheetCellContent()

bool RagTimeSpreadsheet::readSpreadsheetCellContent ( RagTimeSpreadsheetInternal::Cell cell,
long  endPos 
)
protected

try to read a spreadsheet cells content

Referenced by readSpreadsheetComplexStructure().

◆ readSpreadsheetCellDimension()

bool RagTimeSpreadsheet::readSpreadsheetCellDimension ( MWAWVec2i const &  cellPos,
long  endPos,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read a spreadsheet cells dimension

Referenced by readSpreadsheetComplexStructure().

◆ readSpreadsheetCellFormat()

bool RagTimeSpreadsheet::readSpreadsheetCellFormat ( MWAWVec2i const &  cellPos,
long  endPos,
RagTimeSpreadsheetInternal::Cell cell 
)
protected

try to read a spreadsheet cell's format

Referenced by readSpreadsheetComplexStructure().

◆ readSpreadsheetCellsV2()

bool RagTimeSpreadsheet::readSpreadsheetCellsV2 ( MWAWEntry entry,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read spreadsheet cells :v2

Referenced by readSpreadsheetV2().

◆ readSpreadsheetCellV2()

bool RagTimeSpreadsheet::readSpreadsheetCellV2 ( RagTimeSpreadsheetInternal::Cell cell,
long  endPos 
)
protected

try to read a cell :v2

Referenced by readSpreadsheetCellsV2().

◆ readSpreadsheetComplexStructure()

bool RagTimeSpreadsheet::readSpreadsheetComplexStructure ( MWAWEntry const &  entry,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read a complex structured spreadsheet zone

Referenced by readSpreadsheet().

◆ readSpreadsheetExtraV2()

bool RagTimeSpreadsheet::readSpreadsheetExtraV2 ( MWAWEntry entry,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read spreadsheet end zone (positions, ...) :v2

Referenced by readSpreadsheetV2().

◆ readSpreadsheetSimpleStructure()

bool RagTimeSpreadsheet::readSpreadsheetSimpleStructure ( MWAWEntry const &  entry,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read a simple structured spreadsheet zone

Referenced by readSpreadsheet().

◆ readSpreadsheetV2()

bool RagTimeSpreadsheet::readSpreadsheetV2 ( MWAWEntry entry)
protected

try to read spreadsheet zone ( a big zone):v2

◆ readSpreadsheetZone9()

bool RagTimeSpreadsheet::readSpreadsheetZone9 ( MWAWEntry const &  entry,
RagTimeSpreadsheetInternal::Spreadsheet sheet 
)
protected

try to read a the last spreadsheet zone

Referenced by readSpreadsheet().

◆ send() [1/2]

bool RagTimeSpreadsheet::send ( int  zId,
MWAWPosition const &  pos 
)
protected

send a spreadsheet corresponding to zId

Referenced by flushExtra().

◆ send() [2/2]

bool RagTimeSpreadsheet::send ( RagTimeSpreadsheetInternal::Spreadsheet sheet,
MWAWSpreadsheetListenerPtr  listener 
)
protected

send a spreadsheet to a listener

◆ version()

int RagTimeSpreadsheet::version ( ) const

returns the file version

Referenced by readPositionsList(), readSpreadsheet(), and readSpreadsheetV2().

Friends And Related Function Documentation

◆ RagTimeParser

friend class RagTimeParser
friend

Member Data Documentation

◆ m_mainParser

RagTimeParser* RagTimeSpreadsheet::m_mainParser
protected

◆ m_parserState

◆ m_state


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

Generated for libmwaw by doxygen 1.8.14