Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QDocDatabase Class Reference

This class provides exclusive access to the qdoc database, which consists of a forrest of trees and a lot of maps and other useful data structures. More...

#include <qdocdatabase.h>

+ Collaboration diagram for QDocDatabase:

Public Types

using FindFunctionPtr = void (QDocDatabase::*)(Aggregate *)
 

Public Member Functions

 ~QDocDatabase ()=default
 
TreefindTree (const QString &t)
 
const CNMapgroups ()
 Returns a const reference to the collection of all group nodes in the primary tree.
 
const CNMapmodules ()
 Returns a const reference to the collection of all module nodes in the primary tree.
 
const CNMapqmlModules ()
 Returns a const reference to the collection of all QML module nodes in the primary tree.
 
CollectionNodeaddGroup (const QString &name)
 Looks up the group named name in the primary tree.
 
CollectionNodeaddModule (const QString &name)
 Looks up the module named name in the primary tree.
 
CollectionNodeaddQmlModule (const QString &name)
 Looks up the QML module named name in the primary tree.
 
CollectionNodeaddToGroup (const QString &name, Node *node)
 Looks up the group node named name in the collection of all group nodes.
 
CollectionNodeaddToModule (const QString &name, Node *node)
 Looks up the module node named name in the collection of all module nodes.
 
CollectionNodeaddToQmlModule (const QString &name, Node *node)
 Looks up the QML module named name.
 
void addExampleNode (ExampleNode *n)
 
ExampleNodeMapexampleNodeMap ()
 
QmlTypeNodefindQmlType (const QString &name)
 Returns the QML type node identified by the qualified QML type name, or nullptr if no type was found.
 
QmlTypeNodefindQmlType (const QString &qmid, const QString &name)
 Returns the QML type node identified by the QML module id qmid and QML type name, or nullptr if no type was found.
 
QmlTypeNodefindQmlType (const ImportRec &import, const QString &name)
 Returns the QML type node identified by the QML module id constructed from the strings in the import record and the QML type name.
 
QmlTypeNodefindQmlTypeInPrimaryTree (const QString &qmid, const QString &name)
 Returns the QML node identified by the QML module id qmid and name, searching in the primary tree only.
 
NodeMultiMapgetCppClasses ()
 Returns a reference to the map of all C++ classes.
 
NodeMultiMapgetObsoleteClasses ()
 Returns a reference to the map of obsolete C++ clases.
 
NodeMultiMapgetClassesWithObsoleteMembers ()
 Returns a reference to the map of C++ classes with obsolete members.
 
NodeMultiMapgetObsoleteQmlTypes ()
 Returns a reference to the map of obsolete QML types.
 
NodeMultiMapgetQmlTypesWithObsoleteMembers ()
 Returns a reference to the map of QML types with obsolete members.
 
NodeMultiMapgetNamespaces ()
 Returns a reference to the namespace map.
 
NodeMultiMapgetQmlValueTypes ()
 Returns a reference to the map of QML basic types.
 
NodeMultiMapgetQmlTypes ()
 Returns a reference to the multimap of QML types.
 
NodeMultiMapgetExamples ()
 Returns a reference to the multimap of example nodes.
 
NodeMultiMapgetAttributions ()
 Returns a reference to the multimap of attribution nodes.
 
NodeMapMapgetFunctionIndex ()
 Returns the function index.
 
TextToNodeMapgetLegaleseTexts ()
 Returns a reference to the collection of legalese texts.
 
const NodeMultiMapgetClassMap (const QString &key)
 Find the key in the map of new class maps, and return a reference to the value, which is a NodeMap.
 
const NodeMultiMapgetQmlTypeMap (const QString &key)
 Find the key in the map of new QML type maps, and return a reference to the value, which is a NodeMap.
 
const NodeMultiMapgetSinceMap (const QString &key)
 Find the key in the map of new {since} maps, and return a reference to the value, which is a NodeMultiMap.
 
void resolveStuff ()
 Performs several housekeeping tasks prior to generating the documentation.
 
void insertTarget (const QString &name, const QString &title, TargetRec::TargetType type, Node *node, int priority)
 
