DocPara Class Reference

#include <docparser.h>

Inheritance diagram for DocPara:

CompAccept< DocPara > DocNode List of all members.

Public Member Functions

 DocPara (DocNode *parent)
int parse ()
Kind kind () const
DocNodeparent () const
bool isEmpty () const
void accept (DocVisitor *v)
void markFirst (bool v=TRUE)
void markLast (bool v=TRUE)
bool isFirst () const
bool isLast () const
const QList< DocNode > & children () const
QList< DocNode > & children ()
int handleCommand (const QString &cmdName)
int handleHtmlStartTag (const QString &tagName, const HtmlAttribList &tagHtmlAttribs)
int handleHtmlEndTag (const QString &tagName)
int handleSimpleSection (DocSimpleSect::Type t, bool xmlContext=FALSE)
int handleXRefItem ()
int handleParamSection (const QString &cmdName, DocParamSect::Type t, bool xmlContext, int direction)
void handleIncludeOperator (const QString &cmdName, DocIncOperator::Type t)
void handleImage (const QString &cmdName)
void handleDotFile (const QString &cmdName)
void handleInclude (const QString &cmdName, DocInclude::Type t)
void handleLink (const QString &cmdName, bool isJavaLink)
void handleRef (const QString &cmdName)
void handleSection (const QString &cmdName)
void handleInheritDoc ()
int handleStartCode ()
int handleHtmlHeader (const HtmlAttribList &tagHtmlAttribs, int level)
bool injectToken (int tok, const QString &tokText)

Detailed Description

Node representing a paragraph in the documentation tree

Definition at line 963 of file docparser.h.


Constructor & Destructor Documentation

DocPara::DocPara ( DocNode parent  )  [inline]

Definition at line 966 of file docparser.h.


Member Function Documentation

int DocPara::parse (  ) 

Definition at line 5377 of file docparser.cpp.

References TokenInfo::attribs, TokenInfo::chars, CMD_LI, Mappers::cmdMapper, DBG, DocSymbol::decodeSymbol(), doctokenizerYYlex(), doctokenizerYYlineno, TokenInfo::endTag, g_token, handleCommand(), handleHtmlEndTag(), handleHtmlStartTag(), DocAutoList::indent(), TokenInfo::indent, INTERNAL_ASSERT, TokenInfo::isEMailAddr, TokenInfo::isEnumList, DocNode::kind(), kind(), DocNode::Kind_AutoList, DocNode::Kind_AutoListItem, DocNode::Kind_HtmlDescList, DocNode::Kind_HtmlHeader, DocNode::Kind_HtmlList, DocNode::Kind_HtmlTable, DocNode::Kind_ParamSect, DocNode::Kind_SimpleList, DocNode::Kind_SimpleListItem, DocNode::Kind_SimpleSect, DocNode::Kind_XRefItem, CompAccept< DocPara >::m_children, Mapper::map(), TokenInfo::name, DocNode::parent(), parent(), DocAutoList::parse(), DocSimpleSect::parseRcs(), DocSimpleSect::Rcs, RetVal_ListItem, RetVal_OK, RetVal_SimpleSec, SIMPLESECT_BIT, TokenInfo::simpleSectName, TokenInfo::simpleSectText, TokenInfo::text, TK_COMMAND, TK_ENDLIST, TK_HTMLTAG, TK_LISTITEM, TK_LNKWORD, TK_NEWPARA, TK_RCSTAG, TK_SYMBOL, TK_URL, TK_WHITESPACE, TK_WORD, tokToString(), DocSymbol::Unknown, and warn_doc_error().

Referenced by DocRoot::parse(), DocSection::parse(), DocParamList::parse(), DocSimpleSect::parse(), DocAutoListItem::parse(), DocSimpleListItem::parse(), DocHtmlListItem::parse(), DocHtmlDescData::parse(), DocHtmlCell::parse(), DocInternal::parse(), DocParamList::parseXml(), DocSimpleSect::parseXml(), DocHtmlListItem::parseXml(), and DocHtmlCell::parseXml().

Kind DocPara::kind (  )  const [inline, virtual]

Returns the kind of node. Provides runtime type information

Implements DocNode.

Definition at line 969 of file docparser.h.

References DocNode::Kind_Para.

Referenced by parse().

DocNode* DocPara::parent (  )  const [inline, virtual]

Returns the parent of this node or 0 for the root node.

Implements DocNode.

