Doxygen
Loading...
Searching...
No Matches
docnode.h File Reference
#include <cstdio>
#include <cstdint>
#include <vector>
#include <memory>
#include <variant>
#include <type_traits>
#include "qcstring.h"
#include "docvisitor.h"
#include "docparser.h"
#include "htmlattrib.h"
#include "htmlentity.h"
#include "growvector.h"
#include "section.h"
#include "construct.h"
#include "doctokenizer.h"
+ Include dependency graph for docnode.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  DocNode
 Abstract node interface with type information. More...
 
struct  DocNodeList
 
class  DocCompoundNode
 Base class for nodes with children. More...
 
class  DocWord
 Node representing a word. More...
 
class  DocLinkedWord
 Node representing a word that can be linked to something. More...
 
class  DocURL
 Node representing a URL (or email address) More...
 
class  DocLineBreak
 Node representing a line break. More...
 
class  DocHorRuler
 Node representing a horizontal ruler. More...
 
class  DocAnchor
 Node representing an anchor. More...
 
class  DocCite
 Node representing a citation of some bibliographic reference. More...
 
class  DocStyleChange
 Node representing a style change. More...
 
class  DocSymbol
 Node representing a special symbol. More...
 
class  DocEmoji
 Node representing an emoji. More...
 
class  DocWhiteSpace
 Node representing some amount of white space. More...
 
class  DocSeparator
 Node representing a separator. More...
 
class  DocVerbatim
 Node representing a verbatim, unparsed text fragment. More...
 
struct  DocVerbatim::Private
 
class  DocInclude
 Node representing an included text block from file. More...
 
class  DocIncOperator
 Node representing a include/dontinclude operator block. More...
 
class  DocFormula
 Node representing an item of a cross-referenced list. More...
 
class  DocIndexEntry
 Node representing an entry in the index. More...
 
class  DocAutoList
 Node representing an auto List. More...
 
class  DocAutoListItem
 Node representing an item of a auto list. More...
 
class  DocTitle
 Node representing a simple section title. More...
 
class  DocXRefItem
 Node representing an item of a cross-referenced list. More...
 
class  DocImage
 Node representing an image. More...
 
struct  DocImage::Private
 
class  DocDiagramFileBase
 
struct  DocDiagramFileBase::Private
 
class  DocDotFile
 Node representing a dot file. More...
 
class  DocMscFile
 Node representing a msc file. More...
 
class  DocDiaFile
 Node representing a dia file. More...
 
class  DocPlantUmlFile
 Node representing a uml file. More...
 
class  DocVhdlFlow
 Node representing a VHDL flow chart. More...
 
class  DocLink
 Node representing a link to some item. More...
 
class  DocRef
 Node representing a reference to some item. More...
 
class  DocInternalRef
 Node representing an internal reference to some item. More...
 
class  DocHRef
 Node representing a Hypertext reference. More...
 
class  DocHtmlSummary
 Node Html summary. More...
 
class  DocHtmlDetails
 Node Html details. More...
 
class  DocHtmlHeader
 Node Html heading. More...
 
class  DocHtmlDescTitle
 Node representing a Html description item. More...
 
class  DocHtmlDescList
 Node representing a Html description list. More...
 
class  DocSection
 Node representing a normal section. More...
 
class  DocSecRefItem
 Node representing a reference to a section. More...
 
class  DocSecRefList
 Node representing a list of section references. More...
 
class  DocInternal
 Node representing an internal section of documentation. More...
 
class  DocParBlock
 Node representing an block of paragraphs. More...
 
class  DocSimpleList
 Node representing a simple list. More...
 
class  DocHtmlList
 Node representing a Html list. More...
 
class  DocSimpleSect
 Node representing a simple section. More...
 
class  DocSimpleSectSep
 Node representing a separator between two simple sections of the same type. More...
 
class  DocParamSect
 Node representing a parameter section. More...
 
class  DocPara
 Node representing a paragraph in the documentation tree. More...
 
class  DocParamList
 Node representing a parameter list. More...
 