AggregatefindRelatesNode (const QStringList &path)
 
const NodefindNodeForAtom (const Atom *atom, const Node *relative, QString &ref, Node::Genus genus=Node::DontCare)
 Searches for the node that matches the path in atom and the specified genus.
 
ClassNodefindClassNode (const QStringList &path)
 
NodefindNodeForInclude (const QStringList &path)
 
const FunctionNodefindFunctionNode (const QString &target, const Node *relative, Node::Genus genus)
 Finds the function node for the qualified function path in target and returns a pointer to it.
 
const NodefindTypeNode (const QString &type, const Node *relative, Node::Genus genus)
 This function is called for autolinking to a type, which could be a function return type or a parameter type.
 
const NodefindNodeForTarget (const QString &target, const Node *relative)
 Finds the node that will generate the documentation that contains the target and returns a pointer to it.
 
const PageNodefindPageNodeByTitle (const QString &title)
 
NodefindNodeByNameAndType (const QStringList &path, bool(Node::*isMatch)() const)
 
const CollectionNodegetCollectionNode (const QString &name, Node::NodeType type)
 
const CollectionNodegetModuleNode (const Node *relative)
 Returns the collection node representing the module that relative node belongs to, or nullptr if there is no such module in the primary tree.
 
FunctionNodefindFunctionNodeForTag (const QString &tag)
 
FunctionNodefindMacroNode (const QString &t)
 
QStringList groupNamesForNode (Node *node)
 
void addPropertyFunction (PropertyNode *property, const QString &funcName, PropertyNode::FunctionRole funcRole)
 
void setVersion (const QString &v)
 
QString version () const
 
void readIndexes (const QStringList &indexFiles)
 Reads and parses the qdoc index files listed in indexFiles.
 
void generateIndex (const QString &fileName, const QString &url, const QString &title, Generator *g)
 Generates a qdoc index file and write it to fileName.
 
void processForest ()
 This function calls a set of functions for each tree in the forest that has not already been analyzed.
 
NamespaceNodeprimaryTreeRoot ()
 Returns a pointer to the root node of the primary tree.
 
void newPrimaryTree (const QString &module)
 
void setPrimaryTree (const QString &t)
 
NamespaceNodenewIndexTree (const QString &module)
 
const QList< Tree * > & searchOrder ()
 
void setLocalSearch ()
 
void setSearchOrder (const QList< Tree * > &searchOrder)
 
void setSearchOrder (QStringList &t)
 
void mergeCollections (Node::NodeType type, CNMap &cnm, const Node *relative)
 Finds all the collection nodes of the specified type and merges them into the collection node map cnm.
 
void mergeCollections (CollectionNode *c)
 Finds all the collection nodes with the same name and type as c and merges their members into the members list of c.
 
void clearSearchOrder ()
 
QStringList keys ()
 
void resolveNamespaces ()
 Multiple namespace nodes for namespace X can exist in the qdoc database in different trees.
 
void resolveProxies ()
 Each instance of class Tree that represents an index file must be traversed to find all instances of class ProxyNode.
 
void resolveBaseClasses ()
 
void updateNavigation ()
 Updates navigation (previous/next page links and the navigation parent) for pages listed in the TOC, specified by the navigation.toctitles configuration variable.
 
TreeprimaryTree ()
 

Static Public Member Functions

static QDocDatabaseqdocDB ()
 Creates the singleton.
 
static void destroyQdocDB ()
 Destroys the singleton.
 
static NodeMultiMapobsoleteClasses ()
 
static NodeMultiMapobsoleteQmlTypes ()
 
static NodeMultiMapclassesWithObsoleteMembers ()
 
static NodeMultiMapqmlTypesWithObsoleteMembers ()
 
static NodeMultiMapcppClasses ()
 
static NodeMultiMapqmlBasicTypes ()
 
static NodeMultiMapqmlTypes ()
 
static NodeMultiMapexamples ()
 
static NodeMultiMapMapnewClassMaps ()
 
static NodeMultiMapMapnewQmlTypeMaps ()
 
