Doxygen
Loading...
Searching...
No Matches
docnode.h
Go to the documentation of this file.
1/******************************************************************************
2 *
3 * Copyright (C) 1997-2022 by Dimitri van Heesch.
4 *
5 * Permission to use, copy, modify, and distribute this software and its
6 * documentation under the terms of the GNU General Public License is hereby
7 * granted. No representations are made about the suitability of this software
8 * for any purpose. It is provided "as is" without express or implied warranty.
9 * See the GNU General Public License for more details.
10 *
11 * Documents produced by Doxygen are derivative works derived from the
12 * input used in their production; they are not affected by this license.
13 *
14 */
15
16#ifndef DOCNODE_H
17#define DOCNODE_H
18
19#include <cstdio>
20#include <cstdint>
21#include <vector>
22#include <memory>
23#include <variant>
24#include <type_traits>
25
26#include "qcstring.h"
27#include "docvisitor.h"
28#include "docparser.h"
29#include "htmlattrib.h"
30#include "htmlentity.h"
31#include "growvector.h"
32#include "section.h"
33#include "construct.h"
34#include "doctokenizer.h"
35
36class MemberDef;
37class Definition;
38class DocParser;
39
40//---------------------------------------------------------------------------
41
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
56// forward declarations
57#define DN(x) class x;
58#define DN_SEP
60#undef DN
61#undef DN_SEP
62
63// define a variant type
64#define DN(x) x
65#define DN_SEP ,
66using DocNodeVariant = std::variant<
68>;
69#undef DN
70#undef DN_SEP
71
72// getter functions to return the name of a doc node type
73#define DN(x) constexpr const char *docNodeName(const x &/* n */) { return #x; }
74#define DN_SEP
76#undef DN
77#undef DN_SEP
78
79/** Abstract node interface with type information. */
81{
82 public:
83 /*! Creates a new node */
85 ~DocNode() = default;
87
88 /*! Returns the parent of this node or nullptr for the root node. */
90 const DocNodeVariant *parent() const { return m_parent; }
91
93 const DocNodeVariant *thisVariant() const { return m_thisVariant; }
94
96
97 DocParser *parser() { return m_parser; }
98 const DocParser *parser() const { return m_parser; }
99
100 /*! Sets a new parent for this node. */
102
103 /*! Returns TRUE iff this node is inside a preformatted section */
104 bool isPreformatted() const { return m_insidePre; }
105
106 protected:
107 /*! Sets whether or not this item is inside a preformatted section */
108 void setInsidePreformatted(bool p) { m_insidePre = p; }
110 private:
111 bool m_insidePre = false;
112 DocParser *m_parser;
115};
116
117struct DocNodeList : public GrowVector<DocNodeVariant>
118{
119 /** Append a new DocNodeVariant to the list by constructing it with type T and
120 * parameters Args.
121 */
122 template<class T,class...Args>
123 void append(Args&&... args);
124
125 /** moves the element of list \a l at the end of this list.
126 * List \a l will become empty. */
127 void move_append(DocNodeList &l);
128
129 /** Returns a pointer to the last element in the list if that element exists and
130 * holds a T, otherwise nullptr is returned.
131 */
132 template<class T>
133 T *get_last();
134};
135
136/** Base class for nodes with children */
138{
139 public:
142 DocNodeList &children() { return m_children; }
143 const DocNodeList &children() const { return m_children; }
144
145 private:
146 DocNodeList m_children;
147};
148
149/** Node representing a word
150 */
151class DocWord : public DocNode
152{
153 public:
154 DocWord(DocParser *parser,DocNodeVariant *parent,const QCString &word);
155 QCString word() const { return m_word; }
156
157 private:
158 QCString m_word;
159};
160
161/** Node representing a word that can be linked to something
162 */
163class DocLinkedWord : public DocNode
164{
165 public:
166 DocLinkedWord(DocParser *parser,DocNodeVariant *parent,const QCString &word,
167 const QCString &ref,const QCString &file,
168 const QCString &anchor,const QCString &tooltip);
169 QCString word() const { return m_word; }
170 QCString file() const { return m_file; }
171 QCString relPath() const { return m_relPath; }
172 QCString ref() const { return m_ref; }
173 QCString anchor() const { return m_anchor; }
174 QCString tooltip() const { return m_tooltip; }
175
176 private:
177 QCString m_word;
178 QCString m_ref;
179 QCString m_file;
180 QCString m_relPath;
181 QCString m_anchor;
182 QCString m_tooltip;
183};
184
185/** Node representing a URL (or email address) */
186class DocURL : public DocNode
187{
188 public:
189 DocURL(DocParser *parser,DocNodeVariant *parent,const QCString &url,bool isEmail) :
191 QCString url() const { return m_url; }
192 bool isEmail() const { return m_isEmail; }
193
194 private:
195 QCString m_url;
196 bool m_isEmail = false;
197};
198
199/** Node representing a line break */
200class DocLineBreak : public DocNode
201{
202 public:
204 DocLineBreak(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs)
206
207 const HtmlAttribList &attribs() const { return m_attribs; }
208
209 private:
210 HtmlAttribList m_attribs;
211};
212
213/** Node representing a horizontal ruler */
214class DocHorRuler : public DocNode
215{
216 public:
217 DocHorRuler(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs)
219
220 const HtmlAttribList &attribs() const { return m_attribs; }
221
222 private:
223 HtmlAttribList m_attribs;
224};
225
226/** Node representing an anchor */
227class DocAnchor : public DocNode
228{
229 public:
230 DocAnchor(DocParser *parser,DocNodeVariant *parent,const QCString &id,bool newAnchor);
231 QCString anchor() const { return m_anchor; }
232 QCString file() const { return m_file; }
233
234 const HtmlAttribList &attribs() const { return m_attribs; }
235
236 private:
237 QCString m_anchor;
238 QCString m_file;
239 HtmlAttribList m_attribs;
240};
241
242/** Node representing a citation of some bibliographic reference */
243class DocCite : public DocNode
244{
245 public:
246 DocCite(DocParser *parser,DocNodeVariant *parent,const QCString &target,const QCString &context);
247 QCString file() const { return m_file; }
248 QCString relPath() const { return m_relPath; }
249 QCString ref() const { return m_ref; }
250 QCString anchor() const { return m_anchor; }
251 QCString text() const { return m_text; }
252
253 private:
254 QCString m_file;
255 QCString m_relPath;
256 QCString m_ref;
257 QCString m_anchor;
258 QCString m_text;
259};
260
261
262/** Node representing a style change */
264{
265 public:
266 enum Style { Bold = (1<<0),
267 Italic = (1<<1),
268 Code = (1<<2),
269 Center = (1<<3),
270 Small = (1<<4),
271 Subscript = (1<<5),
272 Superscript = (1<<6),
273 Preformatted = (1<<7),
274 Span = (1<<8),
275 Div = (1<<9),
276 Strike = (1<<10),
277 Underline = (1<<11),
278 Del = (1<<12),
279 Ins = (1<<13),
280 S = (1<<14),
281 Cite = (1<<15),
282 Kbd = (1<<16)
283 };
284
286 const QCString &tagName,bool enable, const HtmlAttribList *attribs=nullptr)
288 {
290 m_tagName = tagName.lower();
291 }
292 Style style() const { return m_style; }
293 const char *styleString() const;
294 bool enable() const { return m_enable; }
295 size_t position() const { return m_position; }
296 const HtmlAttribList &attribs() const { return m_attribs; }
297 QCString tagName() const { return m_tagName; }
298
299 private:
300 size_t m_position = 0;
302 bool m_enable = false;
303 HtmlAttribList m_attribs;
304 QCString m_tagName;
305};
306
307/** Node representing a special symbol */
319
320/** Node representing an emoji */
321class DocEmoji : public DocNode
322{
323 public:
324 DocEmoji(DocParser *parser,DocNodeVariant *parent,const QCString &symName);
325 QCString name() const { return m_symName; }
326 int index() const { return m_index; }
327
328 private:
329 QCString m_symName;
330 int m_index = 0;
331};
332
333/** Node representing some amount of white space */
334class DocWhiteSpace : public DocNode
335{
336 public:
339 QCString chars() const { return m_chars; }
340 private:
341 QCString m_chars;
342};
343
344/** Node representing a separator */
345class DocSeparator : public DocNode
346{
347 public:
348 DocSeparator(DocParser *parser,DocNodeVariant *parent,const QCString &chars)
350 QCString chars() const { return m_chars; }
351 private:
352 QCString m_chars;
353};
354
355/** Node representing a verbatim, unparsed text fragment */
356class DocVerbatim : public DocNode
357{
358 public:
360 DocVerbatim(DocParser *parser,DocNodeVariant *parent,const QCString &context,
361 const QCString &text, Type t,bool isExample,
362 const QCString &exampleFile,bool isBlock=FALSE,const QCString &lang=QCString());
363 Type type() const { return p->type; }
364 QCString text() const { return p->text; }
365 QCString context() const { return p->context; }
366 bool isExample() const { return p->isExample; }
367 QCString exampleFile() const { return p->exampleFile; }
368 QCString relPath() const { return p->relPath; }
369 QCString language() const { return p->lang; }
370 bool isBlock() const { return p->isBlock; }
371 bool hasCaption() const { return !p->children.empty(); }
372 QCString width() const { return p->width; }
373 QCString height() const { return p->height; }
374 QCString engine() const { return p->engine; }
375 bool useBitmap() const { return p->useBitmap; }
376 const DocNodeList &children() const { return p->children; }
377 DocNodeList &children() { return p->children; }
378 QCString srcFile() const { return p->srcFile; }
379 int srcLine() const { return p->srcLine; }
380 void setText(const QCString &t) { p->text=t; }
381 void setWidth(const QCString &w) { p->width=w; }
382 void setHeight(const QCString &h) { p->height=h; }
383 void setEngine(const QCString &e) { p->engine=e; }
384 void setUseBitmap(const bool &u) { p->useBitmap=u; }
385 void setLocation(const QCString &file,int line) { p->srcFile=file; p->srcLine=line; }
386
387 private:
388 struct Private
389 {
390 Private(const QCString &context_,const QCString &text_, Type type_, bool isExample_,
391 const QCString &exampleFile_, const QCString &relPath_,const QCString &lang_, bool isBlock_)
392 : context(context_), text(text_), type(type_), isExample(isExample_),
393 exampleFile(exampleFile_), relPath(relPath_), lang(lang_), isBlock(isBlock_) {}
394 QCString context;
395 QCString text;
398 QCString exampleFile;
399 QCString relPath;
400 QCString lang;
402 QCString width;
403 QCString height;
404 QCString engine;
405 bool useBitmap=false; // some PlantUML engines cannot output data in EPS format so bitmap format is required
406 DocNodeList children;
407 QCString srcFile;
408 int srcLine = -1;
409 };
410 std::unique_ptr<Private> p;
411};
412
413
414/** Node representing an included text block from file */
415class DocInclude : public DocNode
416{
417 public:
421 };
430 QCString file() const { return m_file; }
431 QCString extension() const { int i=m_file.findRev('.'); return i!=-1 ? m_file.mid(i) : QCString(); }
432 Type type() const { return m_type; }
433 QCString text() const { return m_text; }
434 QCString context() const { return m_context; }
435 QCString blockId() const { return m_blockId; }
436 bool stripCodeComments() const { return m_stripCodeComments; }
437 bool isExample() const { return m_isExample; }
438 QCString exampleFile() const { return m_exampleFile; }
439 bool isBlock() const { return m_isBlock; }
440 bool trimLeft() const { return m_trimLeft; }
441 void parse();
442
443 private:
444 QCString m_file;
445 QCString m_context;
446 QCString m_text;
453 QCString m_blockId;
454};
455
456/** Node representing a include/dontinclude operator block */
458{
459 public:
466 Type type() const { return m_type; }
467 const char *typeAsString() const
468 {
469 switch(m_type)
470 {
471 case Line: return "line";
472 case SkipLine: return "skipline";
473 case Skip: return "skip";
474 case Until: return "until";
475 }
476 return "";
477 }
478 int line() const { return m_line; }
479 bool showLineNo() const { return m_showLineNo; }
480 QCString text() const { return m_text; }
481 QCString pattern() const { return m_pattern; }
482 QCString context() const { return m_context; }
483 bool isFirst() const { return m_isFirst; }
484 bool isLast() const { return m_isLast; }
485 void markFirst(bool v=TRUE) { m_isFirst = v; }
486 void markLast(bool v=TRUE) { m_isLast = v; }
487 bool stripCodeComments() const { return m_stripCodeComments; }
488 bool isExample() const { return m_isExample; }
489 QCString exampleFile() const { return m_exampleFile; }
490 QCString includeFileName() const { return m_includeFileName; }
491 void parse();
492
493 private:
495 int m_line = 0;
496 bool m_showLineNo = false;
497 QCString m_text;
498 QCString m_pattern;
499 QCString m_context;
500 bool m_isFirst = false;
501 bool m_isLast = false;
503 bool m_isExample = false;
506};
507
508/** Node representing an item of a cross-referenced list */
509class DocFormula : public DocNode
510{
511 public:
512 DocFormula(DocParser *parser,DocNodeVariant *parent,int id);
513 QCString name() const { return m_name; }
514 QCString text() const { return m_text; }
515 QCString relPath() const { return m_relPath; }
516 int id() const { return m_id; }
517 bool isInline() const
518 {
519 if (m_text.length()>1 && m_text.at(0)=='\\' && m_text.at(1)=='[') return false;
520 if (m_text.startsWith("\\begin{")) return false;
521 return true;
522 }
523
524 private:
525 QCString m_name;
526 QCString m_text;
527 QCString m_relPath;
528 int m_id = 0;
529};
530
531/** Node representing an entry in the index. */
532class DocIndexEntry : public DocNode
533{
534 public:
535 DocIndexEntry(DocParser *parser,DocNodeVariant *parent,const Definition *scope,const MemberDef *md)
537 Token parse();
538 const Definition *scope() const { return m_scope; }
539 const MemberDef *member() const { return m_member; }
540 QCString entry() const { return m_entry; }
541
542 private:
543 QCString m_entry;
544 const Definition *m_scope = nullptr;
545 const MemberDef *m_member = nullptr;
546};
547
548//-----------------------------------------------------------------------
549
550/** Node representing an auto List */
552{
553 public:
555 {
556 Unnumbered=1, Unchecked=-2, Checked_x=-3, Checked_X=-4 // positive numbers give the label
557 };
559 int depth, bool isCheckedList);
560
561 bool isEnumList() const { return m_isEnumList; }
562 int indent() const { return m_indent; }
563 bool isCheckedList() const { return m_isCheckedList; }
564 int depth() const { return m_depth; }
565 Token parse();
566
567 private:
568 int m_indent = 0;
569 bool m_isEnumList = false;
570 bool m_isCheckedList = false;
571 int m_depth = 0;
572};
573
574/** Node representing an item of a auto list */
576{
577 public:
578 DocAutoListItem(DocParser *parser,DocNodeVariant *parent,int indent,int num);
579 int itemNumber() const { return m_itemNum; }
580 Token parse();
581
582 private:
583 int m_indent = 0;
584 int m_itemNum = 0;
585};
586
587/** Node representing a simple section title */
589{
590 public:
592 void parse();
593 void parseFromString(DocNodeVariant *,const QCString &title);
594 bool hasTitle() const { return !children().empty(); }
595
596 private:
597};
598
599/** Node representing an item of a cross-referenced list */
601{
602 public:
603 DocXRefItem(DocParser *parser,DocNodeVariant *parent,int id,const QCString &key);
604 QCString file() const { return m_file; }
605 QCString anchor() const { return m_anchor; }
606 QCString title() const { return m_title; }
607 QCString relPath() const { return m_relPath; }
608 QCString key() const { return m_key; }
609 bool parse();
610
611 private:
612 int m_id = 0;
613 QCString m_key;
614 QCString m_file;
615 QCString m_anchor;
616 QCString m_title;
617 QCString m_relPath;
618};
619
620/** Node representing an image */
622{
623 public:
624 enum Type { Html, Latex, Rtf, DocBook, Xml };
625 DocImage(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs,
626 const QCString &name,Type t,const QCString &url=QCString(), bool inlineImage = TRUE);
627 Type type() const { return p->type; }
628 QCString name() const { return p->name; }
629 bool hasCaption() const { return !children().empty(); }
630 QCString width() const { return p->width; }
631 QCString height() const { return p->height; }
632 QCString relPath() const { return p->relPath; }
633 QCString url() const { return p->url; }
634 bool isInlineImage() const { return p->inlineImage; }
635 bool isSVG() const;
636 const HtmlAttribList &attribs() const { return p->attribs; }
637 void parse();
638
639 private:
640 struct Private
641 {
642 Private(const HtmlAttribList &attribs_,const QCString &name_,Type type_,
643 const QCString &relPath_, const QCString &url_,bool inlineImage_)
644 : attribs(attribs_), name(name_), type(type_),
645 relPath(relPath_), url(url_), inlineImage(inlineImage_) {}
646 HtmlAttribList attribs;
647 QCString name;
649 QCString width;
650 QCString height;
651 QCString relPath;
652 QCString url;
654 };
655 std::unique_ptr<Private> p;
656};
657
659{
660 public:
661 DocDiagramFileBase(DocParser *parser, DocNodeVariant *parent,const QCString &name,
662 const QCString &context, const QCString &srcFile,int srcLine)
663 : DocCompoundNode(parser,parent), p(std::make_unique<Private>(name, context, srcFile, srcLine)) {}
664 QCString name() const { return p->name; }
665 QCString file() const { return p->file; }
666 QCString relPath() const { return p->relPath; }
667 bool hasCaption() const { return !children().empty(); }
668 QCString width() const { return p->width; }
669 QCString height() const { return p->height; }
670 QCString context() const { return p->context; }
671 QCString srcFile() const { return p->srcFile; }
672 int srcLine() const { return p->srcLine; }
673
674 protected:
675 struct Private
676 {
677 Private(const QCString &name_,const QCString &context_,const QCString &srcFile_,int srcLine_)
678 : name(name_), context(context_), srcFile(srcFile_), srcLine(srcLine_) {}
679 QCString name;
680 QCString file;
681 QCString relPath;
682 QCString width;
683 QCString height;
684 QCString context;
685 QCString srcFile;
687 };
688 std::unique_ptr<Private> p;
689};
690
691/** Node representing a dot file */
693{
694 public:
695 DocDotFile(DocParser *parser,DocNodeVariant *parent,const QCString &name,const QCString &context,
696 const QCString &srcFile,int srcLine);
697 bool parse();
698};
699
700/** Node representing a msc file */
702{
703 public:
704 DocMscFile(DocParser *parser,DocNodeVariant *parent,const QCString &name,const QCString &context,
705 const QCString &srcFile,int srcLine);
706 bool parse();
707};
708
709/** Node representing a dia file */
711{
712 public:
713 DocDiaFile(DocParser *parser,DocNodeVariant *parent,const QCString &name,const QCString &context,
714 const QCString &srcFile,int srcLine);
715 bool parse();
716};
717
718/** Node representing a uml file */
720{
721 public:
722 DocPlantUmlFile(DocParser *parser,DocNodeVariant *parent,const QCString &name,const QCString &context,
723 const QCString &srcFile,int srcLine);
724 bool parse();
725};
726
727/** Node representing a VHDL flow chart */
729{
730 public:
732 void parse();
733 bool hasCaption() const { return !children().empty(); }
734 private:
735};
736
737/** Node representing a link to some item */
739{
740 public:
741 DocLink(DocParser *parser,DocNodeVariant *parent,const QCString &target);
742 QCString parse(bool,bool isXmlLink=FALSE);
743 QCString file() const { return m_file; }
744 QCString relPath() const { return m_relPath; }
745 QCString ref() const { return m_ref; }
746 QCString anchor() const { return m_anchor; }
747
748 private:
749 QCString m_file;
750 QCString m_relPath;
751 QCString m_ref;
752 QCString m_anchor;
753 QCString m_refText;
754};
755
756/** Node representing a reference to some item */
758{
759 public:
760 DocRef(DocParser *parser,DocNodeVariant *parent,const QCString &target,const QCString &context);
761 void parse();
762 QCString file() const { return m_file; }
763 QCString relPath() const { return m_relPath; }
764 QCString ref() const { return m_ref; }
765 QCString anchor() const { return m_anchor; }
766 QCString targetTitle() const { return m_text; }
767 SectionType sectionType() const { return m_sectionType; }
768 bool hasLinkText() const { return !children().empty(); }
769 bool refToAnchor() const { return m_refType==Anchor; }
770 bool refToSection() const { return m_refType==Section; }
771 bool refToTable() const { return m_refType==Table; }
772 bool isSubPage() const { return m_isSubPage; }
773
774 private:
777 bool m_isSubPage = false;
778 QCString m_file;
779 QCString m_relPath;
780 QCString m_ref;
781 QCString m_anchor;
782 QCString m_text;
783};
784
785/** Node representing an internal reference to some item */
787{
788 public:
789 DocInternalRef(DocParser *parser,DocNodeVariant *parent,const QCString &target);
790 void parse();
791 QCString file() const { return m_file; }
792 QCString relPath() const { return m_relPath; }
793 QCString anchor() const { return m_anchor; }
794
795 private:
796 QCString m_file;
797 QCString m_relPath;
798 QCString m_anchor;
799};
800
801/** Node representing a Hypertext reference */
803{
804 public:
805 DocHRef(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs,const QCString &url,
806 const QCString &relPath, const QCString &file)
809 Token parse();
810 QCString url() const { return m_url; }
811 QCString file() const { return m_file; }
812 QCString relPath() const { return m_relPath; }
813 const HtmlAttribList &attribs() const { return m_attribs; }
814
815 private:
816 HtmlAttribList m_attribs;
817 QCString m_url;
818 QCString m_relPath;
819 QCString m_file;
820};
821
822/** Node Html summary */
824{
825 public:
828 const HtmlAttribList &attribs() const { return m_attribs; }
829 void parse();
830
831 private:
832 HtmlAttribList m_attribs;
833};
834
835/** Node Html details */
837{
838 public:
841 const HtmlAttribList &attribs() const { return m_attribs; }
842 Token parse();
843 void parseSummary(DocNodeVariant *,HtmlAttribList &attribs);
844 const DocNodeVariant *summary() const { return m_summary.get(); }
845
846 private:
847 HtmlAttribList m_attribs;
848 std::unique_ptr<DocNodeVariant> m_summary;
849};
850
851/** Node Html heading */
853{
854 public:
857 int level() const { return m_level; }
858 const HtmlAttribList &attribs() const { return m_attribs; }
859 Token parse();
860
861 private:
862 int m_level = 0;
863 HtmlAttribList m_attribs;
864};
865
866/** Node representing a Html description item */
868{
869 public:
872 const HtmlAttribList &attribs() const { return m_attribs; }
873 Token parse();
874
875 private:
876 HtmlAttribList m_attribs;
877};
878
879/** Node representing a Html description list */
881{
882 public:
885 const HtmlAttribList &attribs() const { return m_attribs; }
886 Token parse();
887
888 private:
889 HtmlAttribList m_attribs;
890};
891
892/** Node representing a normal section */
894{
895 public:
896 DocSection(DocParser *parser,DocNodeVariant *parent,int level,const QCString &id) :
898 int level() const { return m_level; }
899 const DocNodeVariant *title() const { return m_title.get(); }
900 QCString anchor() const { return m_anchor; }
901 QCString id() const { return m_id; }
902 QCString file() const { return m_file; }
903 Token parse();
904
905 private:
906 int m_level = 0;
907 QCString m_id;
908 std::unique_ptr<DocNodeVariant> m_title;
909 QCString m_anchor;
910 QCString m_file;
911};
912
913/** Node representing a reference to a section */
915{
916 public:
917 DocSecRefItem(DocParser *parser,DocNodeVariant *parent,const QCString &target);
918 QCString target() const { return m_target; }
919 QCString file() const { return m_file; }
920 QCString anchor() const { return m_anchor; }
921 QCString relPath() const { return m_relPath; }
922 QCString ref() const { return m_ref; }
923 bool refToTable() const { return m_refType==Table; }
924 bool isSubPage() const { return m_isSubPage; }
925 void parse();
926
927 private:
928 QCString m_target;
930 bool m_isSubPage = false;
931 QCString m_file;
932 QCString m_relPath;
933 QCString m_ref;
934 QCString m_anchor;
935};
936
937/** Node representing a list of section references */
939{
940 public:
942 void parse();
943
944 private:
945};
946
947/** Node representing an internal section of documentation */
949{
950 public:
952 Token parse(int);
953
954 private:
955};
956
957/** Node representing an block of paragraphs */
959{
960 public:
962 Token parse();
963
964 private:
965};
966
967
968/** Node representing a simple list */
970{
971 public:
973 Token parse();
974
975 private:
976};
977
978/** Node representing a Html list */
980{
981 public:
985 Type type() const { return m_type; }
986 const HtmlAttribList &attribs() const { return m_attribs; }
987 Token parse();
988 Token parseXml();
989
990 private:
992 HtmlAttribList m_attribs;
993};
994
995/** Node representing a simple section */
997{
998 public:
1006 Type type() const { return m_type; }
1007 QCString typeString() const;
1008 Token parse(bool userTitle,bool needsSeparator);
1009 Token parseRcs();
1010 Token parseXml();
1011 void appendLinkWord(const QCString &word);
1012 bool hasTitle() const;
1013 const DocNodeVariant *title() const { return m_title.get(); }
1014
1015 private:
1017 std::unique_ptr<DocNodeVariant> m_title;
1018};
1019
1020/** Node representing a separator between two simple sections of the
1021 * same type.
1022 */
1024{
1025 public:
1027
1028 private:
1029};
1030
1031/** Node representing a parameter section */
1033{
1034 friend class DocParamList;
1035 public:
1041 {
1043 };
1047 Token parse(const QCString &cmdName,bool xmlContext,Direction d);
1048 Type type() const { return m_type; }
1050 bool hasTypeSpecifier() const { return m_hasTypeSpecifier; }
1051
1052 private:
1056};
1057
1058/** Node representing a paragraph in the documentation tree */
1060{
1061 public:
1062 DocPara(DocParser *parser,DocNodeVariant *parent);
1063 Token parse();
1064 bool isEmpty() const { return children().empty(); }
1065 void markFirst(bool v=TRUE) { m_isFirst=v; }
1066 void markLast(bool v=TRUE) { m_isLast=v; }
1067 bool isFirst() const { return m_isFirst; }
1068 bool isLast() const { return m_isLast; }
1069
1070 Token handleCommand(char cmdChar,const QCString &cmdName);
1071 Token handleHtmlStartTag(const QCString &tagName,const HtmlAttribList &tagHtmlAttribs);
1072 Token handleHtmlEndTag(const QCString &tagName);
1073 Token handleSimpleSection(DocSimpleSect::Type t,bool xmlContext=FALSE);
1074 Token handleXRefItem();
1075 Token handleParamSection(const QCString &cmdName,DocParamSect::Type t, bool xmlContext, int direction);
1076 void handleIncludeOperator(const QCString &cmdName,DocIncOperator::Type t);
1077 template<class T> void handleFile(const QCString &cmdName);
1078 void handleInclude(const QCString &cmdName,DocInclude::Type t);
1079 void handleLink(const QCString &cmdName,bool isJavaLink);
1080 void handleCite(char cmdChar,const QCString &cmdName);
1081 void handleDoxyConfig(char cmdChar,const QCString &cmdName);
1082 void handleEmoji(char cmdChar,const QCString &cmdName);
1083 void handleRef(char cmdChar,const QCString &cmdName);
1084 void handleSection(char cmdChar,const QCString &cmdName);
1085 void handleInheritDoc();
1086 void handleVhdlFlow();
1087 void handleILine(char cmdChar,const QCString &cmdName);
1088 void handleIFile(char cmdChar,const QCString &cmdName);
1089 void handleShowDate(char cmdChar,const QCString &cmdName);
1090 Token handleStartCode();
1091 Token handleHtmlHeader(const HtmlAttribList &tagHtmlAttribs,int level);
1092
1093 bool injectToken(Token tok,const QCString &tokText);
1094 const HtmlAttribList &attribs() const { return m_attribs; }
1095 void setAttribs(const HtmlAttribList &attribs) { m_attribs = attribs; }
1096
1097 private:
1098 bool m_isFirst = false;
1099 bool m_isLast = false;
1100 HtmlAttribList m_attribs;
1101};
1102
1103/** Node representing a parameter list. */
1104class DocParamList : public DocNode
1105{
1106 public:
1109 const DocNodeList &parameters() const { return m_params; }
1110 const DocNodeList &paramTypes() const { return m_paramTypes; }
1111 const DocNodeList &paragraphs() const { return m_paragraphs; }
1112 DocParamSect::Type type() const { return m_type; }
1114 void markFirst(bool b=TRUE) { m_isFirst=b; }
1115 void markLast(bool b=TRUE) { m_isLast=b; }
1116 bool isFirst() const { return m_isFirst; }
1117 bool isLast() const { return m_isLast; }
1118 Token parse(const QCString &cmdName);
1119 Token parseXml(const QCString &paramName);
1120
1121 private:
1122 DocNodeList m_paragraphs;
1123 DocNodeList m_params;
1124 DocNodeList m_paramTypes;
1127 bool m_isFirst = false;
1128 bool m_isLast = false;
1129};
1130
1131/** Node representing a simple list item */
1133{
1134 public:
1136 Token parse();
1137 const DocNodeVariant *paragraph() const { return m_paragraph.get(); }
1138
1139 private:
1140 std::unique_ptr<DocNodeVariant> m_paragraph;
1141};
1142
1143/** Node representing a HTML list item */
1145{
1146 public:
1147 DocHtmlListItem(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs,int num)
1149 int itemNumber() const { return m_itemNum; }
1150 const HtmlAttribList &attribs() const { return m_attribs; }
1151 Token parse();
1152 Token parseXml();
1153
1154 private:
1155 HtmlAttribList m_attribs;
1156 int m_itemNum = 0;
1157};
1158
1159/** Node representing a HTML description data */
1161{
1162 public:
1164 const HtmlAttribList &attribs() const { return m_attribs; }
1165 Token parse();
1166
1167 private:
1168 HtmlAttribList m_attribs;
1169};
1170
1171/** Node representing a HTML table cell */
1173{
1174 friend class DocHtmlTable;
1175 public:
1180 bool isHeading() const { return m_isHeading; }
1181 bool isFirst() const { return m_isFirst; }
1182 bool isLast() const { return m_isLast; }
1183 void markFirst(bool v=TRUE) { m_isFirst=v; }
1184 void markLast(bool v=TRUE) { m_isLast=v; }
1185 const HtmlAttribList &attribs() const { return m_attribs; }
1186 Token parse();
1187 Token parseXml();
1188 uint32_t rowIndex() const { return m_rowIdx; }
1189 uint32_t columnIndex() const { return m_colIdx; }
1190 uint32_t rowSpan() const;
1191 uint32_t colSpan() const;
1192 Alignment alignment() const;
1193 Valignment valignment() const;
1194
1195 private:
1196 void setRowIndex(uint32_t idx) { m_rowIdx = idx; }
1197 void setColumnIndex(uint32_t idx) { m_colIdx = idx; }
1198 bool m_isHeading = false;
1199 bool m_isFirst = false;
1200 bool m_isLast = false;
1201 HtmlAttribList m_attribs;
1202 uint32_t m_rowIdx = static_cast<uint32_t>(-1);
1203 uint32_t m_colIdx = static_cast<uint32_t>(-1);
1204};
1205
1206/** Node representing a HTML table caption */
1208{
1209 public:
1210 DocHtmlCaption(DocParser *parser,DocNodeVariant *parent,const HtmlAttribList &attribs);
1211 const HtmlAttribList &attribs() const { return m_attribs; }
1212 Token parse();
1213 bool hasCaptionId() const { return m_hasCaptionId; }
1214 QCString file() const { return m_file; }
1215 QCString anchor() const { return m_anchor; }
1216
1217 private:
1218 HtmlAttribList m_attribs;
1219 bool m_hasCaptionId = false;
1220 QCString m_file;
1221 QCString m_anchor;
1222};
1223
1224/** Node representing a HTML table row */
1226{
1227 friend class DocHtmlTable;
1228 public:
1231 size_t numCells() const { return children().size(); }
1232 const HtmlAttribList &attribs() const { return m_attribs; }
1233 Token parse();
1234 Token parseXml(bool header);
1235 bool isHeading() const;
1236 void setVisibleCells(uint32_t n) { m_visibleCells = n; }
1237 uint32_t visibleCells() const { return m_visibleCells; }
1238 uint32_t rowIndex() const { return m_rowIdx; }
1239
1240 private:
1241 void setRowIndex(uint32_t idx) { m_rowIdx = idx; }
1242 HtmlAttribList m_attribs;
1243 uint32_t m_visibleCells = 0;
1244 uint32_t m_rowIdx = static_cast<uint32_t>(-1);
1245};
1246
1247/** Node representing a HTML table */
1249{
1250 public:
1253 size_t numRows() const { return children().size(); }
1254 bool hasCaption() const;
1255 const HtmlAttribList &attribs() const { return m_attribs; }
1256 Token parse();
1257 Token parseXml();
1258 size_t numColumns() const { return m_numCols; }
1259 const DocNodeVariant *caption() const;
1260 const DocNodeVariant *firstRow() const;
1261
1262 private:
1263 void computeTableGrid();
1264 std::unique_ptr<DocNodeVariant> m_caption;
1265 HtmlAttribList m_attribs;
1266 size_t m_numCols = 0;
1267};
1268
1269/** Node representing an HTML blockquote */
1271{
1272 public:
1275 Token parse();
1276 const HtmlAttribList &attribs() const { return m_attribs; }
1277
1278 private:
1279 HtmlAttribList m_attribs;
1280};
1281
1282/** Root node of a text fragment */
1284{
1285 public:
1286 DocText(DocParser *parser) : DocCompoundNode(parser,nullptr) {}
1287 void parse();
1288 bool isEmpty() const { return children().empty(); }
1289};
1290
1291/** Root node of documentation tree */
1293{
1294 public:
1295 DocRoot(DocParser *parser,bool indent,bool sl)
1297 void parse();
1298 bool indent() const { return m_indent; }
1299 bool singleLine() const { return m_singleLine; }
1300 bool isEmpty() const { return children().empty(); }
1301
1302 private:
1303 bool m_indent = false;
1304 bool m_singleLine = false;
1305};
1306
1307//--------------------------------------------------------------------------------------
1308
1309/// returns the parent node of a given node \a n or nullptr if the node has no parent.
1311{
1312 return n ? std::visit([](auto &&x)->decltype(auto) { return x.parent(); }, *n) : nullptr;
1313}
1314
1315/// returns the parent node of a given node \a n or nullptr if the node has no parent.
1316constexpr const DocNodeVariant *parent(const DocNodeVariant *n)
1317{
1318 return n ? std::visit([](auto &&x)->decltype(auto) { return x.parent(); }, *n) : nullptr;
1319}
1320
1321namespace details
1322{
1323
1324template<class T,class... Ts>
1325struct Impl
1326{
1327 static constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
1328 {
1329 return std::holds_alternative<T>(v) || Impl<Ts...>::holds_one_of_alternatives(v);
1330 }
1331};
1332
1333template<class T>
1334struct Impl<T>
1335{
1336 static constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
1337 {
1338 return std::holds_alternative<T>(v);
1339 }
1340};
1341
1342} // namespace details
1343
1344/// returns true iff \a v holds one of types passed as template parameters
1345template<class... Ts>
1350
1351namespace details
1352{
1353
1354// Helper type trait to check if a type has member function children(). Default case is false.
1355template <typename T, typename = void>
1356struct has_method_children : std::false_type {};
1357
1358// Use SFINAE to have a partial template specialization derived from std::true_type in case T has method children()
1359template <typename T>
1360struct has_method_children<T, std::void_t<decltype(std::declval<T>().children())>> : std::true_type {};
1361
1362} // namespace details
1363
1364// Call children() on variant v if the contained type has this method, otherwise return nullptr
1366{
1367 return std::visit([](auto&& value) -> DocNodeList* {
1368 if constexpr (details::has_method_children<decltype(value)>::value) {
1369 return &value.children();
1370 } else {
1371 return nullptr;
1372 }
1373 }, *v);
1374}
1375
1376//----------------- DocNodeList ---------------------------------------
1377
1378template<class T,class...Args>
1379inline void DocNodeList::append(Args&&... args)
1380{
1381 // add a DocNodeVariant to the list containing an node T as its active member.
1382 emplace_back(T(std::forward<Args>(args)...));
1383 // store a pointer to the variant holding node T inside the node itself.
1384 // Since DocNodeList is a GrowVector this reference will remain valid even if new
1385 // elements are added (which would not be the case if a std::vector was used)
1386 std::get_if<T>(&back())->setThisVariant(&back());
1387}
1388
1389template<class T>
1391{
1392 return std::get_if<T>(&back());
1393}
1394
1395// ---------------- Debug helpers -------------------------------
1396
1397#define DN(x) #x
1398#define DN_SEP ,
1399inline const char *docNodeName(const DocNodeVariant &v)
1400{
1401 static const char *table[] = { DOC_NODES };
1402 return table[v.index()];
1403}
1404#undef DN
1405#undef DN_SEP
1406
1407inline void dumpDocNodeSizes()
1408{
1409#define DN(x) #x
1410#define DN_SEP ,
1411 static const char *tableWithNames[] = { DOC_NODES };
1412#undef DN
1413#undef DN_SEP
1414
1415#define DN(x) sizeof(x)
1416#define DN_SEP ,
1417 static size_t tableWithSizes[] = { DOC_NODES };
1418#undef DN
1419#undef DN_SEP
1420
1421 size_t maxSize=0;
1422 printf("DocNodeVariant(\n");
1423 for (size_t i=0;i<sizeof(tableWithNames)/sizeof(tableWithNames[0]);i++)
1424 {
1425 printf(" /* %2zu */ sizeof(%s)=%zu\n",i,tableWithNames[i],tableWithSizes[i]);
1426 if (tableWithSizes[i]>maxSize) maxSize = tableWithSizes[i];
1427 }
1428 printf(")=%zu\n",maxSize);
1429}
1430
1431inline void dumpDocNodeList(const DocNodeList &children)
1432{
1433 printf("children=[\n");
1434 for (const auto &child : children)
1435 {
1436 const DocWord *w = std::get_if<DocWord>(&child);
1437 printf(" %s (%p) %s\n",docNodeName(child),(void*)&child,qPrint(w?w->word():""));
1438 }
1439 printf("]\n");
1440}
1441
1442//----------------------------------------------------------------------------------
1443
1444/** Class representing the abstract syntax tree of a documentation block */
1446{
1447 public:
1448 // Note that r can only be a rvalue, not a general forwarding reference.
1449 // The compiler will error on lvalues because DotNodeVariant doesn't have a copy constructor
1450 template<class DocNode>
1451 DocNodeAST(DocNode &&r) : root(std::move(r))
1452 {
1453 std::get_if<DocNode>(&root)->setThisVariant(&root);
1454 }
1455 bool isEmpty() const override
1456 {
1457 if (std::holds_alternative<DocRoot>(root))
1458 {
1459 return std::get<DocRoot>(root).isEmpty();
1460 }
1461 else if (std::holds_alternative<DocText>(root))
1462 {
1463 return std::get<DocText>(root).isEmpty();
1464 }
1465 return false;
1466 }
1468};
1469
1470template<class T,class... Args>
1471std::unique_ptr<DocNodeVariant> createDocNode(Args&&...args)
1472{
1473 auto node = std::make_unique<DocNodeVariant>(T(std::forward<Args>(args)...));
1474 std::get_if<T>(node.get())->setThisVariant(node.get());
1475 return node;
1476}
1477
1478#endif
The common base class of all entity definitions found in the sources.
Definition definition.h:76
const HtmlAttribList & attribs() const
Definition docnode.h:234
HtmlAttribList m_attribs
Definition docnode.h:239
DocAnchor(DocParser *parser, DocNodeVariant *parent, const QCString &id, bool newAnchor)
Definition docnode.cpp:208
QCString anchor() const
Definition docnode.h:231
QCString m_anchor
Definition docnode.h:237
QCString m_file
Definition docnode.h:238
QCString file() const
Definition docnode.h:232
int m_depth
Definition docnode.h:571
bool isCheckedList() const
Definition docnode.h:563
bool isEnumList() const
Definition docnode.h:561
int depth() const
Definition docnode.h:564
int m_indent
Definition docnode.h:568
Token parse()
Definition docnode.cpp:2809
bool m_isCheckedList
Definition docnode.h:570
int indent() const
Definition docnode.h:562
DocAutoList(DocParser *parser, DocNodeVariant *parent, int indent, bool isEnumList, int depth, bool isCheckedList)
Definition docnode.cpp:2802
bool m_isEnumList
Definition docnode.h:569
int itemNumber() const
Definition docnode.h:579
DocAutoListItem(DocParser *parser, DocNodeVariant *parent, int indent, int num)
Definition docnode.cpp:2762
QCString m_anchor
Definition docnode.h:257
DocCite(DocParser *parser, DocNodeVariant *parent, const QCString &target, const QCString &context)
Definition docnode.cpp:887
QCString text() const
Definition docnode.h:251
QCString m_relPath
Definition docnode.h:255
QCString relPath() const
Definition docnode.h:248
QCString m_ref
Definition docnode.h:256
QCString anchor() const
Definition docnode.h:250
QCString m_file
Definition docnode.h:254
QCString ref() const
Definition docnode.h:249
QCString file() const
Definition docnode.h:247
QCString m_text
Definition docnode.h:258
DocNodeList & children()
Definition docnode.h:142
const DocNodeList & children() const
Definition docnode.h:143
DocCompoundNode(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:140
DocNodeList m_children
Definition docnode.h:146
bool parse()
Definition docnode.cpp:1136
DocDiaFile(DocParser *parser, DocNodeVariant *parent, const QCString &name, const QCString &context, const QCString &srcFile, int srcLine)
Definition docnode.cpp:1129
QCString relPath() const
Definition docnode.h:666
QCString height() const
Definition docnode.h:669
QCString srcFile() const
Definition docnode.h:671
QCString file() const
Definition docnode.h:665
std::unique_ptr< Private > p
Definition docnode.h:688
int srcLine() const
Definition docnode.h:672
DocDiagramFileBase(DocParser *parser, DocNodeVariant *parent, const QCString &name, const QCString &context, const QCString &srcFile, int srcLine)
Definition docnode.h:661
bool hasCaption() const
Definition docnode.h:667
QCString context() const
Definition docnode.h:670
QCString width() const
Definition docnode.h:668
QCString name() const
Definition docnode.h:664
bool parse()
Definition docnode.cpp:1058
DocDotFile(DocParser *parser, DocNodeVariant *parent, const QCString &name, const QCString &context, const QCString &srcFile, int srcLine)
Definition docnode.cpp:1051
int index() const
Definition docnode.h:326
DocEmoji(DocParser *parser, DocNodeVariant *parent, const QCString &symName)
Definition docnode.cpp:159
int m_index
Definition docnode.h:330
QCString name() const
Definition docnode.h:325
QCString m_symName
Definition docnode.h:329
QCString m_relPath
Definition docnode.h:527
QCString text() const
Definition docnode.h:514
QCString name() const
Definition docnode.h:513
bool isInline() const
Definition docnode.h:517
QCString m_text
Definition docnode.h:526
int id() const
Definition docnode.h:516
QCString m_name
Definition docnode.h:525
DocFormula(DocParser *parser, DocNodeVariant *parent, int id)
Definition docnode.cpp:514
QCString relPath() const
Definition docnode.h:515
Token parse()
Definition docnode.cpp:1450
HtmlAttribList m_attribs
Definition docnode.h:816
QCString url() const
Definition docnode.h:810
QCString m_file
Definition docnode.h:819
DocHRef(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, const QCString &url, const QCString &relPath, const QCString &file)
Definition docnode.h:805
QCString relPath() const
Definition docnode.h:812
QCString file() const
Definition docnode.h:811
const HtmlAttribList & attribs() const
Definition docnode.h:813
QCString m_url
Definition docnode.h:817
QCString m_relPath
Definition docnode.h:818
DocHorRuler(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:217
const HtmlAttribList & attribs() const
Definition docnode.h:220
HtmlAttribList m_attribs
Definition docnode.h:223
DocHtmlBlockQuote(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:1273
const HtmlAttribList & attribs() const
Definition docnode.h:1276
HtmlAttribList m_attribs
Definition docnode.h:1279
bool hasCaptionId() const
Definition docnode.h:1213
HtmlAttribList m_attribs
Definition docnode.h:1218
bool m_hasCaptionId
Definition docnode.h:1219
DocHtmlCaption(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.cpp:1655
QCString m_file
Definition docnode.h:1220
const HtmlAttribList & attribs() const
Definition docnode.h:1211
QCString anchor() const
Definition docnode.h:1215
QCString file() const
Definition docnode.h:1214
QCString m_anchor
Definition docnode.h:1221
Valignment valignment() const
Definition docnode.cpp:1859
friend class DocHtmlTable
Definition docnode.h:1174
void setColumnIndex(uint32_t idx)
Definition docnode.h:1197
bool isFirst() const
Definition docnode.h:1181
Token parseXml()
Definition docnode.cpp:1763
uint32_t columnIndex() const
Definition docnode.h:1189
void setRowIndex(uint32_t idx)
Definition docnode.h:1196
void markLast(bool v=TRUE)
Definition docnode.h:1184
uint32_t rowSpan() const
Definition docnode.cpp:1797
uint32_t rowIndex() const
Definition docnode.h:1188
DocHtmlCell(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, bool isHeading)
Definition docnode.h:1178
uint32_t m_colIdx
Definition docnode.h:1203
bool m_isFirst
Definition docnode.h:1199
void markFirst(bool v=TRUE)
Definition docnode.h:1183
Alignment alignment() const
Definition docnode.cpp:1821
bool isLast() const
Definition docnode.h:1182
bool isHeading() const
Definition docnode.h:1180
bool m_isLast
Definition docnode.h:1200
const HtmlAttribList & attribs() const
Definition docnode.h:1185
HtmlAttribList m_attribs
Definition docnode.h:1201
bool m_isHeading
Definition docnode.h:1198
Token parse()
Definition docnode.cpp:1729
uint32_t m_rowIdx
Definition docnode.h:1202
uint32_t colSpan() const
Definition docnode.cpp:1809
DocHtmlDescData(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:1163
const HtmlAttribList & attribs() const
Definition docnode.h:1164
HtmlAttribList m_attribs
Definition docnode.h:1168
DocHtmlDescList(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:883
const HtmlAttribList & attribs() const
Definition docnode.h:885
HtmlAttribList m_attribs
Definition docnode.h:889
HtmlAttribList m_attribs
Definition docnode.h:876
DocHtmlDescTitle(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:870
const HtmlAttribList & attribs() const
Definition docnode.h:872
const HtmlAttribList & attribs() const
Definition docnode.h:841
DocHtmlDetails(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:839
void parseSummary(DocNodeVariant *, HtmlAttribList &attribs)
Definition docnode.cpp:1440
const DocNodeVariant * summary() const
Definition docnode.h:844
HtmlAttribList m_attribs
Definition docnode.h:847
std::unique_ptr< DocNodeVariant > m_summary
Definition docnode.h:848
Token parse()
Definition docnode.cpp:1265
HtmlAttribList m_attribs
Definition docnode.h:863
const HtmlAttribList & attribs() const
Definition docnode.h:858
DocHtmlHeader(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, int level)
Definition docnode.h:855
int level() const
Definition docnode.h:857
Type m_type
Definition docnode.h:991
Token parseXml()
Definition docnode.cpp:2609
const HtmlAttribList & attribs() const
Definition docnode.h:986
HtmlAttribList m_attribs
Definition docnode.h:992
Token parse()
Definition docnode.cpp:2534
Type type() const
Definition docnode.h:985
DocHtmlList(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, Type t)
Definition docnode.h:983
const HtmlAttribList & attribs() const
Definition docnode.h:1150
HtmlAttribList m_attribs
Definition docnode.h:1155
int itemNumber() const
Definition docnode.h:1149
DocHtmlListItem(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, int num)
Definition docnode.h:1147
Token parseXml(bool header)
Definition docnode.cpp:1961
uint32_t m_rowIdx
Definition docnode.h:1244
void setVisibleCells(uint32_t n)
Definition docnode.h:1236
friend class DocHtmlTable
Definition docnode.h:1227
DocHtmlRow(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:1229
HtmlAttribList m_attribs
Definition docnode.h:1242
bool isHeading() const
Definition docnode.cpp:1881
size_t numCells() const
Definition docnode.h:1231
uint32_t m_visibleCells
Definition docnode.h:1243
uint32_t rowIndex() const
Definition docnode.h:1238
const HtmlAttribList & attribs() const
Definition docnode.h:1232
void setRowIndex(uint32_t idx)
Definition docnode.h:1241
uint32_t visibleCells() const
Definition docnode.h:1237
Token parse()
Definition docnode.cpp:1896
const HtmlAttribList & attribs() const
Definition docnode.h:828
HtmlAttribList m_attribs
Definition docnode.h:832
DocHtmlSummary(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:826
size_t numRows() const
Definition docnode.h:1253
Token parseXml()
Definition docnode.cpp:2119
std::unique_ptr< DocNodeVariant > m_caption
Definition docnode.h:1264
Token parse()
Definition docnode.cpp:2041
void computeTableGrid()
determines the location of all cells in a grid, resolving row and column spans.
Definition docnode.cpp:2176
size_t numColumns() const
Definition docnode.h:1258
size_t m_numCols
Definition docnode.h:1266
const DocNodeVariant * caption() const
Definition docnode.cpp:2027
const HtmlAttribList & attribs() const
Definition docnode.h:1255
bool hasCaption() const
Definition docnode.cpp:2022
HtmlAttribList m_attribs
Definition docnode.h:1265
DocHtmlTable(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:1251
const DocNodeVariant * firstRow() const
Definition docnode.cpp:2032
const HtmlAttribList & attribs() const
Definition docnode.h:636
QCString relPath() const
Definition docnode.h:632
QCString name() const
Definition docnode.h:628
QCString url() const
Definition docnode.h:633
QCString height() const
Definition docnode.h:631
Type type() const
Definition docnode.h:627
QCString width() const
Definition docnode.h:630
DocImage(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs, const QCString &name, Type t, const QCString &url=QCString(), bool inlineImage=TRUE)
Definition docnode.cpp:1242
@ DocBook
Definition docnode.h:624
std::unique_ptr< Private > p
Definition docnode.h:655
void parse()
Definition docnode.cpp:1257
bool isInlineImage() const
Definition docnode.h:634
bool isSVG() const
Definition docnode.cpp:1248
bool hasCaption() const
Definition docnode.h:629
bool m_stripCodeComments
Definition docnode.h:502
const char * typeAsString() const
Definition docnode.h:467
bool stripCodeComments() const
Definition docnode.h:487
bool isLast() const
Definition docnode.h:484
QCString m_exampleFile
Definition docnode.h:504
void markFirst(bool v=TRUE)
Definition docnode.h:485
QCString includeFileName() const
Definition docnode.h:490
QCString text() const
Definition docnode.h:480
QCString m_includeFileName
Definition docnode.h:505
QCString m_context
Definition docnode.h:499
QCString context() const
Definition docnode.h:482
QCString exampleFile() const
Definition docnode.h:489
bool m_isExample
Definition docnode.h:503
int line() const
Definition docnode.h:478
Type type() const
Definition docnode.h:466
bool isFirst() const
Definition docnode.h:483
QCString pattern() const
Definition docnode.h:481
DocIncOperator(DocParser *parser, DocNodeVariant *parent, Type t, const QCString &pat, const QCString &context, bool stripCodeComments, bool isExample, const QCString &exampleFile)
Definition docnode.h:461
bool showLineNo() const
Definition docnode.h:479
QCString m_pattern
Definition docnode.h:498
void markLast(bool v=TRUE)
Definition docnode.h:486
QCString m_text
Definition docnode.h:497
bool m_showLineNo
Definition docnode.h:496
bool isExample() const
Definition docnode.h:488
QCString blockId() const
Definition docnode.h:435
bool m_trimLeft
Definition docnode.h:451
QCString m_context
Definition docnode.h:445
QCString extension() const
Definition docnode.h:431
bool isBlock() const
Definition docnode.h:439
void parse()
Definition docnode.cpp:267
QCString m_text
Definition docnode.h:446
Type m_type
Definition docnode.h:447
bool m_isExample
Definition docnode.h:449
bool m_isBlock
Definition docnode.h:450
DocInclude(DocParser *parser, DocNodeVariant *parent, const QCString &file, const QCString &context, Type t, bool stripCodeComments, bool isExample, const QCString &exampleFile, const QCString &blockId, bool isBlock, bool trimLeft)
Definition docnode.h:422
bool stripCodeComments() const
Definition docnode.h:436
@ LatexInclude
Definition docnode.h:418
@ SnippetWithLines
Definition docnode.h:419
@ DontIncWithLines
Definition docnode.h:420
@ IncWithLines
Definition docnode.h:419
@ HtmlInclude
Definition docnode.h:418
@ VerbInclude
Definition docnode.h:418
@ DontInclude
Definition docnode.h:418
@ DocbookInclude
Definition docnode.h:420
QCString m_blockId
Definition docnode.h:453
Type type() const
Definition docnode.h:432
QCString exampleFile() const
Definition docnode.h:438
QCString text() const
Definition docnode.h:433
bool m_stripCodeComments
Definition docnode.h:448
QCString file() const
Definition docnode.h:430
QCString m_exampleFile
Definition docnode.h:452
bool trimLeft() const
Definition docnode.h:440
bool isExample() const
Definition docnode.h:437
QCString context() const
Definition docnode.h:434
QCString m_file
Definition docnode.h:444
QCString m_entry
Definition docnode.h:543
Token parse()
Definition docnode.cpp:1560
const MemberDef * m_member
Definition docnode.h:545
DocIndexEntry(DocParser *parser, DocNodeVariant *parent, const Definition *scope, const MemberDef *md)
Definition docnode.h:535
QCString entry() const
Definition docnode.h:540
const Definition * m_scope
Definition docnode.h:544
const Definition * scope() const
Definition docnode.h:538
const MemberDef * member() const
Definition docnode.h:539
DocInternal(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:951
Token parse(int)
Definition docnode.cpp:1500
QCString m_file
Definition docnode.h:796
QCString file() const
Definition docnode.h:791
QCString m_anchor
Definition docnode.h:798
DocInternalRef(DocParser *parser, DocNodeVariant *parent, const QCString &target)
Definition docnode.cpp:670
QCString relPath() const
Definition docnode.h:792
QCString anchor() const
Definition docnode.h:793
QCString m_relPath
Definition docnode.h:797
DocLineBreak(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:203
HtmlAttribList m_attribs
Definition docnode.h:210
DocLineBreak(DocParser *parser, DocNodeVariant *parent, const HtmlAttribList &attribs)
Definition docnode.h:204
const HtmlAttribList & attribs() const
Definition docnode.h:207
QCString m_word
Definition docnode.h:177
QCString m_anchor
Definition docnode.h:181
QCString file() const
Definition docnode.h:170
QCString relPath() const
Definition docnode.h:171
QCString ref() const
Definition docnode.h:172
QCString word() const
Definition docnode.h:169
QCString m_file
Definition docnode.h:179
QCString anchor() const
Definition docnode.h:173
QCString m_ref
Definition docnode.h:178
QCString m_relPath
Definition docnode.h:180
DocLinkedWord(DocParser *parser, DocNodeVariant *parent, const QCString &word, const QCString &ref, const QCString &file, const QCString &anchor, const QCString &tooltip)
Definition docnode.cpp:191
QCString m_tooltip
Definition docnode.h:182
QCString tooltip() const
Definition docnode.h:174
DocMscFile(DocParser *parser, DocNodeVariant *parent, const QCString &name, const QCString &context, const QCString &srcFile, int srcLine)
Definition docnode.cpp:1089
bool parse()
Definition docnode.cpp:1096
bool isEmpty() const override
Definition docnode.h:1455
DocNodeVariant root
Definition docnode.h:1467
DocNodeAST(DocNode &&r)
Definition docnode.h:1451
void setParent(DocNodeVariant *parent)
Definition docnode.h:101
DocNode(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:84
bool m_insidePre
Definition docnode.h:111
const DocNodeVariant * thisVariant() const
Definition docnode.h:93
void setInsidePreformatted(bool p)
Definition docnode.h:108
DocNodeVariant * thisVariant()
Definition docnode.h:92
DocNodeVariant * m_parent
Definition docnode.h:113
bool isPreformatted() const
Definition docnode.h:104
DocParser * parser()
Definition docnode.h:97
void setThisVariant(DocNodeVariant *thisVariant)
Definition docnode.h:95
DocNodeVariant * parent()
Definition docnode.h:89
DocNodeVariant * m_thisVariant
Definition docnode.h:114
~DocNode()=default
const DocNodeVariant * parent() const
Definition docnode.h:90
const DocParser * parser() const
Definition docnode.h:98
DocParser * m_parser
Definition docnode.h:112
@ Unknown
Definition docnode.h:109
@ Table
Definition docnode.h:109
@ Section
Definition docnode.h:109
@ Anchor
Definition docnode.h:109
DocParBlock(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:961
Token parse()
Definition docnode.cpp:2703
bool isEmpty() const
Definition docnode.h:1064
Token handleSimpleSection(DocSimpleSect::Type t, bool xmlContext=FALSE)
Definition docnode.cpp:3231
void handleLink(const QCString &cmdName, bool isJavaLink)
Definition docnode.cpp:3674
void handleInheritDoc()
Definition docnode.cpp:3932
void handleCite(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3284
DocPara(DocParser *parser, DocNodeVariant *parent)
Definition docnode.cpp:3225
void handleInclude(const QCString &cmdName, DocInclude::Type t)
Definition docnode.cpp:3742
Token handleCommand(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3969
void handleDoxyConfig(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3347
void handleSection(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3847
void handleFile(const QCString &cmdName)
Definition docnode.cpp:3635
bool isLast() const
Definition docnode.h:1068
void handleIFile(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3551
Token handleParamSection(const QCString &cmdName, DocParamSect::Type t, bool xmlContext, int direction)
Definition docnode.cpp:3261
const HtmlAttribList & attribs() const
Definition docnode.h:1094
void markLast(bool v=TRUE)
Definition docnode.h:1066
Token handleHtmlStartTag(const QCString &tagName, const HtmlAttribList &tagHtmlAttribs)
Definition docnode.cpp:4713
void handleEmoji(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3316
void handleIncludeOperator(const QCString &cmdName, DocIncOperator::Type t)
Definition docnode.cpp:3575
bool isFirst() const
Definition docnode.h:1067
void markFirst(bool v=TRUE)
Definition docnode.h:1065
void handleRef(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3715
void handleILine(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3537
void setAttribs(const HtmlAttribList &attribs)
Definition docnode.h:1095
HtmlAttribList m_attribs
Definition docnode.h:1100
bool m_isFirst
Definition docnode.h:1098
Token parse()
Definition docnode.cpp:5451
void handleVhdlFlow()
Definition docnode.cpp:3667
Token handleHtmlHeader(const HtmlAttribList &tagHtmlAttribs, int level)
Definition docnode.cpp:3878
void handleShowDate(char cmdChar, const QCString &cmdName)
Definition docnode.cpp:3466
bool m_isLast
Definition docnode.h:1099
Token handleXRefItem()
Definition docnode.cpp:3445
Token handleHtmlEndTag(const QCString &tagName)
Definition docnode.cpp:5181
Token handleStartCode()
Definition docnode.cpp:3896
bool injectToken(Token tok, const QCString &tokText)
Definition docnode.cpp:3889
DocNodeList m_paramTypes
Definition docnode.h:1124
DocNodeList m_paragraphs
Definition docnode.h:1122
bool m_isFirst
Definition docnode.h:1127
DocParamSect::Direction m_dir
Definition docnode.h:1126
const DocNodeList & parameters() const
Definition docnode.h:1109
bool isFirst() const
Definition docnode.h:1116
const DocNodeList & paramTypes() const
Definition docnode.h:1110
void markFirst(bool b=TRUE)
Definition docnode.h:1114
DocParamSect::Type type() const
Definition docnode.h:1112
Token parseXml(const QCString &paramName)
Definition docnode.cpp:3114
void markLast(bool b=TRUE)
Definition docnode.h:1115
bool isLast() const
Definition docnode.h:1117
Token parse(const QCString &cmdName)
Definition docnode.cpp:3035
bool m_isLast
Definition docnode.h:1128
DocParamList(DocParser *parser, DocNodeVariant *parent, DocParamSect::Type t, DocParamSect::Direction d)
Definition docnode.h:1107
DocParamSect::Type m_type
Definition docnode.h:1125
DocParamSect::Direction direction() const
Definition docnode.h:1113
DocNodeList m_params
Definition docnode.h:1123
const DocNodeList & paragraphs() const
Definition docnode.h:1111
bool hasInOutSpecifier() const
Definition docnode.h:1049
DocParamSect(DocParser *parser, DocNodeVariant *parent, Type t)
Definition docnode.h:1044
friend class DocParamList
Definition docnode.h:1034
bool m_hasTypeSpecifier
Definition docnode.h:1055
Token parse(const QCString &cmdName, bool xmlContext, Direction d)
Definition docnode.cpp:3182
bool m_hasInOutSpecifier
Definition docnode.h:1054
bool hasTypeSpecifier() const
Definition docnode.h:1050
Type type() const
Definition docnode.h:1048
DocPlantUmlFile(DocParser *parser, DocNodeVariant *parent, const QCString &name, const QCString &context, const QCString &srcFile, int srcLine)
Definition docnode.cpp:1168
QCString anchor() const
Definition docnode.h:765
QCString m_file
Definition docnode.h:778
SectionType m_sectionType
Definition docnode.h:776
SectionType sectionType() const
Definition docnode.h:767
QCString m_text
Definition docnode.h:782
QCString relPath() const
Definition docnode.h:763
QCString targetTitle() const
Definition docnode.h:766
void parse()
Definition docnode.cpp:841
bool isSubPage() const
Definition docnode.h:772
bool refToTable() const
Definition docnode.h:771
QCString file() const
Definition docnode.h:762
QCString m_ref
Definition docnode.h:780
bool refToAnchor() const
Definition docnode.h:769
QCString ref() const
Definition docnode.h:764
QCString m_relPath
Definition docnode.h:779
DocRef(DocParser *parser, DocNodeVariant *parent, const QCString &target, const QCString &context)
Definition docnode.cpp:705
RefType m_refType
Definition docnode.h:775
QCString m_anchor
Definition docnode.h:781
bool refToSection() const
Definition docnode.h:770
bool m_isSubPage
Definition docnode.h:777
bool hasLinkText() const
Definition docnode.h:768
bool singleLine() const
Definition docnode.h:1299
bool indent() const
Definition docnode.h:1298
bool m_singleLine
Definition docnode.h:1304
void parse()
Definition docnode.cpp:6034
DocRoot(DocParser *parser, bool indent, bool sl)
Definition docnode.h:1295
bool m_indent
Definition docnode.h:1303
bool isEmpty() const
Definition docnode.h:1300
QCString m_file
Definition docnode.h:931
bool refToTable() const
Definition docnode.h:923
QCString m_target
Definition docnode.h:928
QCString relPath() const
Definition docnode.h:921
bool m_isSubPage
Definition docnode.h:930
QCString m_anchor
Definition docnode.h:934
QCString target() const
Definition docnode.h:918
QCString file() const
Definition docnode.h:919
QCString m_ref
Definition docnode.h:933
DocSecRefItem(DocParser *parser, DocNodeVariant *parent, const QCString &target)
Definition docnode.cpp:533
QCString m_relPath
Definition docnode.h:932
QCString anchor() const
Definition docnode.h:920
RefType m_refType
Definition docnode.h:929
QCString ref() const
Definition docnode.h:922
bool isSubPage() const
Definition docnode.h:924
DocSecRefList(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:941
std::unique_ptr< DocNodeVariant > m_title
Definition docnode.h:908
QCString m_id
Definition docnode.h:907
QCString file() const
Definition docnode.h:902
QCString m_file
Definition docnode.h:910
int level() const
Definition docnode.h:898
Token parse()
Definition docnode.cpp:5756
DocSection(DocParser *parser, DocNodeVariant *parent, int level, const QCString &id)
Definition docnode.h:896
QCString id() const
Definition docnode.h:901
QCString anchor() const
Definition docnode.h:900
const DocNodeVariant * title() const
Definition docnode.h:899
QCString m_anchor
Definition docnode.h:909
int m_level
Definition docnode.h:906
DocSeparator(DocParser *parser, DocNodeVariant *parent, const QCString &chars)
Definition docnode.h:348
QCString m_chars
Definition docnode.h:352
QCString chars() const
Definition docnode.h:350
DocSimpleList(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:972
Token parse()
Definition docnode.cpp:2747
std::unique_ptr< DocNodeVariant > m_paragraph
Definition docnode.h:1140
const DocNodeVariant * paragraph() const
Definition docnode.h:1137
DocSimpleListItem(DocParser *parser, DocNodeVariant *parent)
Definition docnode.cpp:2728
QCString typeString() const
Definition docnode.cpp:3006
Type type() const
Definition docnode.h:1006
Token parse(bool userTitle, bool needsSeparator)
Definition docnode.cpp:2896
Token parseRcs()
Definition docnode.cpp:2933
DocSimpleSect(DocParser *parser, DocNodeVariant *parent, Type t)
Definition docnode.cpp:2886
const DocNodeVariant * title() const
Definition docnode.h:1013
Token parseXml()
Definition docnode.cpp:2950
void appendLinkWord(const QCString &word)
Definition docnode.cpp:2986
bool hasTitle() const
Definition docnode.cpp:2891
std::unique_ptr< DocNodeVariant > m_title
Definition docnode.h:1017
DocSimpleSectSep(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:1026
DocStyleChange(DocParser *parser, DocNodeVariant *parent, size_t position, Style s, const QCString &tagName, bool enable, const HtmlAttribList *attribs=nullptr)
Definition docnode.h:285
const char * styleString() const
Definition docnode.cpp:125
const HtmlAttribList & attribs() const
Definition docnode.h:296
QCString tagName() const
Definition docnode.h:297
Style style() const
Definition docnode.h:292
Style m_style
Definition docnode.h:301
size_t position() const
Definition docnode.h:295
HtmlAttribList m_attribs
Definition docnode.h:303
bool enable() const
Definition docnode.h:294
size_t m_position
Definition docnode.h:300
QCString m_tagName
Definition docnode.h:304
HtmlEntityMapper::SymType m_symbol
Definition docnode.h:317
HtmlEntityMapper::SymType symbol() const
Definition docnode.h:313
DocSymbol(DocParser *parser, DocNodeVariant *parent, HtmlEntityMapper::SymType s)
Definition docnode.h:311
static HtmlEntityMapper::SymType decodeSymbol(const QCString &symName)
Definition docnode.cpp:152
DocText(DocParser *parser)
Definition docnode.h:1286
void parse()
Definition docnode.cpp:5926
bool isEmpty() const
Definition docnode.h:1288
void parse()
Definition docnode.cpp:2855
void parseFromString(DocNodeVariant *, const QCString &title)
Definition docnode.cpp:2873
DocTitle(DocParser *parser, DocNodeVariant *parent)
Definition docnode.h:591
bool hasTitle() const
Definition docnode.h:594
QCString url() const
Definition docnode.h:191
QCString m_url
Definition docnode.h:195
bool m_isEmail
Definition docnode.h:196
DocURL(DocParser *parser, DocNodeVariant *parent, const QCString &url, bool isEmail)
Definition docnode.h:189
bool isEmail() const
Definition docnode.h:192
QCString srcFile() const
Definition docnode.h:378
int srcLine() const
Definition docnode.h:379
QCString height() const
Definition docnode.h:373
DocVerbatim(DocParser *parser, DocNodeVariant *parent, const QCString &context, const QCString &text, Type t, bool isExample, const QCString &exampleFile, bool isBlock=FALSE, const QCString &lang=QCString())
Definition docnode.cpp:257
bool hasCaption() const
Definition docnode.h:371
QCString language() const
Definition docnode.h:369
const DocNodeList & children() const
Definition docnode.h:376
DocNodeList & children()
Definition docnode.h:377
void setWidth(const QCString &w)
Definition docnode.h:381
std::unique_ptr< Private > p
Definition docnode.h:410
bool isBlock() const
Definition docnode.h:370
bool isExample() const
Definition docnode.h:366
QCString context() const
Definition docnode.h:365
Type type() const
Definition docnode.h:363
QCString text() const
Definition docnode.h:364
QCString exampleFile() const
Definition docnode.h:367
void setHeight(const QCString &h)
Definition docnode.h:382
QCString engine() const
Definition docnode.h:374
bool useBitmap() const
Definition docnode.h:375
void setLocation(const QCString &file, int line)
Definition docnode.h:385
QCString relPath() const
Definition docnode.h:368
void setUseBitmap(const bool &u)
Definition docnode.h:384
void setEngine(const QCString &e)
Definition docnode.h:383
@ JavaDocLiteral
Definition docnode.h:359
void setText(const QCString &t)
Definition docnode.h:380
QCString width() const
Definition docnode.h:372
bool hasCaption() const
Definition docnode.h:733
DocVhdlFlow(DocParser *parser, DocNodeVariant *parent)
Definition docnode.cpp:1212
void parse()
Definition docnode.cpp:1216
QCString m_chars
Definition docnode.h:341
QCString chars() const
Definition docnode.h:339
DocWhiteSpace(DocParser *parser, DocNodeVariant *parent, const QCString &chars)
Definition docnode.h:337
Node representing a word.
Definition docnode.h:152
DocWord(DocParser *parser, DocNodeVariant *parent, const QCString &word)
Definition docnode.cpp:179
QCString m_word
Definition docnode.h:158
QCString word() const
Definition docnode.h:155
QCString m_anchor
Definition docnode.h:615
DocXRefItem(DocParser *parser, DocNodeVariant *parent, int id, const QCString &key)
Definition docnode.cpp:472
QCString anchor() const
Definition docnode.h:605
QCString key() const
Definition docnode.h:608
QCString relPath() const
Definition docnode.h:607
QCString m_file
Definition docnode.h:614
QCString file() const
Definition docnode.h:604
QCString m_key
Definition docnode.h:613
QCString m_title
Definition docnode.h:616
bool parse()
Definition docnode.cpp:477
QCString m_relPath
Definition docnode.h:617
QCString title() const
Definition docnode.h:606
std::vector like container optimized for pushing elements to the back.
Definition growvector.h:40
size_t size() const
returns the number of elements
Definition growvector.h:93
DocNodeVariant & back()
Definition growvector.h:135
bool empty() const
checks whether the container is empty
Definition growvector.h:140
void emplace_back(Args &&...args)
Definition growvector.h:108
opaque representation of the abstract syntax tree (AST)
Definition docparser.h:49
A model of a class/file/namespace member symbol.
Definition memberdef.h:48
static constexpr int Anchor
Definition section.h:40
#define ONLY_DEFAULT_MOVABLE(cls)
Macro to help implementing the rule of 5 for a class that can be moved but not copied.
Definition construct.h:44
void dumpDocNodeSizes()
Definition docnode.h:1407
std::variant< DocWord, DocLinkedWord, DocURL, DocLineBreak, DocHorRuler, DocAnchor, DocCite, DocStyleChange, DocSymbol, DocEmoji, DocWhiteSpace, DocSeparator, DocVerbatim, DocInclude, DocIncOperator, DocFormula, DocIndexEntry, DocAutoList, DocAutoListItem, DocTitle, DocXRefItem, DocImage, DocDotFile, DocMscFile, DocDiaFile, DocVhdlFlow, DocLink, DocRef, DocInternalRef, DocHRef, DocHtmlHeader, DocHtmlDescTitle, DocHtmlDescList, DocSection, DocSecRefItem, DocSecRefList, DocInternal, DocParBlock, DocSimpleList, DocHtmlList, DocSimpleSect, DocSimpleSectSep, DocParamSect, DocPara, DocParamList, DocSimpleListItem, DocHtmlListItem, DocHtmlDescData, DocHtmlCell, DocHtmlCaption, DocHtmlRow, DocHtmlTable, DocHtmlBlockQuote, DocText, DocRoot, DocHtmlDetails, DocHtmlSummary, DocPlantUmlFile > DocNodeVariant
Definition docnode.h:66
constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
returns true iff v holds one of types passed as template parameters
Definition docnode.h:1346
DocNodeList * call_method_children(DocNodeVariant *v)
Definition docnode.h:1365
#define DOC_NODES
Definition docnode.h:42
constexpr DocNodeVariant * parent(DocNodeVariant *n)
returns the parent node of a given node n or nullptr if the node has no parent.
Definition docnode.h:1310
std::unique_ptr< DocNodeVariant > createDocNode(Args &&...args)
Definition docnode.h:1471
void dumpDocNodeList(const DocNodeList &children)
Definition docnode.h:1431
constexpr const char * docNodeName(const DocWord &)
Definition docnode.h:75
const char * qPrint(const char *s)
Definition qcstring.h:661
#define TRUE
Definition qcstring.h:37
#define FALSE
Definition qcstring.h:34
Private(const QCString &name_, const QCString &context_, const QCString &srcFile_, int srcLine_)
Definition docnode.h:677
QCString name
Definition docnode.h:647
QCString relPath
Definition docnode.h:651
HtmlAttribList attribs
Definition docnode.h:646
Private(const HtmlAttribList &attribs_, const QCString &name_, Type type_, const QCString &relPath_, const QCString &url_, bool inlineImage_)
Definition docnode.h:642
QCString height
Definition docnode.h:650
QCString width
Definition docnode.h:649
void move_append(DocNodeList &l)
moves the element of list l at the end of this list.
Definition docnode.cpp:800
void append(Args &&... args)
Append a new DocNodeVariant to the list by constructing it with type T and parameters Args.
Definition docnode.h:1379
T * get_last()
Returns a pointer to the last element in the list if that element exists and holds a T,...
Definition docnode.h:1390
QCString exampleFile
Definition docnode.h:398
DocNodeList children
Definition docnode.h:406
Private(const QCString &context_, const QCString &text_, Type type_, bool isExample_, const QCString &exampleFile_, const QCString &relPath_, const QCString &lang_, bool isBlock_)
Definition docnode.h:390
static constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
Definition docnode.h:1327
static constexpr bool holds_one_of_alternatives(const DocNodeVariant &v)
Definition docnode.h:1336
std::string_view word
Definition util.cpp:980