Definition at line 970 of file docparser.h.

Referenced by parse(), RTFDocVisitor::visitPost(), ManDocVisitor::visitPost(), LatexDocVisitor::visitPost(), and HtmlDocVisitor::visitPost().

bool DocPara::isEmpty (  )  const [inline]

Definition at line 971 of file docparser.h.

References CompAccept< DocPara >::m_children.

Referenced by DocRoot::parse(), DocSection::parse(), DocInternal::parse(), and DocParamList::parseXml().

void DocPara::accept ( DocVisitor v  )  [inline, virtual]

Acceptor function for node visitors. Part of the visitor pattern.

Parameters:
v Abstract visitor.

Implements DocNode.

Definition at line 972 of file docparser.h.

References CompAccept< T >::accept().

Referenced by DocSimpleListItem::accept(), and DocAutoListItem::accept().

void DocPara::markFirst ( bool  v = TRUE  )  [inline]

Definition at line 973 of file docparser.h.

Referenced by DocRoot::parse(), DocSection::parse(), DocParamList::parse(), DocSimpleSect::parse(), DocAutoListItem::parse(), DocSimpleListItem::parse(), DocHtmlListItem::parse(), DocHtmlDescData::parse(), DocHtmlCell::parse(), DocInternal::parse(), DocParamList::parseXml(), DocSimpleSect::parseXml(), DocHtmlListItem::parseXml(), and DocHtmlCell::parseXml().

void DocPara::markLast ( bool  v = TRUE  )  [inline]

Definition at line 974 of file docparser.h.

Referenced by DocRoot::parse(), DocSection::parse(), DocParamList::parse(), DocSimpleSect::parse(), DocAutoListItem::parse(), DocSimpleListItem::parse(), DocHtmlListItem::parse(), DocHtmlDescData::parse(), DocHtmlCell::parse(), DocInternal::parse(), DocParamList::parseXml(), DocSimpleSect::parseXml(), DocHtmlListItem::parseXml(), and DocHtmlCell::parseXml().

bool DocPara::isFirst (  )  const [inline]

Definition at line 975 of file docparser.h.

bool DocPara::isLast (  )  const [inline]

Definition at line 976 of file docparser.h.

Referenced by RTFDocVisitor::visitPost(), ManDocVisitor::visitPost(), LatexDocVisitor::visitPost(), and HtmlDocVisitor::visitPost().

const QList<DocNode>& DocPara::children (  )  const [inline]

Definition at line 977 of file docparser.h.

References CompAccept< DocPara >::m_children.

QList<DocNode>& DocPara::children (  )  [inline]

Definition at line 978 of file docparser.h.

References CompAccept< DocPara >::m_children.

int DocPara::handleCommand ( const QString &  cmdName  ) 

Definition at line 4435 of file docparser.cpp.