static NodeMultiMapMapnewEnumValueMaps ()
 
static NodeMultiMapMapnewSinceMaps ()
 

Friends

class Tree
 

Detailed Description

This class provides exclusive access to the qdoc database, which consists of a forrest of trees and a lot of maps and other useful data structures.

Definition at line 165 of file qdocdatabase.h.

Member Typedef Documentation

◆ FindFunctionPtr

using QDocDatabase::FindFunctionPtr = void (QDocDatabase::*)(Aggregate *)

Definition at line 172 of file qdocdatabase.h.

Constructor & Destructor Documentation

◆ ~QDocDatabase()

QDocDatabase::~QDocDatabase ( )
default

Member Function Documentation

◆ addExampleNode()

void QDocDatabase::addExampleNode ( ExampleNode * n)
inline

Definition at line 197 of file qdocdatabase.h.

References primaryTree().

Referenced by CppCodeParser::processMetaCommand().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ addGroup()

CollectionNode * QDocDatabase::addGroup ( const QString & name)
inline

Looks up the group named name in the primary tree.

If a match is found, a pointer to the node is returned. Otherwise, a new group node named name is created and inserted into the collection, and the pointer to that node is returned.

Definition at line 180 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addModule()

CollectionNode * QDocDatabase::addModule ( const QString & name)
inline

Looks up the module named name in the primary tree.

If a match is found, a pointer to the node is returned. Otherwise, a new module node named name is created and inserted into the collection, and the pointer to that node is returned.

Definition at line 181 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addPropertyFunction()

void QDocDatabase::addPropertyFunction ( PropertyNode * property,
const QString & funcName,
PropertyNode::FunctionRole funcRole )
inline

Definition at line 320 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addQmlModule()

CollectionNode * QDocDatabase::addQmlModule ( const QString & name)
inline

Looks up the QML module named name in the primary tree.

If a match is found, a pointer to the node is returned. Otherwise, a new QML module node named name is created and inserted into the collection, and the pointer to that node is returned.

Definition at line 182 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addToGroup()

CollectionNode * QDocDatabase::addToGroup ( const QString & name,
Node * node )
inline

Looks up the group node named name in the collection of all group nodes.

If a match is not found, a new group node named name is created and inserted into the collection. Then append node to the group's members list, and append the group node to the member list of the node. The parent of the node is not changed by this function. Returns a pointer to the group node.

Definition at line 184 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addToModule()

CollectionNode * QDocDatabase::addToModule ( const QString & name,
Node * node )
inline

Looks up the module node named name in the collection of all module nodes.

If a match is not found, a new module node named name is created and inserted into the collection. Then append node to the module's members list. The parent of node is not changed by this function. Returns the module node.

Definition at line 188 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ addToQmlModule()

CollectionNode * QDocDatabase::addToQmlModule ( const QString & name,
Node * node )
inline

Looks up the QML module named name.

If it isn't there, create it. Then append node to the QML module's member list. The parent of node is not changed by this function.

Definition at line 192 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ classesWithObsoleteMembers()

static NodeMultiMap & QDocDatabase::classesWithObsoleteMembers ( )
inlinestatic

Definition at line 210 of file qdocdatabase.h.

◆ clearSearchOrder()

void QDocDatabase::clearSearchOrder ( )
inline

Definition at line 345 of file qdocdatabase.h.

Referenced by processQdocconfFile().

+ Here is the caller graph for this function:

◆ cppClasses()

static NodeMultiMap & QDocDatabase::cppClasses ( )
inlinestatic

Definition at line 212 of file qdocdatabase.h.

◆ destroyQdocDB()

void QDocDatabase::destroyQdocDB ( )
static

Destroys the singleton.

Definition at line 379 of file qdocdatabase.cpp.

Referenced by main().

+ Here is the caller graph for this function:

◆ exampleNodeMap()

ExampleNodeMap & QDocDatabase::exampleNodeMap ( )
inline

Definition at line 198 of file qdocdatabase.h.

References primaryTree().

Referenced by ManifestWriter::generateExampleManifestFile(), and ManifestWriter::generateManifestFiles().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ examples()

