![]() |
Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
#include <cppcodeparser.h>
Public Member Functions | |
CppCodeParser (FnCommandParser &&parser) | |
FunctionNode * | parseMacroArg (const Location &location, const QString ¯oArg) |
Parse the macro arguments in macroArg ad hoc, without using any actual parser. | |
FunctionNode * | parseOtherFuncArg (const QString &topic, const Location &location, const QString &funcArg) |
Parse QML signal/method topic commands. | |
std::pair< std::vector< TiedDocumentation >, std::vector< FnMatchError > > | processTopicArgs (const UntiedDocumentation &untied) |
void | processMetaCommand (const Doc &doc, const QString &command, const ArgPair &argLocPair, Node *node) |
Process the metacommand command in the context of the node associated with the topic command and the doc. | |
void | processMetaCommands (const Doc &doc, Node *node) |
The topic command has been processed, and now doc and node are passed to this function to get the metacommands from doc and process them one at a time. | |
void | processMetaCommands (const std::vector< TiedDocumentation > &tied) |
Static Public Member Functions | |
static bool | isQMLMethodTopic (const QString &t) |
returns true if t is {qmlsignal}, {qmlmethod}, {qmlattachedsignal}, or {qmlattachedmethod}. | |
static bool | isQMLPropertyTopic (const QString &t) |
Returns true if t is {qmlproperty}, {qmlpropertygroup}, or {qmlattachedproperty}. |
Static Public Attributes | |
static const QSet< QString > | topic_commands |
static const QSet< QString > | meta_commands |
Protected Member Functions | |
virtual Node * | processTopicCommand (const Doc &doc, const QString &command, const ArgPair &arg) |
Process the topic command found in the doc with argument arg. | |
std::vector< TiedDocumentation > | processQmlProperties (const UntiedDocumentation &untied) |
Definition at line 20 of file cppcodeparser.h.
|
explicit |
Definition at line 59 of file cppcodeparser.cpp.
References CppCodeParser().
Referenced by CppCodeParser(), and processQdocconfFile().
|
static |
returns true if t is {qmlsignal}, {qmlmethod}, {qmlattachedsignal}, or {qmlattachedmethod}.
Definition at line 858 of file cppcodeparser.cpp.
|
static |
Returns true if t is {qmlproperty}, {qmlpropertygroup}, or {qmlattachedproperty}.
Definition at line 868 of file cppcodeparser.cpp.
FunctionNode * CppCodeParser::parseMacroArg | ( | const Location & | location, |
const QString & | macroArg ) |
Parse the macro arguments in macroArg ad hoc, without using any actual parser.
If successful, return a pointer to the new FunctionNode for the macro. Otherwise return null. location is used for reporting errors.
Definition at line 743 of file cppcodeparser.cpp.
References Node< _Tp >::doc(), FunctionNode::MacroWithoutParams, FunctionNode::MacroWithParams, Node< _Tp >::parent(), QDocDatabase::primaryTreeRoot(), Public, and QDocDatabase::qdocDB().
FunctionNode * CppCodeParser::parseOtherFuncArg | ( | const QString & | topic, |
const Location & | location, | ||
const QString & | funcArg ) |
Parse QML signal/method topic commands.
Definition at line 684 of file cppcodeparser.cpp.
References Public.
void CppCodeParser::processMetaCommand | ( | const Doc & | doc, |
const QString & | command, | ||
const ArgPair & | argPair, | ||
Node * | node ) |
Process the metacommand command in the context of the node associated with the topic command and the doc.
arg is the argument to the metacommand.
node is guaranteed to be non-null.
Definition at line 325 of file cppcodeparser.cpp.
References QDocDatabase::addExampleNode(), Node< _Tp >::Deprecated, Node< _Tp >::isAggregate(), Node< _Tp >::isCollectionNode(), Node< _Tp >::isExample(), Node< _Tp >::isFunction(), Node< _Tp >::isInternal(), Node< _Tp >::isModule(), Node< _Tp >::isQmlModule(), Node< _Tp >::isQmlProperty(), Node< _Tp >::isQmlType(), Node< _Tp >::isSharedCommentNode(), Node< _Tp >::isTextPageNode(), CodeParser::isWorthWarningAbout(), Doc::location(), PageNode::markAttribution(), Node< _Tp >::markDefault(), Node< _Tp >::markInternal(), Node< _Tp >::markReadOnly(), NativeEnumInterface::nativeEnum(), Node< _Tp >::NonReentrant, FunctionNode::overridesThis(), Node< _Tp >::parent(), Node< _Tp >::Preliminary, InclusionFilter::processInternalDocs(), QDocDatabase::qdocDB(), Node< _Tp >::Reentrant, Node< _Tp >::setAbstract(), PageNode::setNoAutoList(), FunctionNode::setOverloadFlag(), SharedCommentNode::setOverloadFlags(), FunctionNode::setPrimaryOverloadFlag(), FunctionNode::setReimpFlag(), QmlPropertyNode::setRequired(), Node< _Tp >::setStatus(), Node< _Tp >::setThreadSafeness(), Node< _Tp >::setWrapper(), and Node< _Tp >::ThreadSafe.
The topic command has been processed, and now doc and node are passed to this function to get the metacommands from doc and process them one at a time.
node is the node where doc resides.
Definition at line 615 of file cppcodeparser.cpp.
References Node< _Tp >::isSharedCommentNode().
Referenced by parseSourceFiles().
void CppCodeParser::processMetaCommands | ( | const std::vector< TiedDocumentation > & | tied | ) |
Definition at line 988 of file cppcodeparser.cpp.
|
protected |
Definition at line 237 of file cppcodeparser.cpp.
References UntiedDocumentation::documentation, Doc::location(), QmlPropertyArguments::parse(), QmlPropertyArguments::RequireQualifiedPath, Doc::startLocation(), and Doc::topicsUsed().
std::pair< std::vector< TiedDocumentation >, std::vector< FnMatchError > > CppCodeParser::processTopicArgs | ( | const UntiedDocumentation & | untied | ) |
Definition at line 874 of file cppcodeparser.cpp.
|
protectedvirtual |
Process the topic command found in the doc with argument arg.
Definition at line 87 of file cppcodeparser.cpp.
References Node< _Tp >::access(), Tree::camelCaseModuleName(), Class, Config::generateExamples, Node< _Tp >::isAggregate(), Node< _Tp >::isTypeAlias(), CodeParser::isWorthWarningAbout(), Doc::location(), Node< _Tp >::location(), CollectionNode::markSeen(), NamespaceNode::markSeen(), Namespace, Node< _Tp >::parent(), QDocDatabase::primaryTreeRoot(), QDocDatabase::qdocDB(), QmlType, QmlValueType, Node< _Tp >::setAccess(), Node< _Tp >::setLocation(), Node< _Tp >::setTemplateDecl(), Doc::startLocation(), Node< _Tp >::templateDecl(), NamespaceNode::tree(), and Variable.
Definition at line 34 of file cppcodeparser.h.
Definition at line 23 of file cppcodeparser.h.