References DocSymbol::Amp, DocSymbol::At, DocSimpleSect::Attention, DocSimpleSect::Author, DocSimpleSect::Authors, DocStyleChange::Bold, DocSymbol::BSlash, CMD_ADDINDEX, CMD_AMP, CMD_ANCHOR, CMD_AT, CMD_ATTENTION, CMD_AUTHOR, CMD_AUTHORS, CMD_BOLD, CMD_BSLASH, CMD_CODE, CMD_COPYDOC, CMD_DATE, CMD_DOLLAR, CMD_DONTINCLUDE, CMD_DOT, CMD_DOTFILE, CMD_EMPHASIS, CMD_ENDCODE, CMD_ENDDOT, CMD_ENDHTMLONLY, CMD_ENDLATEXONLY, CMD_ENDLINK, CMD_ENDMANONLY, CMD_ENDMSC, CMD_ENDSECREFLIST, CMD_ENDVERBATIM, CMD_ENDXMLONLY, CMD_EXCEPTION, CMD_FORMULA, CMD_GREATER, CMD_HASH, CMD_HTMLINCLUDE, CMD_HTMLONLY, CMD_IMAGE, CMD_INCLUDE, CMD_INCWITHLINES, CMD_INHERITDOC, CMD_INTERNAL, CMD_INTERNALREF, CMD_INVARIANT, CMD_JAVALINK, CMD_LATEXONLY, CMD_LESS, CMD_LI, CMD_LINE, CMD_LINEBREAK, CMD_LINK, CMD_MANONLY, CMD_MSC, CMD_NOTE, CMD_PAR, CMD_PARAGRAPH, CMD_PARAM, CMD_PERCENT, CMD_POST, CMD_PRE, CMD_REF, CMD_REMARK, CMD_RETURN, CMD_RETVAL, CMD_SA, CMD_SECREFITEM, CMD_SECREFLIST, CMD_SECTION, CMD_SINCE, CMD_SKIP, CMD_SKIPLINE, CMD_STARTCODE, CMD_SUBPAGE, CMD_SUBSECTION, CMD_SUBSUBSECTION, CMD_TPARAM, CMD_UNKNOWN, CMD_UNTIL, CMD_VERBATIM, CMD_VERBINCLUDE, CMD_VERSION, CMD_WARNING, CMD_XMLONLY, CMD_XREFITEM, Mappers::cmdMapper, DocStyleChange::Code, DocSimpleSect::Date, DBG, doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStateCode(), doctokenizerYYsetStateDot(), doctokenizerYYsetStateHtmlOnly(), doctokenizerYYsetStateLatexOnly(), doctokenizerYYsetStateManOnly(), doctokenizerYYsetStateMsc(), doctokenizerYYsetStatePara(), doctokenizerYYsetStateVerbatim(), doctokenizerYYsetStateXmlOnly(), DocSymbol::Dollar, DocInclude::DontInclude, DocVerbatim::Dot, DocParamSect::Exception, g_token, DocSymbol::Greater, handleDotFile(), handleImage(), handleInclude(), handleIncludeOperator(), handleInheritDoc(), handleLink(), handleParamSection(), handleRef(), handleSection(), handleSimpleSection(), handleStartCode(), handleXRefItem(), DocSymbol::Hash, DocInclude::HtmlInclude, DocVerbatim::HtmlOnly, TokenInfo::id, DocInclude::Include, DocInclude::IncWithLines, INTERNAL_ASSERT, DocSimpleSect::Invar, DocStyleChange::Italic, DocVerbatim::LatexOnly, DocSymbol::Less, DocIncOperator::Line, CompAccept< DocPara >::m_children, DocVerbatim::ManOnly, DocVerbatim::Msc, TokenInfo::name, DocSimpleSect::Note, DocParamSect::Param, TokenInfo::paramDir, DocSecRefList::parse(), DocCopy::parse(), DocIndexEntry::parse(), DocSimpleList::parse(), DocSymbol::Percent, DocSimpleSect::Post, DocSimpleSect::Pre, DocSimpleSect::Remark, DocSimpleSect::Return, DocParamSect::RetVal, RetVal_EndList, RetVal_Internal, RetVal_OK, RetVal_Paragraph, RetVal_Section, RetVal_SimpleSec, RetVal_Subsection, RetVal_Subsubsection, RetVal_SwitchLang, DocSimpleSect::See, DocSimpleSect::Since, DocIncOperator::Skip, DocIncOperator::SkipLine, DocParamSect::TemplateParam, TK_ENDLIST, TK_LISTITEM, TK_LNKWORD, TK_NEWPARA, TK_WHITESPACE, TK_WORD, tokToString(), DocIncOperator::Until, DocSimpleSect::User, TokenInfo::verb, DocVerbatim::Verbatim, DocInclude::VerbInclude, DocSimpleSect::Version, warn_doc_error(), DocSimpleSect::Warning, and DocVerbatim::XmlOnly.

Referenced by parse().

int DocPara::handleHtmlStartTag ( const QString &  tagName,
const HtmlAttribList tagHtmlAttribs 
)

Definition at line 4834 of file docparser.cpp.