static NodeMultiMap & QDocDatabase::examples ( )
inlinestatic

Definition at line 215 of file qdocdatabase.h.

◆ findClassNode()

ClassNode * QDocDatabase::findClassNode ( const QStringList & path)
inline

Definition at line 278 of file qdocdatabase.h.

◆ findFunctionNode()

const FunctionNode * QDocDatabase::findFunctionNode ( const QString & target,
const Node * relative,
Node::Genus genus )

Finds the function node for the qualified function path in target and returns a pointer to it.

The target is a function signature with or without parameters but without the return type.

relative is the node in the primary tree where the search begins. It is not used in the other trees, if the node is not found in the primary tree. genus can be used to force the search to find a C++ function or a QML function.

The entire forest is searched, but the first match is accepted.

Definition at line 1086 of file qdocdatabase.cpp.

◆ findFunctionNodeForTag()

FunctionNode * QDocDatabase::findFunctionNodeForTag ( const QString & tag)
inline

Definition at line 298 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ findMacroNode()

FunctionNode * QDocDatabase::findMacroNode ( const QString & t)
inline

Definition at line 302 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ findNodeByNameAndType()

Node * QDocDatabase::findNodeByNameAndType ( const QStringList & path,
bool(Node::* isMatch )() const )
inline

Definition at line 288 of file qdocdatabase.h.

◆ findNodeForAtom()

const Node * QDocDatabase::findNodeForAtom ( const Atom * a,
const Node * relative,
QString & ref,
Node::Genus genus = Node::DontCare )

Searches for the node that matches the path in atom and the specified genus.

The relative node is used if the first leg of the path is empty, i.e. if the path begins with '#'. The function also sets ref if there remains an unused leg in the path after the node is found. The node is returned as well as the ref. If the returned node pointer is null, ref is also not valid.

Definition at line 1420 of file qdocdatabase.cpp.

References Atom::domain(), Atom::genus(), Atom::isLinkAtom(), Node< _Tp >::isPageNode(), Node< _Tp >::root(), SearchBaseClasses, SearchEnumValues, and Node< _Tp >::tree().

+ Here is the call graph for this function:

◆ findNodeForInclude()

Node * QDocDatabase::findNodeForInclude ( const QStringList & path)
inline

Definition at line 279 of file qdocdatabase.h.

◆ findNodeForTarget()

const Node * QDocDatabase::findNodeForTarget ( const QString & target,
const Node * relative )

Finds the node that will generate the documentation that contains the target and returns a pointer to it.

Can this be improved by using the target map in Tree?

Definition at line 1130 of file qdocdatabase.cpp.

References SearchBaseClasses, and SearchEnumValues.

◆ findPageNodeByTitle()

const PageNode * QDocDatabase::findPageNodeByTitle ( const QString & title)
inline

Definition at line 284 of file qdocdatabase.h.

◆ findQmlType() [1/3]

QmlTypeNode * QDocDatabase::findQmlType ( const ImportRec & record,
const QString & name )

Returns the QML type node identified by the QML module id constructed from the strings in the import record and the QML type name.

Returns nullptr if no type was not found.

Definition at line 653 of file qdocdatabase.cpp.

References ImportRec::isEmpty().

+ Here is the call graph for this function:

◆ findQmlType() [2/3]

QmlTypeNode * QDocDatabase::findQmlType ( const QString & name)
inline

Returns the QML type node identified by the qualified QML type name, or nullptr if no type was found.

Definition at line 200 of file qdocdatabase.h.

◆ findQmlType() [3/3]

QmlTypeNode * QDocDatabase::findQmlType ( const QString & qmid,
const QString & name )

Returns the QML type node identified by the QML module id qmid and QML type name, or nullptr if no type was found.

If the QML module id is empty, looks up the QML type by name only.

Definition at line 637 of file qdocdatabase.cpp.

◆ findQmlTypeInPrimaryTree()

QmlTypeNode * QDocDatabase::findQmlTypeInPrimaryTree ( const QString & qmid,
const QString & name )

