47 const char* p=s.
data();
52 if (c ==
'\'') t <<
'\\';
85 t <<
" " <<
prefix <<
"-member = {\n";
88 memPrefix.
append(
"-mem-" );
112 t << memPrefix <<
"kind = '" << memType <<
"';\n";
113 t << memPrefix <<
"id = '"
117 t << memPrefix <<
"virt = ";
126 t << memPrefix <<
"prot = ";
140 t << memPrefix <<
"type = <<_EnD_oF_dEf_TeXt_\n" << typeStr <<
"\n"
141 <<
"_EnD_oF_dEf_TeXt_;\n";
144 t << memPrefix <<
"name = '" << md->
name() <<
"';\n";
150 QCString fcnPrefix =
" " + memPrefix +
"param-";
152 auto defIt = defAl.
begin();
156 if (defIt!=defAl.
end())
161 t << memPrefix <<
"param = {\n";
162 if (!a.attrib.isEmpty())
164 t << fcnPrefix <<
"attributes = ";
168 if (!a.type.isEmpty())
170 t << fcnPrefix <<
"type = <<_EnD_oF_dEf_TeXt_\n"
171 << a.type <<
"\n_EnD_oF_dEf_TeXt_;\n";
173 if (!a.name.isEmpty())
175 t << fcnPrefix <<
"declname = ";
181 t << fcnPrefix <<
"defname = ";
185 if (!a.array.isEmpty())
187 t << fcnPrefix <<
"array = ";
191 if (!a.defval.isEmpty())
193 t << fcnPrefix <<
"defval = <<_EnD_oF_dEf_TeXt_\n"
194 << a.defval <<
"\n_EnD_oF_dEf_TeXt_;\n";
196 t <<
" }; /*" << fcnPrefix <<
"-param */\n";
202 QCString defPrefix =
" " + memPrefix +
"def-";
205 t << memPrefix <<
"param = {\n";
206 t << defPrefix <<
"name = '" << a.type <<
"';\n";
207 t <<
" }; /*" << defPrefix <<
"-param */\n";
213 t << memPrefix <<
"initializer = <<_EnD_oF_dEf_TeXt_\n"
221 t << memPrefix <<
"enum = { enum-name = " << emd->name() <<
';';
222 if (!emd->initializer().isEmpty())
224 t <<
" enum-value = ";
232 t << memPrefix <<
"desc-file = '" << md->
getDefFileName() <<
"';\n";
233 t << memPrefix <<
"desc-line = '" << md->
getDefLine() <<
"';\n";
234 t << memPrefix <<
"briefdesc = <<_EnD_oF_dEf_TeXt_\n"
236 t << memPrefix <<
"documentation = <<_EnD_oF_dEf_TeXt_\n"
241 QCString refPrefix =
" " + memPrefix +
"ref-";
243 for (
const auto &rmd : refList)
245 if (rmd->getStartBodyLine()!=-1 && rmd->getBodyDef())
247 t << memPrefix <<
"referenceto = {\n";
248 t << refPrefix <<
"id = '"
249 << rmd->getBodyDef()->getOutputFileBase()
251 << rmd->anchor() <<
"';\n";
253 t << refPrefix <<
"line = '"
254 << rmd->getStartBodyLine() <<
"';\n";
256 QCString scope = rmd->getScopeString();
263 t << refPrefix <<
"name = ";
265 t <<
';' <<
"\n };\n";
269 for (
const auto &rmd : refByList)
271 if (rmd->getStartBodyLine()!=-1 && rmd->getBodyDef())
273 t << memPrefix <<
"referencedby = {\n";
274 t << refPrefix <<
"id = '"
275 << rmd->getBodyDef()->getOutputFileBase()
277 << rmd->anchor() <<
"';\n";
279 t << refPrefix <<
"line = '"
280 << rmd->getStartBodyLine() <<
"';\n";
282 QCString scope = rmd->getScopeString();
289 t << refPrefix <<
"name = ";
291 t <<
';' <<
"\n };\n";
295 t <<
" }; /* " <<
prefix <<
"-member */\n";
304 if (cd && ml && !ml->
empty())
306 t <<
" cp-section = {\n";
307 t <<
" sec-kind = '" << kind <<
"';\n";
309 for (
const auto &md : *ml)
313 t <<
" }; /* cp-section */\n";
334 if (cd->
name().
find(
'@')!=-1)
return;
339 t <<
" cp-name = '" << cd->
name() <<
"';\n";
343 t <<
" cp-ref = {\n" <<
" ref-type = base;\n";
345 << bcd.classDef->getOutputFileBase() <<
"';\n";
366 t <<
" cp-ref = {\n" <<
" ref-type = derived;\n";
368 << bcd.classDef->getOutputFileBase() <<
"';\n";
387 size_t numMembers = 0;
390 if (!ml->listType().isDetailed())
392 numMembers+=ml->size();
425 t <<
" cp-fileline = '" << cd->
getDefLine() <<
"';\n";
426 t <<
" cp-briefdesc = <<_EnD_oF_dEf_TeXt_\n"
429 t <<
" cp-documentation = <<_EnD_oF_dEf_TeXt_\n"
435 t <<
" cp-inheritancegraph = <<_EnD_oF_dEf_TeXt_\n";
437 t <<
"\n_EnD_oF_dEf_TeXt_;\n";
442 t <<
" cp-collaborationgraph = <<_EnD_oF_dEf_TeXt_\n";
444 t <<
"\n_EnD_oF_dEf_TeXt_;\n";
454 if (ml && !ml->
empty())
456 t <<
" " << kind <<
" = {\n";
457 for (
const auto &md : *ml)
468 t <<
" namespace = {\n";
484 t <<
" ns-fileline = '" << nd->
getDefLine() <<
"';\n";
485 t <<
" ns-briefdesc = <<_EnD_oF_dEf_TeXt_\n"
488 t <<
" ns-documentation = <<_EnD_oF_dEf_TeXt_\n"
499 t <<
" file-name = ";
513 t <<
" file-first-line = '" << fd->
getDefLine() <<
"';\n";
515 t <<
" file-briefdesc = <<_EnD_oF_dEf_TeXt_\n"
518 t <<
" file-documentation = <<_EnD_oF_dEf_TeXt_\n"
521 t <<
"}; /* file */\n";
528 Dir defDir(outputDirectory.
str());
531 err(
"Could not create def directory in %s\n",
qPrint(outputDirectory));
535 QCString fileName=outputDirectory+
"/doxygen.def";
539 err(
"Cannot open file %s for writing!\n",
qPrint(fileName));
543 t <<
"AutoGen Definitions dummy;\n";
555 for (
const auto &fd : *fn)
567 t <<
"dummy_value = true;\n";
This class represents an function or template argument list.
A abstract class representing of a compound symbol.
virtual QCString compoundTypeString() const =0
Returns the type of compound as a string.
virtual const MemberLists & getMemberLists() const =0
Returns the list containing the list of members sorted per type.
virtual const BaseClassList & baseClasses() const =0
Returns the list of base classes from which this class directly inherits.
virtual MemberList * getMemberList(MemberListType lt) const =0
Returns the members in the list identified by lt.
virtual const ClassDef * templateMaster() const =0
Returns the template master of which this class is an instance.
virtual const BaseClassList & subClasses() const =0
Returns the list of sub classes that directly derive from this class.
The common base class of all entity definitions found in the sources.
virtual SrcLangExt getLanguage() const =0
Returns the programming language this definition was written in.
virtual QCString getDefFileName() const =0
virtual int getDefLine() const =0
virtual QCString anchor() const =0
virtual QCString briefDescription(bool abbreviate=FALSE) const =0
virtual QCString documentation() const =0
virtual QCString getOutputFileBase() const =0
virtual const MemberVector & getReferencedByMembers() const =0
virtual bool isReference() const =0
virtual const MemberVector & getReferencesMembers() const =0
virtual const QCString & name() const =0
Class representing a directory in the file system.
bool mkdir(const std::string &path, bool acceptsAbsPath=true) const
Representation of a class inheritance or dependency graph.
void writeDEF(TextStream &t)
static NamespaceLinkedMap * namespaceLinkedMap
static FileNameLinkedMap * inputNameLinkedMap
static ClassLinkedMap * classLinkedMap
A model of a file symbol.
virtual MemberList * getMemberList(MemberListType lt) const =0
A model of a class/file/namespace member symbol.
virtual QCString typeString() const =0
virtual const ClassDef * getClassDef() const =0
virtual const MemberVector & enumFieldList() const =0
virtual const ArgumentList & argumentList() const =0
virtual const NamespaceDef * getNamespaceDef() const =0
virtual Protection protection() const =0
virtual MemberType memberType() const =0
virtual QCString argsString() const =0
virtual Specifier virtualness(int count=0) const =0
virtual const QCString & initializer() const =0
A list of MemberDef objects as shown in documentation sections.
bool empty() const noexcept
An abstract interface of a namespace symbol.
virtual MemberList * getMemberList(MemberListType lt) const =0
This is an alternative implementation of QCString.
int find(char c, int index=0, bool cs=TRUE) const
QCString & prepend(const char *s)
bool isEmpty() const
Returns TRUE iff the string is empty.
const std::string & str() const
QCString & append(char c)
const char * data() const
Returns a pointer to the contents of the string in the form of a 0-terminated C string.
Text streaming class that buffers data.
#define Config_getString(name)
std::unique_ptr< ArgumentList > stringToArgumentList(SrcLangExt lang, const QCString &argsString, QCString *extraTypeChars=nullptr)
static void generateDEFClassSection(const ClassDef *cd, TextStream &t, const MemberList *ml, const QCString &kind)
static void generateDEFForClass(const ClassDef *cd, TextStream &t)
static void generateDEFForMember(const MemberDef *md, TextStream &t, const Definition *def, const QCString &prefix)
static void writeDEFString(TextStream &t, const QCString &s)
static void generateDEFSection(const Definition *d, TextStream &t, const MemberList *ml, const QCString &kind)
static void generateDEFForFile(const FileDef *fd, TextStream &t)
static void generateDEFForNamespace(const NamespaceDef *nd, TextStream &t)
std::ofstream openOutputStream(const QCString &name, bool append=false)
Portable versions of functions that are platform dependent.
const char * qPrint(const char *s)
This class contains the information about the argument of a function or template.
QCString replaceAnonymousScopes(const QCString &s, const QCString &replacement)
A bunch of utility functions.