References DocSimpleSect::appendLinkWord(), TokenInfo::attribs, DocStyleChange::Bold, DocStyleChange::Center, DocStyleChange::Code, DBG, DocStyleChange::Div, doctokenizerYYlineno, doctokenizerYYsetStatePara(), doctokenizerYYsetStateXmlCode(), TokenInfo::emptyTag, DocParamSect::Exception, g_token, handleHtmlHeader(), handleParamSection(), handleSimpleSection(), handleStartCode(), DocImage::Html, HTML_A, HTML_BOLD, HTML_BR, HTML_CAPTION, HTML_CENTER, HTML_CODE, HTML_DD, HTML_DIV, HTML_DL, HTML_DT, HTML_EMPHASIS, HTML_H1, HTML_H2, HTML_H3, HTML_H4, HTML_H5, HTML_H6, HTML_HR, HTML_IMG, HTML_LI, HTML_OL, HTML_P, HTML_PRE, HTML_SMALL, HTML_SPAN, HTML_SUB, HTML_SUP, HTML_TABLE, HTML_TD, HTML_TH, HTML_TR, HTML_UL, HTML_UNKNOWN, Mappers::htmlTagMapper, DocStyleChange::Italic, DocNode::kind(), DocNode::Kind_SimpleSect, CompAccept< DocPara >::m_children, Mapper::map(), TokenInfo::name, HtmlAttrib::name, DocHtmlList::Ordered, DocParamSect::Param, DocLink::parse(), DocHtmlTable::parse(), DocHtmlDescList::parse(), DocHtmlList::parse(), DocHtmlList::parseXml(), DocHtmlTable::parseXml(), DocStyleChange::Preformatted, DocSimpleSect::Return, RetVal_DescTitle, RetVal_ListItem, RetVal_OK, RetVal_TableCell, RetVal_TableHCell, RetVal_TableRow, DocSimpleSect::See, DocNode::setInsidePreformatted(), DocStyleChange::Small, DocStyleChange::Span, DocStyleChange::Subscript, DocStyleChange::Superscript, DocParamSect::TemplateParam, TK_NEWPARA, TK_WORD, HtmlAttribList::toString(), DocHtmlList::Unordered, HtmlAttrib::value, warn_doc_error(), XML_C, XML_CmdMask, XML_DESCRIPTION, XML_EXAMPLE, XML_EXCEPTION, XML_INCLUDE, XML_ITEM, XML_LIST, XML_LISTHEADER, XML_PARA, XML_PARAM, XML_PARAMREF, XML_PERMISSION, XML_REMARKS, XML_RETURNS, XML_SEE, XML_SEEALSO, XML_SUMMARY, XML_TERM, XML_TYPEPARAM, XML_TYPEPARAMREF, and XML_VALUE.

Referenced by parse().

int DocPara::handleHtmlEndTag ( const QString &  tagName  ) 

Definition at line 5207 of file docparser.cpp.

References DocStyleChange::Bold, DocStyleChange::Center, DocStyleChange::Code, DBG, DocStyleChange::Div, doctokenizerYYlineno, HTML_A, HTML_BOLD, HTML_BR, HTML_CAPTION, HTML_CENTER, HTML_CODE, HTML_DD, HTML_DIV, HTML_DL, HTML_DT, HTML_EMPHASIS, HTML_H1, HTML_H2, HTML_H3, HTML_HR, HTML_IMG, HTML_LI, HTML_OL, HTML_P, HTML_PRE, HTML_SMALL, HTML_SPAN, HTML_SUB, HTML_SUP, HTML_TABLE, HTML_TD, HTML_TH, HTML_TR, HTML_UL, HTML_UNKNOWN, Mappers::htmlTagMapper, DocStyleChange::Italic, CompAccept< DocPara >::m_children, Mapper::map(), DocStyleChange::Preformatted, RetVal_CloseXml, RetVal_EndDesc, RetVal_EndList, RetVal_EndTable, RetVal_OK, DocNode::setInsidePreformatted(), DocStyleChange::Small, DocStyleChange::Span, DocStyleChange::Subscript, DocStyleChange::Superscript, warn_doc_error(), XML_C, XML_DESCRIPTION, XML_EXAMPLE, XML_EXCEPTION, XML_INCLUDE, XML_ITEM, XML_LIST, XML_LISTHEADER, XML_PARA, XML_PARAM, XML_PARAMREF, XML_PERMISSION, XML_REMARKS, XML_RETURNS, XML_SEEALSO, XML_SUMMARY, XML_TERM, XML_TYPEPARAM, XML_TYPEPARAMREF, and XML_VALUE.

Referenced by parse().

int DocPara::handleSimpleSection ( DocSimpleSect::Type  t,
bool  xmlContext = FALSE 
)

Definition at line 4067 of file docparser.cpp.

References DocNode::Kind_SimpleSect, CompAccept< DocPara >::m_children, DocSimpleSect::parse(), DocSimpleSect::parseXml(), RetVal_OK, TK_NEWPARA, and DocSimpleSect::User.

Referenced by handleCommand(), and handleHtmlStartTag().

int DocPara::handleXRefItem (  ) 

Definition at line 4117 of file docparser.cpp.