Returns the QML node identified by the QML module id qmid and name, searching in the primary tree only.

If qmid is an empty string, searches for the node using name only.

Returns nullptr if no node was found.

Definition at line 674 of file qdocdatabase.cpp.

References primaryTreeRoot(), Node< _Tp >::QML, and TypesOnly.

+ Here is the call graph for this function:

◆ findRelatesNode()

Aggregate * QDocDatabase::findRelatesNode ( const QStringList & path)
inline

Definition at line 262 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ findTree()

Tree * QDocDatabase::findTree ( const QString & t)
inline

Definition at line 174 of file qdocdatabase.h.

◆ findTypeNode()

const Node * QDocDatabase::findTypeNode ( const QString & type,
const Node * relative,
Node::Genus genus )

This function is called for autolinking to a type, which could be a function return type or a parameter type.

The tree node that represents the type is returned. All the trees are searched until a match is found. When searching the primary tree, the search begins at relative and proceeds up the parent chain. When searching the index trees, the search begins at the root.

Definition at line 1113 of file qdocdatabase.cpp.

◆ generateIndex()

void QDocDatabase::generateIndex ( const QString & fileName,
const QString & url,
const QString & title,
Generator * g )

Generates a qdoc index file and write it to fileName.

The index file is generated with the parameters url and title, using the generator g.

Definition at line 1187 of file qdocdatabase.cpp.

References primaryTree().

+ Here is the call graph for this function:

◆ getAttributions()

NodeMultiMap & QDocDatabase::getAttributions ( )

Returns a reference to the multimap of attribution nodes.

Definition at line 783 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom(), and HtmlGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getClassesWithObsoleteMembers()

NodeMultiMap & QDocDatabase::getClassesWithObsoleteMembers ( )

Returns a reference to the map of C++ classes with obsolete members.

Definition at line 729 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getClassMap()

const NodeMultiMap & QDocDatabase::getClassMap ( const QString & key)

Find the key in the map of new class maps, and return a reference to the value, which is a NodeMap.

If key is not found, return a reference to an empty NodeMap.

Definition at line 857 of file qdocdatabase.cpp.

References emptyNodeMultiMap_.

◆ getCollectionNode()

const CollectionNode * QDocDatabase::getCollectionNode ( const QString & name,
Node::NodeType type )
inline

Definition at line 292 of file qdocdatabase.h.

◆ getCppClasses()

NodeMultiMap & QDocDatabase::getCppClasses ( )

Returns a reference to the map of all C++ classes.

Definition at line 801 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom(), and HtmlGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getExamples()

NodeMultiMap & QDocDatabase::getExamples ( )

Returns a reference to the multimap of example nodes.

Definition at line 774 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom(), and HtmlGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getFunctionIndex()

NodeMapMap & QDocDatabase::getFunctionIndex ( )

Returns the function index.

This data structure is used to output the function index page.

Definition at line 811 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getLegaleseTexts()

TextToNodeMap & QDocDatabase::getLegaleseTexts ( )

Returns a reference to the collection of legalese texts.

Definition at line 720 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getModuleNode()

const CollectionNode * QDocDatabase::getModuleNode ( const Node * relative)

Returns the collection node representing the module that relative node belongs to, or nullptr if there is no such module in the primary tree.

Definition at line 1201 of file qdocdatabase.cpp.

References Node< _Tp >::CPP, Node< _Tp >::genus(), Node< _Tp >::Module, primaryTree(), Node< _Tp >::QML, and Node< _Tp >::QmlModule.

Referenced by formatStatus().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getNamespaces()

NodeMultiMap & QDocDatabase::getNamespaces ( )

Returns a reference to the namespace map.

Constructs the namespace map if it hasn't been constructed yet.

Note
This function must not be called in the prepare phase.

Definition at line 943 of file qdocdatabase.cpp.

References resolveNamespaces().

Referenced by DocBookGenerator::generateAtom().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getObsoleteClasses()

NodeMultiMap & QDocDatabase::getObsoleteClasses ( )

Returns a reference to the map of obsolete C++ clases.

Definition at line 792 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getObsoleteQmlTypes()