class  DocSimpleListItem
 Node representing a simple list item. More...
 
class  DocHtmlListItem
 Node representing a HTML list item. More...
 
class  DocHtmlDescData
 Node representing a HTML description data. More...
 
class  DocHtmlCell
 Node representing a HTML table cell. More...
 
class  DocHtmlCaption
 Node representing a HTML table caption. More...
 
class  DocHtmlRow
 Node representing a HTML table row. More...
 
class  DocHtmlTable
 Node representing a HTML table. More...
 
class  DocHtmlBlockQuote
 Node representing an HTML blockquote. More...
 
class  DocText
 Root node of a text fragment. More...
 
class  DocRoot
 Root node of documentation tree. More...
 
struct  details::Impl< T, Ts >
 
struct  details::Impl< T >
 
struct  details::has_method_children< T, typename >
 
struct  details::has_method_children< T, std::void_t< decltype(std::declval< T >().children())> >
 
class  DocNodeAST
 Class representing the abstract syntax tree of a documentation block. More...
 

Namespaces

namespace  details
 

Macros

#define DOC_NODES
 
#define DN(x)
 
#define DN_SEP
 
#define DN(x)
 
#define DN_SEP   ,
 
#define DN(x)
 
#define DN_SEP
 
#define DN(x)
 
#define DN_SEP   ,
 
#define DN(x)
 
#define DN_SEP   ,
 
#define DN(x)
 
#define DN_SEP   ,
 

Typedefs

using DocNodeVariant
 

Functions

constexpr const char * docNodeName (const DocWord &)
 
constexpr const char * docNodeName (const DocLinkedWord &)
 
constexpr const char * docNodeName (const DocURL &)
 
constexpr const char * docNodeName (const DocLineBreak &)
 
constexpr const char * docNodeName (const DocHorRuler &)
 
constexpr const char * docNodeName (const DocAnchor &)
 
constexpr const char * docNodeName (const DocCite &)
 
constexpr const char * docNodeName (const DocStyleChange &)
 
constexpr const char * docNodeName (const DocSymbol &)
 
constexpr const char * docNodeName (const DocEmoji &)
 
constexpr const char * docNodeName (const DocWhiteSpace &)
 
constexpr const char * docNodeName (const DocSeparator &)
 
constexpr const char * docNodeName (const DocVerbatim &)
 
constexpr const char * docNodeName (const DocInclude &)
 
constexpr const char * docNodeName (const DocIncOperator &)
 
constexpr const char * docNodeName (const DocFormula &)
 
constexpr const char * docNodeName (const DocIndexEntry &)
 
constexpr const char * docNodeName (const DocAutoList &)
 
constexpr const char * docNodeName (const DocAutoListItem &)
 
constexpr const char * docNodeName (const DocTitle &)
 
constexpr const char * docNodeName (const DocXRefItem &)
 
constexpr const char * docNodeName (const DocImage &)
 
constexpr const char * docNodeName (const DocDotFile &)
 
constexpr const char * docNodeName (const DocMscFile &)
 
constexpr const char * docNodeName (const DocDiaFile &)
 
constexpr const char * docNodeName (const DocVhdlFlow &)
 
constexpr const char * docNodeName (const DocLink &)
 
constexpr const char * docNodeName (const DocRef &)
 
constexpr const char * docNodeName (const DocInternalRef &)
 
constexpr const char * docNodeName (const DocHRef &)
 
constexpr const char * docNodeName (const DocHtmlHeader &)
 
constexpr const char * docNodeName (const DocHtmlDescTitle &)
 
constexpr const char * docNodeName (const DocHtmlDescList &)
 
constexpr const char * docNodeName (const DocSection &)
 
constexpr const char * docNodeName (const DocSecRefItem &)
 
constexpr const char * docNodeName (const DocSecRefList &)
 
constexpr const char * docNodeName (const DocInternal &)
 
constexpr const char * docNodeName (const DocParBlock &)
 
constexpr const char * docNodeName (const DocSimpleList &)
 
constexpr const char * docNodeName (const DocHtmlList &)
 
