![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
Builds IR (Intermediate Representation) from QDoc's Node tree. More...
#include <irbuilder.h>
Public Member Functions | |
| IRBuilder ()=default | |
| DocumentIR | buildPageIR (const PageNode *pn) const |
Builds IR (Intermediate Representation) from QDoc's Node tree.
IRBuilder is the "compiler" in QDoc's compile/link/render pipeline. It transforms Node objects into format-agnostic IR structures that can be:
\list
IRBuilder handles all interaction with Node classes and Atom chains. Generators receive pre-built IR and focus purely on formatting output. This separation enables:
\list
During IR building, {local links} (within the same module) are resolved immediately. {Cross-module links} are marked as external with an empty href, to be resolved during the link phase when dependency .index files are available.
Definition at line 13 of file irbuilder.h.
|
default |
|
nodiscard |
Build IR for a PageNode.
This method extracts documentation content from the node's atom chain. The brief is stored separately via Doc::briefText(), while body content is extracted by walking the atom chain and collecting text atoms that are not within the brief section.
Definition at line 64 of file irbuilder.cpp.
References Atom::AutoLink, Atom::BriefLeft, Atom::BriefRight, Atom::C, Node< _Tp >::doc(), Text::firstAtom(), Atom::next(), Atom::String, and Atom::type().
Referenced by TemplateGenerator::generatePageNode().