NodeMultiMap & QDocDatabase::getObsoleteQmlTypes ( )

Returns a reference to the map of obsolete QML types.

Definition at line 738 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getQmlTypeMap()

const NodeMultiMap & QDocDatabase::getQmlTypeMap ( const QString & key)

Find the key in the map of new QML type maps, and return a reference to the value, which is a NodeMap.

If the key is not found, return a reference to an empty NodeMap.

Definition at line 869 of file qdocdatabase.cpp.

References emptyNodeMultiMap_.

◆ getQmlTypes()

NodeMultiMap & QDocDatabase::getQmlTypes ( )

Returns a reference to the multimap of QML types.

Definition at line 765 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getQmlTypesWithObsoleteMembers()

NodeMultiMap & QDocDatabase::getQmlTypesWithObsoleteMembers ( )

Returns a reference to the map of QML types with obsolete members.

Definition at line 747 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getQmlValueTypes()

NodeMultiMap & QDocDatabase::getQmlValueTypes ( )

Returns a reference to the map of QML basic types.

Definition at line 756 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateAtom().

+ Here is the caller graph for this function:

◆ getSinceMap()

const NodeMultiMap & QDocDatabase::getSinceMap ( const QString & key)

Find the key in the map of new {since} maps, and return a reference to the value, which is a NodeMultiMap.

If key is not found, return a reference to an empty NodeMultiMap.

Definition at line 881 of file qdocdatabase.cpp.

References emptyNodeMultiMap_.

◆ groupNamesForNode()

QStringList QDocDatabase::groupNamesForNode ( Node * node)

Definition at line 1151 of file qdocdatabase.cpp.

References Node< _Tp >::Group, and primaryTree().

+ Here is the call graph for this function:

◆ groups()

const CNMap & QDocDatabase::groups ( )
inline

Returns a const reference to the collection of all group nodes in the primary tree.

Definition at line 176 of file qdocdatabase.h.

References primaryTree().

Referenced by DocBookGenerator::generateGroupReferenceText().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ insertTarget()

void QDocDatabase::insertTarget ( const QString & name,
const QString & title,
TargetRec::TargetType type,
Node * node,
int priority )
inline

Definition at line 253 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ keys()

QStringList QDocDatabase::keys ( )
inline

Definition at line 346 of file qdocdatabase.h.

◆ mergeCollections() [1/2]

void QDocDatabase::mergeCollections ( CollectionNode * c)

Finds all the collection nodes with the same name and type as c and merges their members into the members list of c.

For QML modules, only nodes with matching module identifiers are merged to avoid merging modules with different (major) versions.

Definition at line 1289 of file qdocdatabase.cpp.

References CollectionNode::isMerged(), and CollectionNode::markMerged().

Referenced by DocBookGenerator::generateDocumentation(), Generator::generateDocumentation(), WebXMLGenerator::generateDocumentation(), DocBookGenerator::generateGroupReferenceText(), and DocBookGenerator::generateList().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ mergeCollections() [2/2]

void QDocDatabase::mergeCollections ( Node::NodeType type,
CNMap & cnm,
const Node * relative )

Finds all the collection nodes of the specified type and merges them into the collection node map cnm.

Nodes that match the relative node are not included.

Definition at line 1229 of file qdocdatabase.cpp.

Referenced by DocBookGenerator::generateList().

+ Here is the caller graph for this function:

◆ modules()

const CNMap & QDocDatabase::modules ( )
inline

Returns a const reference to the collection of all module nodes in the primary tree.

Definition at line 177 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ newClassMaps()

static NodeMultiMapMap & QDocDatabase::newClassMaps ( )
inlinestatic

Definition at line 216 of file qdocdatabase.h.

◆ newEnumValueMaps()

static NodeMultiMapMap & QDocDatabase::newEnumValueMaps ( )
inlinestatic

Definition at line 218 of file qdocdatabase.h.

◆ newIndexTree()

NamespaceNode * QDocDatabase::newIndexTree ( const QString & module)
inline

Definition at line 338 of file qdocdatabase.h.

◆ newPrimaryTree()