constexpr const char * docNodeName (const DocSimpleSect &)
 
constexpr const char * docNodeName (const DocSimpleSectSep &)
 
constexpr const char * docNodeName (const DocParamSect &)
 
constexpr const char * docNodeName (const DocPara &)
 
constexpr const char * docNodeName (const DocParamList &)
 
constexpr const char * docNodeName (const DocSimpleListItem &)
 
constexpr const char * docNodeName (const DocHtmlListItem &)
 
constexpr const char * docNodeName (const DocHtmlDescData &)
 
constexpr const char * docNodeName (const DocHtmlCell &)
 
constexpr const char * docNodeName (const DocHtmlCaption &)
 
constexpr const char * docNodeName (const DocHtmlRow &)
 
constexpr const char * docNodeName (const DocHtmlTable &)
 
constexpr const char * docNodeName (const DocHtmlBlockQuote &)
 
constexpr const char * docNodeName (const DocText &)
 
constexpr const char * docNodeName (const DocRoot &)
 
constexpr const char * docNodeName (const DocHtmlDetails &)
 
constexpr const char * docNodeName (const DocHtmlSummary &)
 
constexpr const char * docNodeName (const DocPlantUmlFile &)
 
constexpr DocNodeVariantparent (DocNodeVariant *n)
 returns the parent node of a given node n or nullptr if the node has no parent.
 
constexpr const DocNodeVariantparent (const DocNodeVariant *n)
 returns the parent node of a given node n or nullptr if the node has no parent.
 
template<class... Ts>
constexpr bool holds_one_of_alternatives (const DocNodeVariant &v)
 returns true iff v holds one of types passed as template parameters
 
DocNodeListcall_method_children (DocNodeVariant *v)
 
const char * docNodeName (const DocNodeVariant &v)
 
void dumpDocNodeSizes ()
 
void dumpDocNodeList (const DocNodeList &children)
 
template<class T, class... Args>
std::unique_ptr< DocNodeVariantcreateDocNode (Args &&...args)
 

Macro Definition Documentation

◆ DN [1/6]

#define DN ( x)
Value:
class x;

Definition at line 57 of file docnode.h.

◆ DN [2/6]

#define DN ( x)
Value:
x

Definition at line 57 of file docnode.h.

◆ DN [3/6]

