libebook::FictionBook2CellContext Class Reference

#include <FictionBook2TableContext.h>

Inheritance diagram for libebook::FictionBook2CellContext:
libebook::FictionBook2StyleContextBase libebook::FictionBook2ParserContext libebook::FictionBook2XMLParserContext

Public Member Functions

 FictionBook2CellContext (FictionBook2ParserContext *parentContext, const std::shared_ptr< FictionBook2TableModel > &model, const FictionBook2BlockFormat &format, bool header)
 
- Public Member Functions inherited from libebook::FictionBook2StyleContextBase
 FictionBook2StyleContextBase (FictionBook2ParserContext *parentContext, const FictionBook2Style &style)
 
- Public Member Functions inherited from libebook::FictionBook2ParserContext
 FictionBook2ParserContext (FictionBook2ParserContext *parentContext, FictionBook2Collector *collector=nullptr)
 Create a new context with parentContext as parent. More...
 
FictionBook2XMLParserContextleaveContext () const override
 Destroy this context and return parent. More...
 
FictionBook2CollectorgetCollector () const
 Get the collector. More...
 
FictionBook2ParserContextgetParentContext () const
 Get the parent context. More...
 
- Public Member Functions inherited from libebook::FictionBook2XMLParserContext
virtual ~FictionBook2XMLParserContext ()=0
 
virtual FictionBook2XMLParserContextleaveContext () const =0
 Destroy this context and return parent. More...
 
virtual FictionBook2XMLParserContextelement (const FictionBook2TokenData &name, const FictionBook2TokenData &ns)=0
 Create a context for parsing a child element. More...
 
virtual void startOfElement ()=0
 Signalize the start of an element. More...
 
virtual void endOfElement ()=0
 Signalize the end of an element. More...
 
virtual void attribute (const FictionBook2TokenData &name, const FictionBook2TokenData *ns, const char *value)=0
 Process an attribute. More...
 
virtual void endOfAttributes ()=0
 Signalize the end of attributes. More...
 
virtual void text (const char *value)=0
 Process textual content of an element. More...
 

Private Member Functions

 FictionBook2CellContext (const FictionBook2CellContext &other)
 
FictionBook2CellContextoperator= (const FictionBook2CellContext &other)
 
void startOfElement () override
 Signalize the start of an element. More...
 
void endOfElement () override
 Signalize the end of an element. More...
 
void attribute (const FictionBook2TokenData &name, const FictionBook2TokenData *ns, const char *value) override
 Process an attribute. More...
 
void endOfAttributes () override
 Signalize the end of attributes. More...
 
void openCell ()
 

Private Attributes

const std::shared_ptr< FictionBook2TableModelm_model
 
const bool m_header
 
bool m_opened
 
int m_columnSpan
 
int m_rowSpan
 
size_t m_coveredColumns
 

Additional Inherited Members

- Protected Member Functions inherited from libebook::FictionBook2StyleContextBase
FictionBook2StylegetStyle ()
 
FictionBook2TextFormatgetTextFormat ()
 
FictionBook2XMLParserContextelement (const FictionBook2TokenData &name, const FictionBook2TokenData &ns) override
 Create a context for parsing a child element. More...
 
void endOfElement () override
 Signalize the end of an element. More...
 
void attribute (const FictionBook2TokenData &name, const FictionBook2TokenData *ns, const char *value) override
 Process an attribute. More...
 
void endOfAttributes () override
 Signalize the end of attributes. More...
 
void text (const char *value) override
 Process textual content of an element. More...
 

Constructor & Destructor Documentation

◆ FictionBook2CellContext() [1/2]

libebook::FictionBook2CellContext::FictionBook2CellContext ( const FictionBook2CellContext other)
private

◆ FictionBook2CellContext() [2/2]

libebook::FictionBook2CellContext::FictionBook2CellContext ( FictionBook2ParserContext parentContext,
const std::shared_ptr< FictionBook2TableModel > &  model,
const FictionBook2BlockFormat format,
bool  header 
)

Member Function Documentation

◆ attribute()

void libebook::FictionBook2CellContext::attribute ( const FictionBook2TokenData name,
const FictionBook2TokenData ns,
const char *  value 
)
overrideprivatevirtual

Process an attribute.

Attributes are handled to the current element's context one by one.

Reimplemented from libebook::FictionBook2StyleContextBase.

◆ endOfAttributes()

void libebook::FictionBook2CellContext::endOfAttributes ( )
overrideprivatevirtual

Signalize the end of attributes.

Reimplemented from libebook::FictionBook2StyleContextBase.

◆ endOfElement()

void libebook::FictionBook2CellContext::endOfElement ( )
overrideprivatevirtual

Signalize the end of an element.

Reimplemented from libebook::FictionBook2StyleContextBase.

◆ openCell()

void libebook::FictionBook2CellContext::openCell ( )
private

Referenced by endOfAttributes(), and endOfElement().

◆ operator=()

FictionBook2CellContext & libebook::FictionBook2CellContext::operator= ( const FictionBook2CellContext other)
private

◆ startOfElement()

void libebook::FictionBook2CellContext::startOfElement ( )
overrideprivatevirtual

Signalize the start of an element.

This can be used if initialization of the context needs virtual function calls.

Implements libebook::FictionBook2XMLParserContext.

Member Data Documentation

◆ m_columnSpan

int libebook::FictionBook2CellContext::m_columnSpan
private

Referenced by attribute(), and openCell().

◆ m_coveredColumns

size_t libebook::FictionBook2CellContext::m_coveredColumns
private

Referenced by endOfElement(), and openCell().

◆ m_header

const bool libebook::FictionBook2CellContext::m_header
private

◆ m_model

const std::shared_ptr<FictionBook2TableModel> libebook::FictionBook2CellContext::m_model
private

Referenced by openCell().

◆ m_opened

bool libebook::FictionBook2CellContext::m_opened
private

Referenced by endOfElement(), and openCell().

◆ m_rowSpan

int libebook::FictionBook2CellContext::m_rowSpan
private

Referenced by attribute(), and openCell().


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

Generated for libe-book by doxygen 1.9.3