void QDocDatabase::newPrimaryTree ( const QString & module)
inline

Definition at line 336 of file qdocdatabase.h.

◆ newQmlTypeMaps()

static NodeMultiMapMap & QDocDatabase::newQmlTypeMaps ( )
inlinestatic

Definition at line 217 of file qdocdatabase.h.

◆ newSinceMaps()

static NodeMultiMapMap & QDocDatabase::newSinceMaps ( )
inlinestatic

Definition at line 219 of file qdocdatabase.h.

◆ obsoleteClasses()

static NodeMultiMap & QDocDatabase::obsoleteClasses ( )
inlinestatic

Definition at line 208 of file qdocdatabase.h.

◆ obsoleteQmlTypes()

static NodeMultiMap & QDocDatabase::obsoleteQmlTypes ( )
inlinestatic

Definition at line 209 of file qdocdatabase.h.

◆ primaryTree()

Tree * QDocDatabase::primaryTree ( )
inline

Definition at line 365 of file qdocdatabase.h.

Referenced by addExampleNode(), addGroup(), addModule(), addPropertyFunction(), addQmlModule(), addToGroup(), addToModule(), addToQmlModule(), exampleNodeMap(), findFunctionNodeForTag(), findMacroNode(), findRelatesNode(), generateIndex(), getModuleNode(), groupNamesForNode(), groups(), insertTarget(), modules(), qmlModules(), and resolveStuff().

+ Here is the caller graph for this function:

◆ primaryTreeRoot()

NamespaceNode * QDocDatabase::primaryTreeRoot ( )
inline

Returns a pointer to the root node of the primary tree.

Definition at line 335 of file qdocdatabase.h.

Referenced by ClangVisitor::ClangVisitor(), QmlDocVisitor::QmlDocVisitor(), findNodeForCursor(), findQmlTypeInPrimaryTree(), Generator::generateDocs(), CppCodeParser::parseMacroArg(), CppCodeParser::parseOtherFuncArg(), processQdocconfFile(), CppCodeParser::processQmlProperties(), CppCodeParser::processTopicCommand(), and resolveStuff().

+ Here is the caller graph for this function:

◆ processForest()

void QDocDatabase::processForest ( )

This function calls a set of functions for each tree in the forest that has not already been analyzed.

In this way, when running qdoc in singleExec mode, each tree is analyzed in turn, and its classes and types are added to the appropriate node maps.

Definition at line 688 of file qdocdatabase.cpp.

References resolveNamespaces().

Referenced by singleExecutionMode().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qdocDB()

QDocDatabase * QDocDatabase::qdocDB ( )
static

Creates the singleton.

Allows only one instance of the class to be created. Returns a pointer to the singleton.

Definition at line 367 of file qdocdatabase.cpp.

Referenced by CodeParser::CodeParser(), ManifestWriter::ManifestWriter(), QmlDocVisitor::QmlDocVisitor(), checkModuleInclusion(), DocBookGenerator::generateAtom(), HtmlGenerator::generateAtom(), FnMatchError::isParentInternal(), loadIndexFiles(), CppCodeParser::parseMacroArg(), CppCodeParser::parseOtherFuncArg(), CppCodeParser::processMetaCommand(), processQdocconfFile(), CppCodeParser::processQmlProperties(), CppCodeParser::processTopicCommand(), HelpProjectWriter::reset(), Aggregate::resolveRelates(), and singleExecutionMode().

+ Here is the caller graph for this function:

◆ qmlBasicTypes()

static NodeMultiMap & QDocDatabase::qmlBasicTypes ( )
inlinestatic

Definition at line 213 of file qdocdatabase.h.

◆ qmlModules()

const CNMap & QDocDatabase::qmlModules ( )
inline

Returns a const reference to the collection of all QML module nodes in the primary tree.

Definition at line 178 of file qdocdatabase.h.

References primaryTree().

+ Here is the call graph for this function:

◆ qmlTypes()

static NodeMultiMap & QDocDatabase::qmlTypes ( )
inlinestatic

Definition at line 214 of file qdocdatabase.h.