#define DN ( x)
Value:
constexpr const char *docNodeName(const x &/* n */) { return #x; }
constexpr const char * docNodeName(const DocWord &)
Definition docnode.h:75

Definition at line 57 of file docnode.h.

◆ DN [4/6]

#define DN ( x)
Value:
#x

Definition at line 57 of file docnode.h.

◆ DN [5/6]

#define DN ( x)
Value:
#x

Definition at line 57 of file docnode.h.

◆ DN [6/6]

#define DN ( x)
Value:
sizeof(x)

Definition at line 57 of file docnode.h.

◆ DN_SEP [1/6]

#define DN_SEP

Definition at line 58 of file docnode.h.

◆ DN_SEP [2/6]

#define DN_SEP   ,

Definition at line 58 of file docnode.h.

◆ DN_SEP [3/6]

#define DN_SEP

Definition at line 58 of file docnode.h.

◆ DN_SEP [4/6]

#define DN_SEP   ,

Definition at line 58 of file docnode.h.

◆ DN_SEP [5/6]

#define DN_SEP   ,

Definition at line 58 of file docnode.h.

◆ DN_SEP [6/6]

#define DN_SEP   ,

Definition at line 58 of file docnode.h.

◆ DOC_NODES

#define DOC_NODES
Value:
Node representing an anchor.
Definition docnode.h:228
Node representing an auto List.
Definition docnode.h:566
Node representing an item of a auto list.
Definition docnode.h:590
Node representing a citation of some bibliographic reference.
Definition docnode.h:244
Node representing a dia file.
Definition docnode.h:725
Node representing a dot file.
Definition docnode.h:707
Node representing an emoji.
Definition docnode.h:336
Node representing an item of a cross-referenced list.
Definition docnode.h:524
Node representing a Hypertext reference.
Definition docnode.h:817
Node representing a horizontal ruler.
Definition docnode.h:215
Node representing an HTML blockquote.
Definition docnode.h:1285
Node representing a HTML table caption.
Definition docnode.h:1222
Node representing a HTML table cell.
Definition docnode.h:1187
Node representing a HTML description data.
Definition docnode.h:1175
Node representing a Html description list.
Definition docnode.h:895
Node representing a Html description item.
Definition docnode.h:882
Node Html details.
Definition docnode.h:851
Node Html heading.
Definition docnode.h:867
Node representing a Html list.
Definition docnode.h:994
Node representing a HTML list item.
Definition docnode.h:1159
Node representing a HTML table row.
Definition docnode.h:1240
Node Html summary.
Definition docnode.h:838
Node representing a HTML table.
Definition docnode.h:1263
Node representing an image.
Definition docnode.h:636
Node representing a include/dontinclude operator block.
Definition docnode.h:472
Node representing an included text block from file.
Definition docnode.h:430
Node representing an entry in the index.
Definition docnode.h:547
Node representing an internal section of documentation.
Definition docnode.h:963
Node representing an internal reference to some item.
Definition docnode.h:801
Node representing a line break.
Definition docnode.h:201
Node representing a word that can be linked to something.
Definition docnode.h:164
Node representing a msc file.
Definition docnode.h:716
Node representing an block of paragraphs.
Definition docnode.h:973
Node representing a paragraph in the documentation tree.
Definition docnode.h:1074
Node representing a parameter list.
Definition docnode.h:1119
Node representing a parameter section.
Definition docnode.h:1047
Node representing a uml file.
Definition docnode.h:734
Node representing a reference to some item.
Definition docnode.h:772
Root node of documentation tree.
Definition docnode.h:1307
Node representing a reference to a section.
Definition docnode.h:929
Node representing a list of section references.
Definition docnode.h:953
Node representing a normal section.
Definition docnode.h:908
Node representing a separator.
Definition docnode.h:360
Node representing a simple list.
Definition docnode.h:984
Node representing a simple list item.
Definition docnode.h:1147
Node representing a simple section.
Definition docnode.h:1011
Node representing a separator between two simple sections of the same type.
Definition docnode.h:1038
Node representing a style change.
Definition docnode.h:264
Node representing a special symbol.
Definition docnode.h:323
Root node of a text fragment.
Definition docnode.h:1298
Node representing a simple section title.
Definition docnode.h:603
Node representing a URL (or email address)
Definition docnode.h:187
Node representing a verbatim, unparsed text fragment.
Definition docnode.h:371
Node representing a VHDL flow chart.
Definition docnode.h:743
Node representing some amount of white space.
Definition docnode.h:349
Node representing a word.
Definition docnode.h:152
Node representing an item of a cross-referenced list.
Definition docnode.h:615
#define DN(x)
Definition docnode.h:57
#define DN_SEP
Definition docnode.h:58

Definition at line 42 of file docnode.h.

42#define DOC_NODES \
43/* 0 */ DN(DocWord) DN_SEP DN(DocLinkedWord) DN_SEP DN(DocURL) DN_SEP DN(DocLineBreak) DN_SEP DN(DocHorRuler) DN_SEP \
44/* 5 */ DN(DocAnchor) DN_SEP DN(DocCite) DN_SEP DN(DocStyleChange) DN_SEP DN(DocSymbol) DN_SEP DN(DocEmoji) DN_SEP \
45/* 10 */ DN(DocWhiteSpace) DN_SEP DN(DocSeparator) DN_SEP DN(DocVerbatim) DN_SEP DN(DocInclude) DN_SEP DN(DocIncOperator) DN_SEP \
46/* 15 */ DN(DocFormula) DN_SEP DN(DocIndexEntry) DN_SEP DN(DocAutoList) DN_SEP DN(DocAutoListItem) DN_SEP DN(DocTitle) DN_SEP \
47/* 20 */ DN(DocXRefItem) DN_SEP DN(DocImage) DN_SEP DN(DocDotFile) DN_SEP DN(DocMscFile) DN_SEP DN(DocDiaFile) DN_SEP \
48/* 25 */ DN(DocVhdlFlow) DN_SEP DN(DocLink) DN_SEP DN(DocRef) DN_SEP DN(DocInternalRef) DN_SEP DN(DocHRef) DN_SEP \
49/* 30 */ DN(DocHtmlHeader) DN_SEP DN(DocHtmlDescTitle) DN_SEP DN(DocHtmlDescList) DN_SEP DN(DocSection) DN_SEP DN(DocSecRefItem) DN_SEP \
50/* 35 */ DN(DocSecRefList) DN_SEP DN(DocInternal) DN_SEP DN(DocParBlock) DN_SEP DN(DocSimpleList) DN_SEP DN(DocHtmlList) DN_SEP \
51/* 40 */ DN(DocSimpleSect) DN_SEP DN(DocSimpleSectSep) DN_SEP DN(DocParamSect) DN_SEP DN(DocPara) DN_SEP DN(DocParamList) DN_SEP \
52/* 45 */ DN(DocSimpleListItem) DN_SEP DN(DocHtmlListItem) DN_SEP DN(DocHtmlDescData) DN_SEP DN(DocHtmlCell) DN_SEP DN(DocHtmlCaption) DN_SEP \
53/* 50 */ DN(DocHtmlRow) DN_SEP DN(DocHtmlTable) DN_SEP DN(DocHtmlBlockQuote) DN_SEP DN(DocText) DN_SEP DN(DocRoot) DN_SEP \
54/* 55 */ DN(DocHtmlDetails) DN_SEP DN(DocHtmlSummary) DN_SEP DN(DocPlantUmlFile) \
55

Referenced by docNodeName(), docNodeName(), and dumpDocNodeSizes().

Typedef Documentation

◆ DocNodeVariant

Function Documentation

◆ call_method_children()

DocNodeList * call_method_children ( DocNodeVariant * v)
inline

Definition at line 1379 of file docnode.h.

1380{
1381 return std::visit([](auto&& value) -> DocNodeList* {
1382 if constexpr (details::has_method_children<decltype(value)>::value) {
1383 return &value.children();
1384 } else {
1385 return nullptr;
1386 }
1387 }, *v);
1388}

Referenced by flattenParagraphs().

◆ createDocNode()

template<class T, class... Args>
std::unique_ptr< DocNodeVariant > createDocNode ( Args &&... args)

Definition at line 1485 of file docnode.h.

1486{
1487 auto node = std::make_unique<DocNodeVariant>(T(std::forward<Args>(args)...));
1488 std::get_if<T>(node.get())->setThisVariant(node.get());
1489 return node;
1490}

Referenced by DocHtmlDetails::parse(), DocHtmlTable::parse(), DocSection::parse(), DocSimpleListItem::parse(), DocSimpleSect::parse(), DocSimpleSect::parseRcs(), and DocHtmlDetails::parseSummary().

◆ docNodeName() [1/59]

const char * docNodeName ( const DocAnchor & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [2/59]

const char * docNodeName ( const DocAutoList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [3/59]

const char * docNodeName ( const DocAutoListItem & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [4/59]

const char * docNodeName ( const DocCite & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [5/59]

const char * docNodeName ( const DocDiaFile & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [6/59]

const char * docNodeName ( const DocDotFile & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [7/59]

const char * docNodeName ( const DocEmoji & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [8/59]

const char * docNodeName ( const DocFormula & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [9/59]

const char * docNodeName ( const DocHorRuler & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [10/59]

const char * docNodeName ( const DocHRef & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [11/59]

const char * docNodeName ( const DocHtmlBlockQuote & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [12/59]

const char * docNodeName ( const DocHtmlCaption & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [13/59]

const char * docNodeName ( const DocHtmlCell & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [14/59]

const char * docNodeName ( const DocHtmlDescData & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [15/59]

const char * docNodeName ( const DocHtmlDescList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [16/59]

const char * docNodeName ( const DocHtmlDescTitle & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [17/59]

const char * docNodeName ( const DocHtmlDetails & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [18/59]

const char * docNodeName ( const DocHtmlHeader & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [19/59]

const char * docNodeName ( const DocHtmlList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [20/59]

const char * docNodeName ( const DocHtmlListItem & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [21/59]

const char * docNodeName ( const DocHtmlRow & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [22/59]

const char * docNodeName ( const DocHtmlSummary & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [23/59]

const char * docNodeName ( const DocHtmlTable & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [24/59]

const char * docNodeName ( const DocImage & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [25/59]

const char * docNodeName ( const DocInclude & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [26/59]

const char * docNodeName ( const DocIncOperator & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [27/59]

const char * docNodeName ( const DocIndexEntry & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [28/59]

const char * docNodeName ( const DocInternal & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [29/59]

const char * docNodeName ( const DocInternalRef & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [30/59]

const char * docNodeName ( const DocLineBreak & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [31/59]

const char * docNodeName ( const DocLink & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [32/59]

const char * docNodeName ( const DocLinkedWord & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [33/59]

const char * docNodeName ( const DocMscFile & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [34/59]

const char * docNodeName ( const DocNodeVariant & v)
inline

Definition at line 1413 of file docnode.h.

1414{
1415 static const char *table[] = { DOC_NODES };
1416 return table[v.index()];
1417}
#define DOC_NODES
Definition docnode.h:42

References DOC_NODES.

◆ docNodeName() [35/59]

const char * docNodeName ( const DocPara & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [36/59]

const char * docNodeName ( const DocParamList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [37/59]

const char * docNodeName ( const DocParamSect & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [38/59]

const char * docNodeName ( const DocParBlock & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [39/59]

const char * docNodeName ( const DocPlantUmlFile & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [40/59]

const char * docNodeName ( const DocRef & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [41/59]

const char * docNodeName ( const DocRoot & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [42/59]

const char * docNodeName ( const DocSecRefItem & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [43/59]

const char * docNodeName ( const DocSecRefList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [44/59]

const char * docNodeName ( const DocSection & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [45/59]

const char * docNodeName ( const DocSeparator & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [46/59]

const char * docNodeName ( const DocSimpleList & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [47/59]

const char * docNodeName ( const DocSimpleListItem & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [48/59]

const char * docNodeName ( const DocSimpleSect & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [49/59]

const char * docNodeName ( const DocSimpleSectSep & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [50/59]

const char * docNodeName ( const DocStyleChange & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [51/59]

const char * docNodeName ( const DocSymbol & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [52/59]

const char * docNodeName ( const DocText & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [53/59]

const char * docNodeName ( const DocTitle & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [54/59]

const char * docNodeName ( const DocURL & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [55/59]

const char * docNodeName ( const DocVerbatim & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [56/59]

const char * docNodeName ( const DocVhdlFlow & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [57/59]

const char * docNodeName ( const DocWhiteSpace & )
constexpr

Definition at line 75 of file docnode.h.

◆ docNodeName() [58/59]

const char * docNodeName ( const DocWord & )
constexpr

Definition at line 75 of file docnode.h.

References DOC_NODES.

Referenced by dumpDocNodeList().

◆ docNodeName() [59/59]

const char * docNodeName ( const DocXRefItem & )
constexpr

Definition at line 75 of file docnode.h.

◆ dumpDocNodeList()

void dumpDocNodeList ( const DocNodeList & children)
inline

Definition at line 1445 of file docnode.h.

1446{
1447 printf("children=[\n");
1448 for (const auto &child : children)
1449 {
1450 const DocWord *w = std::get_if<DocWord>(&child);
1451 printf(" %s (%p) %s\n",docNodeName(child),(void*)&child,qPrint(w?w->word():""));
1452 }
1453 printf("]\n");
1454}
QCString word() const
Definition docnode.h:155
const char * qPrint(const char *s)
Definition qcstring.h:672

References docNodeName(), qPrint(), and DocWord::word().

◆ dumpDocNodeSizes()

void dumpDocNodeSizes ( )
inline

Definition at line 1421 of file docnode.h.

1422{
1423#define DN(x) #x
1424#define DN_SEP ,
1425 static const char *tableWithNames[] = { DOC_NODES };
1426#undef DN
1427#undef DN_SEP
1428
1429#define DN(x) sizeof(x)
1430#define DN_SEP ,
1431 static size_t tableWithSizes[] = { DOC_NODES };
1432#undef DN
1433#undef DN_SEP
1434
1435 size_t maxSize=0;
1436 printf("DocNodeVariant(\n");
1437 for (size_t i=0;i<sizeof(tableWithNames)/sizeof(tableWithNames[0]);i++)
1438 {
1439 printf(" /* %2zu */ sizeof(%s)=%zu\n",i,tableWithNames[i],tableWithSizes[i]);
1440 if (tableWithSizes[i]>maxSize) maxSize = tableWithSizes[i];
1441 }
1442 printf(")=%zu\n",maxSize);
1443}

References DOC_NODES.

◆ holds_one_of_alternatives()

template<class... Ts>
bool holds_one_of_alternatives ( const DocNodeVariant & v)
constexpr

returns true iff v holds one of types passed as template parameters

Definition at line 1360 of file docnode.h.

1361{
1363}
static constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
Definition docnode.h:1341

References details::Impl< T, Ts >::holds_one_of_alternatives().

Referenced by determineIfNeedsTag(), getParagraphContext(), mustBeOutsideParagraph(), DocPara::parse(), and tableIsNested().

◆ parent() [1/2]

const DocNodeVariant * parent ( const DocNodeVariant * n)
constexpr

returns the parent node of a given node n or nullptr if the node has no parent.

Definition at line 1330 of file docnode.h.

1331{
1332 return n ? std::visit([](auto &&x)->decltype(auto) { return x.parent(); }, *n) : nullptr;
1333}

◆ parent() [2/2]

DocNodeVariant * parent ( DocNodeVariant * n)
constexpr

returns the parent node of a given node n or nullptr if the node has no parent.

Definition at line 1324 of file docnode.h.

1325{
1326 return n ? std::visit([](auto &&x)->decltype(auto) { return x.parent(); }, *n) : nullptr;
1327}

Referenced by buildDirectories(), checkIfHtmlEndTagEndsAutoList(), LayoutDocManager::createChildNavEntry(), FTVHelp::decContentsDepth(), DocParser::defaultHandleTitleAndSize(), DocParser::defaultHandleToken(), DefineManager::DefinesPerFile::DefinesPerFile(), DocDiaFile::DocDiaFile(), DocDotFile::DocDotFile(), DocMscFile::DocMscFile(), DocPlantUmlFile::DocPlantUmlFile(), TreeDiagram::drawConnectors(), dupOfParent(), DocParser::errorHandleDefaultToken(), externalLinkTarget(), generateClassOrGlobalLink(), generateIndent(), generateIndentLabel(), getParagraphContext(), DocParser::handleAHref(), DocParser::handleAnchor(), DocParser::handleImage(), DocParser::handleImg(), DocParser::handleInitialStyleCommands(), DocParser::handleInternalRef(), DocParser::handleLinkedWord(), DocParser::handleParameterType(), DocParser::handlePendingStyleCommands(), DocParser::handlePrefix(), DocParser::handleStyleArgument(), DocParser::handleStyleEnter(), DocParser::handleStyleLeave(), DiagramRow::insertClass(), insideBlockQuote(), insideDetails(), insideDL(), insideLI(), insideOL(), insidePRE(), insideTable(), insideUL(), DocParser::internalValidatingParseDoc(), isFirstChildNode(), isLastChildNode(), isSeparatedParagraph(), isSymbolHidden(), listIsNested(), LatexDocVisitor::operator()(), parentIsVisible(), parseMain(), pathToNode(), recodeString(), tableIsNested(), and writeDotDirDepGraph().