References doctokenizerYYlex(), doctokenizerYYsetStatePara(), doctokenizerYYsetStateXRefItem(), g_token, TokenInfo::id, CompAccept< DocPara >::m_children, TokenInfo::name, DocXRefItem::parse(), RetVal_OK, and TK_WHITESPACE.

Referenced by handleCommand().

int DocPara::handleParamSection ( const QString &  cmdName,
DocParamSect::Type  t,
bool  xmlContext,
int  direction 
)

Definition at line 4095 of file docparser.cpp.

References DocNode::Kind_ParamSect, CompAccept< DocPara >::m_children, DocParamSect::parse(), RetVal_OK, and TK_NEWPARA.

Referenced by handleCommand(), and handleHtmlStartTag().

void DocPara::handleIncludeOperator ( const QString &  cmdName,
DocIncOperator::Type  t 
)

Definition at line 4139 of file docparser.cpp.

References DBG, doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStatePara(), doctokenizerYYsetStatePattern(), g_token, DocNode::kind(), DocNode::Kind_IncOperator, DocNode::Kind_WhiteSpace, CompAccept< DocPara >::m_children, DocIncOperator::markFirst(), DocIncOperator::markLast(), TokenInfo::name, DocIncOperator::parse(), TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleImage ( const QString &  cmdName  ) 

Definition at line 4190 of file docparser.cpp.

References doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStateFile(), doctokenizerYYsetStatePara(), g_token, DocImage::Html, DocImage::Latex, CompAccept< DocPara >::m_children, TokenInfo::name, DocImage::parse(), DocImage::Rtf, TK_LNKWORD, TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleDotFile ( const QString &  cmdName  ) 

Definition at line 4240 of file docparser.cpp.

References doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStateFile(), doctokenizerYYsetStatePara(), g_token, CompAccept< DocPara >::m_children, TokenInfo::name, DocDotFile::parse(), TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleInclude ( const QString &  cmdName,
DocInclude::Type  t 
)

Definition at line 4318 of file docparser.cpp.

References DBG, doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStateFile(), doctokenizerYYsetStatePara(), g_token, CompAccept< DocPara >::m_children, TokenInfo::name, DocInclude::parse(), TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleLink ( const QString &  cmdName,
bool  isJavaLink 
)

Definition at line 4264 of file docparser.cpp.

References doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStateLink(), doctokenizerYYsetStatePara(), g_token, CompAccept< DocPara >::m_children, TokenInfo::name, DocLink::parse(), TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleRef ( const QString &  cmdName  ) 

Definition at line 4291 of file docparser.cpp.

References DBG, doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStatePara(), doctokenizerYYsetStateRef(), g_token, CompAccept< DocPara >::m_children, TokenInfo::name, DocRef::parse(), TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleSection ( const QString &  cmdName  ) 

Definition at line 4348 of file docparser.cpp.

References doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStatePara(), doctokenizerYYsetStateSkipTitle(), g_token, TokenInfo::name, TokenInfo::sectionId, TK_LNKWORD, TK_WHITESPACE, TK_WORD, tokToString(), and warn_doc_error().

Referenced by handleCommand().

void DocPara::handleInheritDoc (  ) 

Definition at line 4410 of file docparser.cpp.

References Definition::briefDescription(), Definition::documentation(), Definition::getOuterScope(), CompAccept< DocPara >::m_children, Definition::name(), and MemberDef::reimplements().

Referenced by handleCommand().

int DocPara::handleStartCode (  ) 

Definition at line 4394 of file docparser.cpp.

References DocVerbatim::Code, doctokenizerYYlex(), doctokenizerYYlineno, doctokenizerYYsetStatePara(), g_token, CompAccept< DocPara >::m_children, TokenInfo::verb, and warn_doc_error().

Referenced by handleCommand(), and handleHtmlStartTag().

int DocPara::handleHtmlHeader ( const HtmlAttribList tagHtmlAttribs,
int  level 
)

Definition at line 4377 of file docparser.cpp.

References CompAccept< DocPara >::m_children, DocHtmlHeader::parse(), RetVal_OK, and TK_NEWPARA.

Referenced by handleHtmlStartTag().

bool DocPara::injectToken ( int  tok,
const QString &  tokText 
)

Definition at line 4388 of file docparser.cpp.

References g_token, CompAccept< DocPara >::m_children, and TokenInfo::name.

Referenced by DocSimpleSect::appendLinkWord().


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



Generated on Mon Mar 31 10:58:58 2008 by  doxygen 1.5.1