◆ qmlTypesWithObsoleteMembers()

static NodeMultiMap & QDocDatabase::qmlTypesWithObsoleteMembers ( )
inlinestatic

Definition at line 211 of file qdocdatabase.h.

◆ readIndexes()

void QDocDatabase::readIndexes ( const QStringList & indexFiles)

Reads and parses the qdoc index files listed in indexFiles.

Definition at line 1169 of file qdocdatabase.cpp.

◆ resolveBaseClasses()

void QDocDatabase::resolveBaseClasses ( )

Definition at line 928 of file qdocdatabase.cpp.

Referenced by resolveStuff().

+ Here is the caller graph for this function:

◆ resolveNamespaces()

void QDocDatabase::resolveNamespaces ( )

Multiple namespace nodes for namespace X can exist in the qdoc database in different trees.

This function first finds all namespace nodes in all the trees and inserts them into a multimap. Then it combines all the namespace nodes that have the same name into a single namespace node of that name and inserts that combined namespace node into an index.

Definition at line 957 of file qdocdatabase.cpp.

References Aggregate::findAllNamespaces(), and NodeMultiMap.

Referenced by getNamespaces(), processForest(), and resolveStuff().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ resolveProxies()

void QDocDatabase::resolveProxies ( )

Each instance of class Tree that represents an index file must be traversed to find all instances of class ProxyNode.

For each ProxyNode found, look up the ProxyNode's name in the primary Tree. If it is found, it means that the proxy node contains elements (normally just functions) that are documented in the module represented by the Tree containing the proxy node but that are related to the node we found in the primary tree.

Definition at line 1051 of file qdocdatabase.cpp.

References Tree::proxies().

Referenced by resolveStuff().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ resolveStuff()

void QDocDatabase::resolveStuff ( )

Performs several housekeeping tasks prior to generating the documentation.

These tasks create required data structures and resolve links.

Definition at line 893 of file qdocdatabase.cpp.

References Tree::markDontDocumentNodes(), Aggregate::markUndocumentedChildrenInternal(), Aggregate::normalizeOverloads(), primaryTree(), primaryTreeRoot(), resolveBaseClasses(), resolveNamespaces(), resolveProxies(), Aggregate::resolveQmlInheritance(), Aggregate::resolveRelates(), and updateNavigation().

Referenced by processQdocconfFile().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ searchOrder()

const QList< Tree * > & QDocDatabase::searchOrder ( )
inline

Definition at line 339 of file qdocdatabase.h.

◆ setLocalSearch()

void QDocDatabase::setLocalSearch ( )
inline

Definition at line 340 of file qdocdatabase.h.

Referenced by updateNavigation().

+ Here is the caller graph for this function:

◆ setPrimaryTree()

void QDocDatabase::setPrimaryTree ( const QString & t)
inline

Definition at line 337 of file qdocdatabase.h.

◆ setSearchOrder() [1/2]

void QDocDatabase::setSearchOrder ( const QList< Tree * > & searchOrder)
inline

Definition at line 341 of file qdocdatabase.h.

◆ setSearchOrder() [2/2]

void QDocDatabase::setSearchOrder ( QStringList & t)
inline

Definition at line 342 of file qdocdatabase.h.

◆ setVersion()

void QDocDatabase::setVersion ( const QString & v)
inline

Definition at line 326 of file qdocdatabase.h.

◆ updateNavigation()

void QDocDatabase::updateNavigation ( )

Updates navigation (previous/next page links and the navigation parent) for pages listed in the TOC, specified by the navigation.toctitles configuration variable.

if navigation.toctitles.inclusive is true, include also the TOC page(s) themselves as a 'root' item in the navigation bar (breadcrumbs) that are generated for HTML output.

Definition at line 1497 of file qdocdatabase.cpp.

References setLocalSearch().

Referenced by resolveStuff().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ version()

QString QDocDatabase::version ( ) const
inlinenodiscard

Definition at line 327 of file qdocdatabase.h.

Friends And Related Symbol Documentation

◆ Tree

friend class Tree
friend

Definition at line 353 of file qdocdatabase.h.


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