浏览该文件的文档.
58 bool isPublished=
false);
168 return new NamespaceDefImpl(defFileName,defLine,defColumn,name,ref,refFile,type,isPublished);
260 ,m_isPublished(isPublished)
284 else if (type==
"constants")
288 else if (type==
"library")
318 mg->distributeMemberGroupDocumentation();
328 mg->findSectionsInDocumentation(
this);
334 ml->findSectionsInDocumentation(
this);
342 auto it = std::find(
files.begin(),
files.end(),fd);
416 mg->addToDeclarationSection();
462 if (allMemberList==0)
505 err(
"NamespaceDefImpl::insertMembers(): "
506 "member '%s' with class scope '%s' inserted in namespace scope '%s'!\n",
517 std::unique_ptr<MemberDef> aliasMd;
547 if (allMemberList) allMemberList->
setAnchors();
559 tagFile <<
" <compound kind=\"namespace\">\n";
565 tagFile <<
" <clangid>" <<
convertToXML(idStr) <<
"</clangid>\n";
575 if (nd->isLinkableInProject())
577 tagFile <<
" <namespace>" <<
convertToXML(nd->name()) <<
"</namespace>\n";
621 mg->writeTagFile(tagFile);
630 tagFile <<
" </compound>\n";
686 if (rootNode && !rootNode->isEmpty())
781 bool const isConstantGroup)
792 && mg->header()!=
"[NOHEADER]")
794 mg->writeDeclarations(ol,0,
this,0,0);
902 for (
const auto &cd : list)
904 if (cd->isLinkableInProject())
906 tagFile <<
" <class kind=\"" << cd->compoundTypeString()
916 if (cd->isLinkableInProject())
918 tagFile <<
" <concept>" <<
convertToXML(cd->name()) <<
"</concept>\n";
932 if (!generateTreeView)
1078 err(
"Internal inconsistency: member %d should not be part of "
1079 "LayoutDocManager::Namespace entry list\n",lde->kind());
1093 if (allMemberList) allMemberList->
sort();
1107 ml->writeDocumentationPage(ol,
displayName(),
this);
1123 for (
const auto &md : *allMemberList)
1125 if (md->getNamespaceDef()==
this && md->isLinkable() && !md->isEnumValue())
1127 if (md->isLinkableInProject())
1158 ml->countDecMembers();
1159 ml->countDocMembers();
1163 mg->countDecMembers();
1164 mg->countDocMembers();
1225 mg->addListReferences(
this);
1231 ml->addListReferences(
this);
1247 result=result.
mid(i+2);
1254 if (visitedNamespaces.find(
this)!=visitedNamespaces.end())
return;
1255 visitedNamespaces.insert(
this);
1258 for (
auto &nd : usingDirList)
1267 for (
auto &nd : usingDirList)
1270 for (
const auto &und : nd->getUsedNamespaces())
1275 for (
const auto &ucd : nd->getUsedClasses())
1287 for (
const auto &nd : *
this)
1289 if (nd->isLinkable() && nd->hasDocumentation())
1294 if (isConstantGroup == nd->isConstantGroup())
1300 else if (!isConstantGroup)
1302 if (nd->isConstantGroup())
1304 err(
"Internal inconsistency: constant group but not IDL?\n");
1315 bool const isConstantGroup,
bool localName)
1319 if (
empty())
return;
1332 for (
const auto &nd : *
this)
1334 if (nd->isLinkable() && nd->hasDocumentation())
1337 if (lang==
SrcLangExt_IDL && (isConstantGroup != nd->isConstantGroup()))
1341 QCString ct = nd->compoundTypeString();
1348 name = nd->localName();
1352 name = nd->displayName();
1356 if (!nd->briefDescription().isEmpty() &&
Config_getBool(BRIEF_MEMBER_DESC))
1376 ml->setNeedsSorting(
1395 if (ml->needsSorting()) { ml->sort(); ml->setNeedsSorting(
FALSE); }
1423 if (ml->listType()==lt)
1447 if (i==-1) i=0;
else i+=2;
1448 static bool extractAnonNs =
Config_getBool(EXTRACT_ANON_NSPACES);
1449 if (extractAnonNs &&
1450 name().mid(i,20)==
"anonymous_namespace{"
1613 StringUnorderedMap::iterator it2;
1622 warn_uncond(
"possible recursive namespace alias detected for %s!\n",
qPrint(name));
1638 if (cnd->isLinkableInProject() && !cnd->isAnonymous())
1658 if (cnd->isLinkableInProject())
1695 for (
const auto &cd : list)
1697 if (cd->isLinkableInProject() && cd->templateMaster()==0)
virtual QCString anchor() const
NamespaceDefMutable * createNamespaceDef(const QCString &defFileName, int defLine, int defColumn, const QCString &name, const QCString &ref, const QCString &refFile, const QCString &type, bool isPublished)
Factory method to create new NamespaceDef instance
Definition * toDefinition(DefinitionMutable *dm)
virtual QCString briefFile() const
void writeInlineClasses(OutputList &ol)
bool add(const char *k, T *obj)
Adds an object reference to the ordered vector if it was not added already.
virtual bool isInline() const
virtual ClassLinkedRefMap getClasses() const
void disableAllBut(OutputGenerator::OutputType o)
virtual LinkedRefMap< const ClassDef > getUsedClasses() const
virtual bool isReference() const
void startMemberDescription(const QCString &anchor, const QCString &inheritId=QCString(), bool typ=false)
void startTitle(OutputList &ol, const QCString &fileName, const DefinitionMutable *def)
virtual QCString trNamespaceReference(const QCString &namespaceName)=0
virtual CodeSymbolType codeSymbolType() const
virtual bool isLinkableInProject() const
NamespaceLinkedRefMap namespaces
void endGroupHeader(int extraLevels=0)
bool namespaceHasNestedConcept(const NamespaceDef *nd)
void writeAuthorSection(OutputList &ol)
virtual QCString getOutputFileBase() const =0
Represents of a member declaration list with configurable title and subtitle.
@ NamespaceNestedNamespaces
virtual QCString compoundTypeString() const
virtual void distributeMemberGroupDocumentation()
MemberLists m_memberLists
@ MemberListType_docDictionaryMembers
void writeDeclaration(OutputList &ol, const QCString &header, bool localNames) const
virtual LinkedRefMap< const NamespaceDef > getUsedNamespaces() const =0
void endTitle(OutputList &ol, const QCString &fileName, const QCString &name)
MemberDefMutable * toMemberDefMutable(Definition *d)
void endMemberDeclaration(const QCString &anchor, const QCString &inheritId)
virtual void addInnerCompound(const Definition *d)
virtual bool isConstantGroup() const =0
ConceptLinkedRefMap m_concepts
virtual void addListReferences()
void writeMemberDocumentation(OutputList &ol, MemberListType lt, const QCString &title)
virtual ~NamespaceDefImpl()
static StringUnorderedMap namespaceAliasMap
The common base class of all entity definitions found in the sources.
virtual void writeTagFile(TextStream &)
@ MemberListType_docEnumMembers
virtual const RefItemVector & xrefListItems() const
virtual bool subGrouping() const
QCString stripScope(const QCString &name)
virtual QCString localName() const =0
An abstract interface of a namespace symbol.
NamespaceDefAliasImpl(const Definition *newScope, const NamespaceDef *nd)
void writeDeclaration(OutputList &ol, const ClassDef::CompoundType *filter, const QCString &header, bool localNames) const
void docify(const QCString &s)
virtual void writeDocAnchorsToTagFile(TextStream &fs) const
void endMemberDeclarations(OutputList &ol)
void endMemberDocumentation(OutputList &ol)
virtual ClassLinkedRefMap getExceptions() const =0
void endMemberDescription()
ClassLinkedRefMap interfaces
const std::unique_ptr< MemberList > & get(MemberListType lt, MemberListContainer con)
int findRev(char c, int index=-1, bool cs=TRUE) const
virtual bool isModule() const
virtual QCString docFile() const
virtual void addUsingDirective(const NamespaceDef *nd)
bool isEmpty() const
Returns TRUE iff the string is empty
@ MemberListType_allMembersList
virtual const MemberLists & getMemberLists() const =0
virtual QCString trPackage(const QCString &name)=0
void writeClassDeclarations(OutputList &ol, const QCString &title, const ClassLinkedRefMap &d)
void writeLabel(const QCString &l, bool isLast)
virtual QCString title() const
CompoundType
The various compound types
void writeClassesToTagFile(TextStream &, const ClassLinkedRefMap &d)
void startMemberSections()
bool namespaceHasNestedClass(const NamespaceDef *nd, bool filterClasses, ClassDef::CompoundType ct)
void writeString(const QCString &text)
virtual QCString displayName(bool b=TRUE) const
virtual void countMembers()
QCString title(SrcLangExt lang) const
void insertMemberAlign(bool templ=FALSE)
virtual QCString title() const =0
virtual int getDefLine() const
LinkedRefMap< const NamespaceDef > m_usingDirList
virtual QCString localName() const
virtual ClassLinkedRefMap getInterfaces() const =0
void push_back(const MemberDef *md)
virtual QCString id() const
virtual NamespaceLinkedRefMap getNamespaces() const
virtual ConceptLinkedRefMap getConcepts() const
SrcLangExt
Language as given by extension
T * add(const char *k, Args &&... args)
Adds a new object to the ordered vector if it was not added already.
@ MemberListType_docSequenceMembers
void writeDocumentation(OutputList &ol, const Definition *container=0) const
virtual QCString compoundTypeString() const
static NamespaceDefMutable * globalScope
void writeNamespaceDeclarations(OutputList &ol, const QCString &title, bool isConstantGroup=false)
ClassLinkedRefMap structs
virtual Definition * getOuterScope() const
virtual bool isLinkableInProject() const
bool namespaceHasNestedNamespace(const NamespaceDef *nd)
ConceptDef * toConceptDef(Definition *d)
virtual QCString getOutputFileBase() const
virtual const MemberLists & getMemberLists() const
virtual bool isInline() const =0
virtual bool isHidden() const =0
virtual const MemberDef * getMemberByName(const QCString &name) const
virtual void insertNamespace(const NamespaceDef *nd)
@ MemberListType_docDefineMembers
virtual QCString anchor() const =0
virtual SrcLangExt getLanguage() const
virtual void setSectionList(const Definition *container, const MemberList *sl)=0
@ MemberListType_decDictionaryMembers
MemberGroupList m_memberGroups
void err(const char *fmt,...)
char & at(size_t i)
Returns a reference to the character at index i.
virtual QCString name() const
Text streaming class that buffers data.
virtual QCString name() const
virtual void writeDocumentation(OutputList &ol)
void writeMemberDeclarations(OutputList &ol, MemberListType lt, const QCString &title)
virtual QCString getDefFileName() const
virtual const MemberDef * getMemberByName(const QCString &) const =0
virtual const MemberGroupList & getMemberGroups() const =0
NamespaceDef * getResolvedNamespace(const QCString &name)
virtual int briefLine() const
void writeBriefDescription(OutputList &ol)
virtual ClassLinkedRefMap getStructs() const
virtual void writeMemberPages(OutputList &ol)
NamespaceDefImpl(const QCString &defFileName, int defLine, int defColumn, const QCString &name, const QCString &ref=QCString(), const QCString &refFile=QCString(), const QCString &type=QCString(), bool isPublished=false)
void endFileWithNavPath(const Definition *d, OutputList &ol)
virtual bool hasBriefDescription() const
void writeDoc(DocRoot *root, const Definition *ctx, const MemberDef *md, int id=0)
virtual QCString displayName(bool=TRUE) const
void addMemberToList(MemberListType lt, MemberDef *md)
virtual bool isLibrary() const
virtual SrcLangExt getLanguage() const =0
Returns the programming language this definition was written in.
@ NamespaceNestedConstantGroups
void writeSummaryLink(const QCString &file, const QCString &anchor, const QCString &title, bool first)
virtual LinkedRefMap< const ClassDef > getUsedClasses() const
void endTextBlock(bool paraBreak=FALSE)
DirIterator end(const DirIterator &) noexcept
virtual bool isModule() const
@ MemberListType_declarationLists
virtual bool isHidden() const
@ MemberListType_decSequenceMembers
virtual const MemberDef * getMemberByName(const QCString &) const
@ ClassCollaborationGraph
virtual QCString qualifiedName() const
QCString title(SrcLangExt lang) const
NamespaceDefMutable * toNamespaceDefMutable(Definition *d)
virtual void combineUsingRelations(NamespaceDefSet &visitedNamespace)=0
virtual void insertConcept(const ConceptDef *cd)
virtual bool isLinkableInProject() const =0
MemberDef * createMemberDefAlias(const Definition *newScope, const MemberDef *aliasMd)
static QCString listTypeAsString(MemberListType type)
virtual void computeAnchors()
Class representing a list of output generators that are written to in parallel.
virtual QCString qualifiedName() const =0
virtual LinkedRefMap< const ClassDef > getUsedClasses() const =0
virtual bool subGrouping() const =0
Represents of a member definition list with configurable title.
QCString addHtmlExtensionIfMissing(const QCString &fName)
A model of a class/file/namespace member symbol.
void writeTagFile(TextStream &)
void warn_uncond(const char *fmt,...)
virtual LinkedRefMap< const NamespaceDef > getUsedNamespaces() const
virtual QCString briefDescription(bool abbreviate=FALSE) const
virtual bool hasDetailedDescription() const =0
virtual bool isConstantGroup() const
A abstract class representing of a compound symbol.
@ MemberListType_decVarMembers
static MemberNameLinkedMap * functionNameLinkedMap
void startTextBlock(bool dense=FALSE)
void startMemberItem(const QCString &anchor, int i1, const QCString &id=QCString())
void disable(OutputGenerator::OutputType o)
void startMemberHeader(const QCString &anchor, int typ=2)
virtual void setFileName(const QCString &fn)
virtual bool isModule() const =0
virtual void combineUsingRelations(NamespaceDefSet &visitedNamespace)
MemberListType listType() const
virtual bool hasDetailedDescription() const
void writeAnchor(const QCString &fileName, const QCString &name)
virtual QCString trMore()=0
void writeConcepts(OutputList &ol, const QCString &title)
virtual MemberList * getMemberList(MemberListType lt) const
int numDocMembers() const
virtual ClassLinkedRefMap getClasses() const =0
virtual int numDocMembers() const
int qstricmp(const char *str1, const char *str2)
void lineBreak(const QCString &style=QCString())
Translator * theTranslator
virtual QCString name() const =0
virtual const ClassDef * getClassDef() const =0
virtual void findSectionsInDocumentation()
virtual int numDocMembers() const
virtual DefType definitionType() const
virtual QCString anchor() const
virtual ConceptLinkedRefMap getConcepts() const
virtual QCString trGeneratedAutomatically(const QCString &s)=0
virtual const Definition * findInnerCompound(const QCString &name) const =0
DocRoot * validatingParseDoc(IDocParser &parserIntf, const QCString &fileName, int startLine, const Definition *ctx, const MemberDef *md, const QCString &input, bool indexWords, bool isExample, const QCString &exampleName, bool singleLine, bool linkFromIndex, bool markdownSupport)
virtual void setOuterScope(Definition *d)=0
@ MemberListType_docFuncMembers
QCString getLanguageSpecificSeparator(SrcLangExt lang, bool classScope)
Returns the scope separator to use given the programming language lang
void startFile(OutputList &ol, const QCString &name, const QCString &manName, const QCString &title, HighlightedItem hli, bool additionalIndices, const QCString &altSidebarName)
virtual NamespaceLinkedRefMap getNamespaces() const
virtual MemberList * getMemberList(MemberListType lt) const =0
virtual const MemberGroupList & getMemberGroups() const
NamespaceDef * createNamespaceDefAlias(const Definition *newScope, const NamespaceDef *nd)
Factory method to create an alias of an existing namespace.
virtual QCString getOutputFileBase() const
virtual bool isLibrary() const
void writeDeclarations(OutputList &ol, const ClassDef *cd, const NamespaceDef *nd, const FileDef *fd, const GroupDef *gd, const QCString &title, const QCString &subtitle, bool showEnumValues=FALSE, bool showInline=FALSE, const ClassDef *inheritedFrom=0, MemberListType lt=MemberListType_pubMethods) const
Writes the list of members to the output.
const T * find(const std::string &key) const
Find an object given the key.
ClassDef * toClassDef(Definition *d)
virtual bool subGrouping() const
virtual void setInline(bool isInline)
virtual NamespaceLinkedRefMap getNamespaces() const =0
@ MemberListType_decEnumMembers
virtual ClassLinkedRefMap getInterfaces() const
virtual void insertUsedFile(FileDef *fd)
void addRefItem(const RefItemVector &sli, const QCString &key, const QCString &prefix, const QCString &name, const QCString &title, const QCString &args, const Definition *scope)
virtual int docLine() const
void writeDetailedDescription(OutputList &ol, const QCString &title)
MemberLinkedRefMap m_allMembers
virtual DefType definitionType() const =0
void startGroupHeader(int extraLevels=0)
virtual void setNamespace(const NamespaceDef *nd)=0
virtual QCString trConstantGroupReference(const QCString &namespaceName)=0
LinkedRefMap< const Definition > m_innerCompounds
@ MemberListType_decDefineMembers
void startTextLink(const QCString &file, const QCString &anchor)
virtual CompoundType compoundType() const =0
Returns the type of compound this is, i.e.
virtual void writeQuickMemberLinks(OutputList &ol, const MemberDef *currentMd) const
virtual CodeSymbolType codeSymbolType() const =0
virtual void insertMember(MemberDef *md)
void docFindSections(const QCString &input, const Definition *d, const QCString &fileName)
virtual MemberList * getMemberList(MemberListType lt) const
@ MemberListType_decFuncMembers
virtual QCString documentation() const
virtual QCString trNamespace(bool first_capital, bool singular)=0
virtual ClassLinkedRefMap getStructs() const
LinkedRefMap< const ClassDef > m_usingDeclList
QCString mid(size_t index, size_t len=static_cast< size_t >(-1)) const
QCString substitute(const QCString &s, const QCString &src, const QCString &dst)
substitute all occurrences of src in s by dst
virtual const MemberLists & getMemberLists() const
virtual DefType definitionType() const
std::vector< RefItem * > RefItemVector
virtual ConceptLinkedRefMap getConcepts() const =0
virtual ~NamespaceDefAliasImpl()
virtual bool isLinkable() const =0
ClassLinkedRefMap classes
#define Config_getBool(name)
void startMemberDocumentation(OutputList &ol)
virtual CodeSymbolType codeSymbolType() const
NamespaceDef * toNamespaceDef(Definition *d)
void writeDocumentation(OutputList &ol, const QCString &scopeName, const Definition *container, const QCString &title, bool showEnumValues=FALSE, bool showInline=FALSE) const
@ MemberListType_documentationLists
virtual void addUsingDeclaration(const ClassDef *cd)
@ MemberListType_docVarMembers
static LayoutDocManager & instance()
Returns a reference to this singleton.
virtual void addMembersToMemberGroup()
virtual bool hasDocumentation() const
virtual const Definition * findInnerCompound(const QCString &name) const
@ MemberListType_decTypedefMembers
void parseText(const QCString &textStr)
void addNamespaceAttributes(OutputList &ol)
virtual bool isLinkable() const
void writeSummaryLinks(OutputList &ol) const
bool declVisible(bool isContantGroup) const
const char * qPrint(const char *s)
virtual QCString trModule(bool first_capital, bool singular)=0
#define Config_getString(name)
void generateDoc(const QCString &fileName, int startLine, const Definition *ctx, const MemberDef *md, const QCString &docStr, bool indexWords, bool isExample, const QCString &exampleName, bool singleLine, bool linkFromIndex, bool markdownSupport)
void addGroupListToTitle(OutputList &ol, const Definition *d)
virtual QCString compoundTypeString() const =0
virtual int numDocMembers() const =0
QCString convertNameToFile(const QCString &name, bool allowDots, bool allowUnderscore)
void err_full(const QCString &file, int line, const char *fmt,...)
bool declVisible(const ClassDef::CompoundType *filter=0) const
static NamespaceLinkedMap * namespaceLinkedMap
virtual ClassLinkedRefMap getClasses() const
void pushGeneratorState()
virtual QCString trModuleReference(const QCString &namespaceName)=0
QCString convertToXML(const QCString &s, bool keepEntities)
A model of a file symbol.
virtual void insertClass(const ClassDef *cd)
virtual void setReference(const QCString &r)
FileDef * toFileDef(Definition *d)
virtual ClassLinkedRefMap getInterfaces() const
virtual bool isArtificial() const
virtual LinkedRefMap< const NamespaceDef > getUsedNamespaces() const
void writeMemberGroups(OutputList &ol)
QCString stripExtension(const QCString &fName)
virtual void writeNavigationPath(OutputList &ol) const
void writeConceptsToTagFile(TextStream &)
static bool suppressDocWarnings
void writeObjectLink(const QCString &ref, const QCString &file, const QCString &anchor, const QCString &name)
void startMemberDeclaration()
virtual ClassLinkedRefMap getStructs() const =0
const T * find(const std::string &key) const
find an object given the key.
virtual QCString title() const
virtual const Definition * findInnerCompound(const QCString &name) const
virtual bool isConstantGroup() const
virtual void setFileDef(const FileDef *fd)=0
A bunch of utility functions.
const NamespaceDef * getNSAlias() const
void createSubDirs(const Dir &d)
virtual bool isLinkable() const
virtual ClassLinkedRefMap getExceptions() const
virtual QCString localName() const =0
virtual QCString localName() const
void enable(OutputGenerator::OutputType o)
void writeDeclaration(OutputList &ol, const QCString &title, bool isConstantGroup=false, bool localName=FALSE)
std::set< const NamespaceDef * > NamespaceDefSet
virtual void sortMemberLists()
A list of MemberDef objects as shown in documentation sections.
virtual ClassLinkedRefMap getExceptions() const
void startMemberDeclarations(OutputList &ol)
const Definition * getAlias() const
virtual QCString className() const =0
Returns the name of the class including outer classes, but not including namespaces.
@ MemberListType_docTypedefMembers
virtual MemberType memberType() const =0
virtual bool isLibrary() const =0
virtual bool isInline() const
QCString convertToHtml(const QCString &s, bool keepEntities)
enum NamespaceDefImpl::@2 m_type
virtual void setMetaData(const QCString &m)
void startParagraph(const QCString &classDef=QCString())
virtual void insertMember(MemberDef *md)=0
QCString title(SrcLangExt lang) const
std::unique_ptr< IDocParser > createDocParser()
virtual void insertMember(MemberDef *md)=0
ClassLinkedRefMap exceptions
virtual const MemberGroupList & getMemberGroups() const
virtual QCString trAuthor(bool first_capital, bool singular)=0
static QCString makeDisplayName(const NamespaceDef *nd, bool includeScope)
virtual bool hasDetailedDescription() const
This is an alternative implementation of QCString.