Doxygen
Loading...
Searching...
No Matches
DotClassGraph Class Referencefinal

Representation of a class inheritance or dependency graph. More...

#include <src/dotclassgraph.h>

Inheritance diagram for DotClassGraph:
Collaboration diagram for DotClassGraph:

Public Member Functions

 DotClassGraph (const ClassDef *cd, GraphType t)
 ~DotClassGraph () override
bool isTrivial () const
bool isTooBig () const
int numNodes () const
DString writeGraph (TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool TBRank=true, bool imageMap=true, int graphId=-1)
void writeXML (TextStream &t)
void writeDocbook (TextStream &t)
void writeDEF (TextStream &t)
Public Member Functions inherited from DotGraph
 DotGraph ()
virtual ~DotGraph ()=default

Protected Member Functions

DString getBaseName () const override
DString getMapLabel () const override
void computeTheGraph () override
DString getImgAltText () const override
Protected Member Functions inherited from DotGraph
int getNextNodeNumber ()
 returns the node number.
int getNextEdgeNumber ()
 returns the edge number.
DString writeGraph (TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1)
virtual DString absMapName () const
DString absBaseName () const
DString absDotName () const
DString imgName () const
DString absImgName () const
DString relImgName () const

Private Member Functions

void buildGraph (const ClassDef *cd, DotNode *n, bool base, int distance)
bool determineVisibleNodes (DotNode *rootNode, int maxNodes, bool includeParents)
void determineTruncatedNodes (DotNodeDeque &queue, bool includeParents)
void addClass (const ClassDef *cd, DotNode *n, EdgeInfo::Colors color, const DString &label, const DString &usedName, const DString &templSpec, bool base, int distance)

Private Attributes

DotNodem_startNode
DotNodeMap m_usedNodes
GraphType m_graphType
DString m_collabFileName
DString m_inheritFileName
bool m_lrRank

Additional Inherited Members

Static Protected Member Functions inherited from DotGraph
static void writeGraphHeader (TextStream &t, const DString &title=DString())
static void writeGraphFooter (TextStream &t)
static void computeGraph (DotNode *root, GraphType gt, GraphOutputFormat format, const DString &rank, bool renderParents, bool backArrows, const DString &title, DString &graphStr)
Protected Attributes inherited from DotGraph
GraphOutputFormat m_graphFormat = GraphOutputFormat::BITMAP
EmbeddedOutputFormat m_textFormat = EmbeddedOutputFormat::Html
Dir m_dir
DString m_fileName
DString m_relPath
bool m_generateImageMap = false
int m_graphId = 0
DString m_absPath
DString m_baseName
DString m_theGraph
bool m_regenerate = false
bool m_doNotAddImageToIndex = false
bool m_noDivTag = false
bool m_zoomable = true
bool m_urlOnly = false

Detailed Description

Representation of a class inheritance or dependency graph.

Definition at line 29 of file dotclassgraph.h.

Constructor & Destructor Documentation

◆ DotClassGraph()

DotClassGraph::DotClassGraph ( const ClassDef * cd,
GraphType t )

Definition at line 317 of file dotclassgraph.cpp.

318{
319 //printf("--------------- DotClassGraph::DotClassGraph '%s'\n",qPrint(cd->displayName()));
320 m_graphType = t;
321 DString tmp_url="";
322 if (cd->isLinkable() && !cd->isHidden())
323 {
324 tmp_url=cd->getReference()+"$"+cd->getOutputFileBase();
325 if (!cd->anchor().empty())
326 {
327 tmp_url+="#"+cd->anchor();
328 }
329 }
330 DString className = cd->displayName();
331 DString tooltip = cd->briefDescriptionAsTooltip();
332 m_startNode = new DotNode(this,
333 className,
334 tooltip,
335 tmp_url,
336 true, // is a root node
337 cd
338 );
340 m_usedNodes.emplace(className.str(),m_startNode);
341
342 buildGraph(cd,m_startNode,true,1);
344
346 DotNodeDeque openNodeQueue;
347 openNodeQueue.push_back(m_startNode);
349
352}
virtual DString inheritanceGraphFileName() const =0
returns the file name to use for the inheritance graph
virtual DString collaborationGraphFileName() const =0
returns the file name to use for the collaboration graph
bool empty() const
Returns true iff the string is empty (std::string compatible alias for isEmpty()).
Definition dstring.h:152
const std::string & str() const
Definition dstring.h:649
virtual bool isLinkable() const =0
virtual DString briefDescriptionAsTooltip() const =0
virtual DString displayName(bool includeScope=true) const =0
virtual bool isHidden() const =0
virtual DString anchor() const =0
virtual DString getReference() const =0
virtual DString getOutputFileBase() const =0
DotNodeMap m_usedNodes
DotNode * m_startNode
GraphType m_graphType
bool determineVisibleNodes(DotNode *rootNode, int maxNodes, bool includeParents)
void determineTruncatedNodes(DotNodeDeque &queue, bool includeParents)
DString m_inheritFileName
void buildGraph(const ClassDef *cd, DotNode *n, bool base, int distance)
DString m_collabFileName
void setDistance(int distance)
Definition dotnode.cpp:390
DotNode(DotGraph *graph, const DString &lab, const DString &tip, const DString &url, bool rootNode=false, const ClassDef *cd=nullptr)
Definition dotnode.cpp:326
#define Config_getInt(name)
Definition config.h:34
@ Inheritance
Definition dotgraph.h:31

References Definition::anchor(), Definition::briefDescriptionAsTooltip(), buildGraph(), ClassDef::collaborationGraphFileName(), Config_getInt, determineTruncatedNodes(), determineVisibleNodes(), Definition::displayName(), DotNode::DotNode(), DString::empty(), Definition::getOutputFileBase(), Definition::getReference(), Inheritance, ClassDef::inheritanceGraphFileName(), Definition::isHidden(), Definition::isLinkable(), m_collabFileName, m_graphType, m_inheritFileName, m_lrRank, m_startNode, m_usedNodes, DotNode::setDistance(), and DString::str().

◆ ~DotClassGraph()

DotClassGraph::~DotClassGraph ( )
override

Definition at line 378 of file dotclassgraph.cpp.

379{
381}
static void deleteNodes(DotNode *node)
Definition dotnode.cpp:404

References DotNode::deleteNodes(), and m_startNode.

Member Function Documentation

◆ addClass()

void DotClassGraph::addClass ( const ClassDef * cd,
DotNode * n,
EdgeInfo::Colors color,
const DString & label,
const DString & usedName,
const DString & templSpec,
bool base,
int distance )
private

Definition at line 27 of file dotclassgraph.cpp.

29{
30 if (Config_getBool(HIDE_UNDOC_CLASSES) && !cd->isLinkable()) return;
31
32 EdgeInfo::Styles edgeStyle = (!label.empty() || color==EdgeInfo::Orange || color==EdgeInfo::Orange2) ? EdgeInfo::Dashed : EdgeInfo::Solid;
33 DString className;
34 DString fullName;
35 if (cd->isAnonymous())
36 {
37 className="anonymous:";
38 className+=label;
39 fullName = className;
40 }
41 else if (!usedName.empty()) // name is a typedef
42 {
43 className=usedName;
44 fullName = className;
45 }
46 else if (!templSpec.empty()) // name has a template part
47 {
48 className=insertTemplateSpecifierInScope(cd->displayName(),templSpec);
49 fullName =insertTemplateSpecifierInScope(cd->name(),templSpec);
50 }
51 else // just a normal name
52 {
53 className=cd->displayName();
54 fullName = cd->name();
55 }
56 //printf("DotClassGraph::addClass(class='%s',parent=%s,prot=%d,label=%s,dist=%d,usedName=%s,templSpec=%s,base=%d)\n",
57 // qPrint(className),qPrint(n->label()),prot,label,distance,usedName,templSpec,base);
58 auto it = m_usedNodes.find(fullName.str());
59 if (it!=m_usedNodes.end()) // class already inserted
60 {
61 DotNode *bn = it->second;
62 if (base)
63 {
64 n->addChild(bn,color,edgeStyle,label);
65 bn->addParent(n);
66 }
67 else
68 {
69 bn->addChild(n,color,edgeStyle,label);
70 n->addParent(bn);
71 }
72 bn->setDistance(distance);
73 //printf(" add exiting node %s of %s\n",qPrint(bn->label()),qPrint(n->label()));
74 }
75 else // new class
76 {
77 DString displayName=className;
78 if (Config_getBool(HIDE_SCOPE_NAMES)) displayName=stripScope(displayName);
79 DString tmp_url;
80 if (cd->isLinkable() && !cd->isHidden())
81 {
82 tmp_url=cd->getReference()+"$"+cd->getOutputFileBase();
83 if (!cd->anchor().empty())
84 {
85 tmp_url+="#"+cd->anchor();
86 }
87 }
88 DString tooltip = cd->briefDescriptionAsTooltip();
89 DotNode *bn = new DotNode(this,
90 displayName,
91 tooltip,
92 tmp_url,
93 false, // rootNode
94 cd
95 );
96 if (base)
97 {
98 n->addChild(bn,color,edgeStyle,label);
99 bn->addParent(n);
100 }
101 else
102 {
103 bn->addChild(n,color,edgeStyle,label);
104 n->addParent(bn);
105 }
106 bn->setDistance(distance);
107 m_usedNodes.emplace(fullName.str(),bn);
108 //printf(" add new child node '%s' to %s hidden=%d url=%s\n",
109 // qPrint(className),qPrint(n->label()),cd->isHidden(),qPrint(tmp_url));
110
111 buildGraph(cd,bn,base,distance+1);
112 }
113}
virtual const DString & name() const =0
virtual bool isAnonymous() const =0
friend class DotNode
Definition dotgraph.h:36
void addParent(DotNode *n)
Definition dotnode.cpp:355
void addChild(DotNode *n, EdgeInfo::Colors edgeColor=EdgeInfo::Purple, EdgeInfo::Styles edgeStyle=EdgeInfo::Solid, const DString &edgeLab=DString(), const DString &edgeURL=DString(), int edgeLabColor=-1)
Definition dotnode.cpp:338
@ Solid
Definition dotnode.h:35
@ Dashed
Definition dotnode.h:35
@ Orange2
Definition dotnode.h:34
@ Orange
Definition dotnode.h:34
#define Config_getBool(name)
Definition config.h:33
DString insertTemplateSpecifierInScope(const DString &scope, const DString &templ)
Definition util.cpp:3078
DString stripScope(const DString &name)
Definition util.cpp:3111

References DotNode::addChild(), DotNode::addParent(), Definition::anchor(), Definition::briefDescriptionAsTooltip(), buildGraph(), Config_getBool, EdgeInfo::Dashed, Definition::displayName(), DotGraph::DotNode, DotNode::DotNode(), DString::empty(), Definition::getOutputFileBase(), Definition::getReference(), insertTemplateSpecifierInScope(), Definition::isAnonymous(), Definition::isHidden(), Definition::isLinkable(), m_usedNodes, Definition::name(), EdgeInfo::Orange, EdgeInfo::Orange2, DotNode::setDistance(), EdgeInfo::Solid, DString::str(), and stripScope().

Referenced by buildGraph().

◆ buildGraph()

void DotClassGraph::buildGraph ( const ClassDef * cd,
DotNode * n,
bool base,
int distance )
private

Definition at line 253 of file dotclassgraph.cpp.

254{
255 //printf("DocClassGraph::buildGraph(%s,distance=%d,base=%d)\n",
256 // qPrint(cd->name()),distance,base);
257 // ---- Add inheritance relations
258
260 {
261 for (const auto &bcd : base ? cd->baseClasses() : cd->subClasses())
262 {
263 //printf("-------- inheritance relation %s->%s templ='%s'\n",
264 // qPrint(cd->name()),qPrint(bcd->classDef->name()),qPrint(bcd->templSpecifiers));
265 addClass(bcd.classDef,n,EdgeInfo::protectionToColor(bcd.prot),DString(),bcd.usedName,bcd.templSpecifiers,base,distance);
266 }
267 }
269 {
270 // ---- Add usage relations
271
272 const UsesClassList &list = base ? cd->usedImplementationClasses() :
274 for (const auto &ucd : list)
275 {
276 //printf("addClass: %s templSpec=%s\n",qPrint(ucd.classDef->name()),qPrint(ucd.templSpecifiers));
277 addClass(ucd.classDef,n,EdgeInfo::Purple,joinLabels(ucd.accessors),DString(),
278 ucd.templSpecifiers,base,distance);
279 }
280 }
281 if (Config_getBool(TEMPLATE_RELATIONS) && base)
282 {
283 for (const auto &ccd : cd->templateTypeConstraints())
284 {
285 //printf("addClass: %s\n",qPrint(ccd.classDef->name()));
286 addClass(ccd.classDef,n,EdgeInfo::Orange2,joinLabels(ccd.accessors),DString(),
287 DString(),true,distance);
288 }
289 }
290
291 // ---- Add template instantiation relations
292
293 if (Config_getBool(TEMPLATE_RELATIONS))
294 {
295 if (base) // template relations for base classes
296 {
297 const ClassDef *templMaster=cd->templateMaster();
298 if (templMaster)
299 {
300 for (const auto &ti : templMaster->getTemplateInstances())
301 if (ti.classDef==cd)
302 {
303 addClass(templMaster,n,EdgeInfo::Orange,ti.templSpec,DString(),DString(),true,distance);
304 }
305 }
306 }
307 else // template relations for super classes
308 {
309 for (const auto &ti : cd->getTemplateInstances())
310 {
311 addClass(ti.classDef,n,EdgeInfo::Orange,ti.templSpec,DString(),DString(),false,distance);
312 }
313 }
314 }
315}
virtual const BaseClassList & baseClasses() const =0
Returns the list of base classes from which this class directly inherits.
virtual const TemplateInstanceList & getTemplateInstances() const =0
Returns a sorted dictionary with all template instances found for this template class.
virtual const UsesClassList & usedImplementationClasses() const =0
virtual const ConstraintClassList & templateTypeConstraints() const =0
virtual const UsesClassList & usedByImplementationClasses() const =0
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.
DString()=default
void addClass(const ClassDef *cd, DotNode *n, EdgeInfo::Colors color, const DString &label, const DString &usedName, const DString &templSpec, bool base, int distance)
static constexpr Colors protectionToColor(Protection prot)
Definition dotnode.h:43
@ Purple
Definition dotnode.h:34
static DString joinLabels(const StringSet &ss)
@ Collaboration
Definition dotgraph.h:31

References addClass(), ClassDef::baseClasses(), Collaboration, Config_getBool, DotGraph::DotNode, DString::DString(), ClassDef::getTemplateInstances(), Inheritance, joinLabels(), m_graphType, EdgeInfo::Orange, EdgeInfo::Orange2, EdgeInfo::protectionToColor(), EdgeInfo::Purple, ClassDef::subClasses(), ClassDef::templateMaster(), ClassDef::templateTypeConstraints(), ClassDef::usedByImplementationClasses(), and ClassDef::usedImplementationClasses().

Referenced by addClass(), and DotClassGraph().

◆ computeTheGraph()

void DotClassGraph::computeTheGraph ( )
overrideprotectedvirtual

Implements DotGraph.

Definition at line 400 of file dotclassgraph.cpp.

401{
406 m_lrRank ? "LR" : "",
408 true,
411 );
412}
static void computeGraph(DotNode *root, GraphType gt, GraphOutputFormat format, const DString &rank, bool renderParents, bool backArrows, const DString &title, DString &graphStr)
Definition dotgraph.cpp:299
DString m_theGraph
Definition dotgraph.h:95
GraphOutputFormat m_graphFormat
Definition dotgraph.h:85
DString label() const
Definition dotnode.h:102

References DotGraph::computeGraph(), Inheritance, DotNode::label(), DotGraph::m_graphFormat, m_graphType, m_lrRank, m_startNode, and DotGraph::m_theGraph.

◆ determineTruncatedNodes()

void DotClassGraph::determineTruncatedNodes ( DotNodeDeque & queue,
bool includeParents )
private

Definition at line 115 of file dotclassgraph.cpp.

116{
117 while (!queue.empty())
118 {
119 DotNode *n = queue.front();
120 queue.pop_front();
121 if (n->isVisible() && n->isTruncated()==DotNode::Unknown)
122 {
123 bool truncated = false;
124 for (const auto &dn : n->children())
125 {
126 if (!dn->isVisible())
127 truncated = true;
128 else
129 queue.push_back(dn);
130 }
131 if (includeParents)
132 {
133 for (const auto &dn : n->parents())
134 {
135 if (!dn->isVisible())
136 truncated = true;
137 else
138 queue.push_back(dn);
139 }
140 }
141 n->markAsTruncated(truncated);
142 }
143 }
144}
bool isVisible() const
Definition dotnode.h:104
@ Unknown
Definition dotnode.h:76
DotNode & markAsTruncated(bool b=true)
Definition dotnode.h:121
const DotNodeRefVector & parents() const
Definition dotnode.h:123
const DotNodeRefVector & children() const
Definition dotnode.h:122
TruncState isTruncated() const
Definition dotnode.h:105

References DotNode::children(), DotGraph::DotNode, DotNode::isTruncated(), DotNode::isVisible(), DotNode::markAsTruncated(), DotNode::parents(), and DotNode::Unknown.

Referenced by DotClassGraph().

◆ determineVisibleNodes()

bool DotClassGraph::determineVisibleNodes ( DotNode * rootNode,
int maxNodes,
bool includeParents )
private

Definition at line 146 of file dotclassgraph.cpp.

148{
149 DotNodeDeque childQueue;
150 DotNodeDeque parentQueue;
151 std::vector<size_t> childTreeWidth;
152 std::vector<size_t> parentTreeWidth;
153 childQueue.push_back(rootNode);
154 if (includeParents) parentQueue.push_back(rootNode);
155 bool firstNode=true; // flag to force reprocessing rootNode in the parent loop
156 // despite being marked visible in the child loop
157 while ((!childQueue.empty() || !parentQueue.empty()) && maxNodes>0)
158 {
159 if (!childQueue.empty())
160 {
161 DotNode *n = childQueue.front();
162 childQueue.pop_front();
163 size_t distance = n->distance();
164 if (!n->isVisible() && distance<=static_cast<size_t>(Config_getInt(MAX_DOT_GRAPH_DEPTH))) // not yet processed
165 {
166 if (distance>0)
167 {
168 size_t oldSize=childTreeWidth.size();
169 if (distance>oldSize)
170 {
171 childTreeWidth.resize(std::max(childTreeWidth.size(),distance));
172 for (size_t i=oldSize;i<distance;i++) childTreeWidth[i]=0;
173 }
174 childTreeWidth[distance-1]+=n->label().length();
175 }
176 n->markAsVisible();
177 maxNodes--;
178 // add direct children
179 for (const auto &dn : n->children())
180 {
181 childQueue.push_back(dn);
182 }
183 }
184 }
185 if (includeParents && !parentQueue.empty())
186 {
187 DotNode *n = parentQueue.front();
188 parentQueue.pop_front();
189 if ((!n->isVisible() || firstNode) && n->distance()<=Config_getInt(MAX_DOT_GRAPH_DEPTH)) // not yet processed
190 {
191 firstNode=false;
192 size_t distance = n->distance();
193 if (distance>0)
194 {
195 size_t oldSize = parentTreeWidth.size();
196 if (distance>oldSize)
197 {
198 parentTreeWidth.resize(std::max(parentTreeWidth.size(),distance));
199 for (size_t i=oldSize;i<distance;i++) parentTreeWidth[i]=0;
200 }
201 parentTreeWidth[distance-1]+=n->label().length();
202 }
203 n->markAsVisible();
204 maxNodes--;
205 // add direct parents
206 for (const auto &dn : n->parents())
207 {
208 parentQueue.push_back(dn);
209 }
210 }
211 }
212 }
213 if (Config_getBool(UML_LOOK)) return false; // UML graph are always top to bottom
214 size_t maxWidth=0;
215 size_t maxHeight=std::max(childTreeWidth.size(),parentTreeWidth.size());
216 for (size_t i=0;i<childTreeWidth.size();i++)
217 {
218 if (childTreeWidth.at(i)>maxWidth) maxWidth=childTreeWidth.at(i);
219 }
220 for (size_t i=0;i<parentTreeWidth.size();i++)
221 {
222 if (parentTreeWidth.at(i)>maxWidth) maxWidth=parentTreeWidth.at(i);
223 }
224 //printf("max tree width=%d, max tree height=%d\n",maxWidth,maxHeight);
225 return maxWidth>80 && maxHeight<12; // used metric to decide to render the tree
226 // from left to right instead of top to bottom,
227 // with the idea to render very wide trees in
228 // left to right order.
229}
size_t length() const
Returns the length of the string, not counting the 0-terminator.
Definition dstring.h:155
int distance() const
Definition dotnode.h:106
void markAsVisible(bool b=true)
Definition dotnode.h:120

References DotNode::children(), Config_getBool, Config_getInt, DotNode::distance(), DotGraph::DotNode, DotNode::isVisible(), DotNode::label(), DString::length(), DotNode::markAsVisible(), and DotNode::parents().

Referenced by DotClassGraph().

◆ getBaseName()

DString DotClassGraph::getBaseName ( ) const
overrideprotectedvirtual

Implements DotGraph.

Definition at line 383 of file dotclassgraph.cpp.

384{
385 switch (m_graphType)
386 {
388 return m_collabFileName;
389 break;
391 return m_inheritFileName;
392 break;
393 default:
394 ASSERT(0);
395 break;
396 }
397 return "";
398}
#define ASSERT(x)
Definition dstring.h:28

References ASSERT, Collaboration, Inheritance, m_collabFileName, m_graphType, and m_inheritFileName.

◆ getImgAltText()

DString DotClassGraph::getImgAltText ( ) const
overrideprotectedvirtual

Reimplemented from DotGraph.

Definition at line 433 of file dotclassgraph.cpp.

434{
435 switch (m_graphType)
436 {
438 return "Collaboration graph";
439 break;
441 return "Inheritance graph";
442 break;
443 default:
444 ASSERT(0);
445 break;
446 }
447 return "";
448}

References ASSERT, Collaboration, Inheritance, and m_graphType.

◆ getMapLabel()

DString DotClassGraph::getMapLabel ( ) const
overrideprotectedvirtual

Implements DotGraph.

Definition at line 414 of file dotclassgraph.cpp.

415{
416 DString mapName;
417 switch (m_graphType)
418 {
420 mapName="coll_map";
421 break;
423 mapName="inherit_map";
424 break;
425 default:
426 ASSERT(0);
427 break;
428 }
429
430 return escapeCharsInString(m_startNode->label(),false)+"_"+escapeCharsInString(mapName,false);
431}
DString escapeCharsInString(const DString &name, bool allowDots, bool allowUnderscore)
Definition util.cpp:2690

References ASSERT, Collaboration, escapeCharsInString(), Inheritance, DotNode::label(), m_graphType, and m_startNode.

◆ isTooBig()

bool DotClassGraph::isTooBig ( ) const

Definition at line 362 of file dotclassgraph.cpp.

363{
364 return numNodes()>=Config_getInt(DOT_GRAPH_MAX_NODES);
365}
int numNodes() const

References Config_getInt, and numNodes().

Referenced by ClassDefImpl::writeCollaborationGraph(), and ClassDefImpl::writeInheritanceGraph().

◆ isTrivial()

◆ numNodes()

int DotClassGraph::numNodes ( ) const

Definition at line 367 of file dotclassgraph.cpp.

368{
369 size_t numNodes = 0;
370 numNodes+= m_startNode->children().size();
372 {
373 numNodes+= m_startNode->parents().size();
374 }
375 return static_cast<int>(numNodes);
376}

References DotNode::children(), Inheritance, m_graphType, m_startNode, numNodes(), and DotNode::parents().

Referenced by isTooBig(), numNodes(), ClassDefImpl::writeCollaborationGraph(), and ClassDefImpl::writeInheritanceGraph().

◆ writeDEF()

void DotClassGraph::writeDEF ( TextStream & t)

Definition at line 483 of file dotclassgraph.cpp.

484{
485 for (const auto &[name,node] : m_usedNodes)
486 {
487 node->writeDEF(t);
488 }
489}

References m_usedNodes.

Referenced by generateDEFForClass().

◆ writeDocbook()

void DotClassGraph::writeDocbook ( TextStream & t)

Definition at line 475 of file dotclassgraph.cpp.

476{
477 for (const auto &[name,node] : m_usedNodes)
478 {
479 node->writeDocbook(t,true);
480 }
481}

References m_usedNodes.

◆ writeGraph()

DString DotClassGraph::writeGraph ( TextStream & t,
GraphOutputFormat gf,
EmbeddedOutputFormat ef,
const DString & path,
const DString & fileName,
const DString & relPath,
bool TBRank = true,
bool imageMap = true,
int graphId = -1 )

Definition at line 450 of file dotclassgraph.cpp.

459{
461
462 return DotGraph::writeGraph(out, graphFormat, textFormat, path, fileName, relPath, generateImageMap, graphId);
463}
bool m_doNotAddImageToIndex
Definition dotgraph.h:97
DString writeGraph(TextStream &t, GraphOutputFormat gf, EmbeddedOutputFormat ef, const DString &path, const DString &fileName, const DString &relPath, bool writeImageMap=true, int graphId=-1)
Definition dotgraph.cpp:114

References Html, DotGraph::m_doNotAddImageToIndex, and DotGraph::writeGraph().

Referenced by DocbookGenerator::endDotGraph(), HtmlGenerator::endDotGraph(), LatexGenerator::endDotGraph(), and RTFGenerator::endDotGraph().

◆ writeXML()

void DotClassGraph::writeXML ( TextStream & t)

Definition at line 467 of file dotclassgraph.cpp.

468{
469 for (const auto &[name,node] : m_usedNodes)
470 {
471 node->writeXML(t,true);
472 }
473}

References m_usedNodes.

Referenced by generateXMLForClass().

Member Data Documentation

◆ m_collabFileName

DString DotClassGraph::m_collabFileName
private

Definition at line 64 of file dotclassgraph.h.

Referenced by DotClassGraph(), and getBaseName().

◆ m_graphType

GraphType DotClassGraph::m_graphType
private

◆ m_inheritFileName

DString DotClassGraph::m_inheritFileName
private

Definition at line 65 of file dotclassgraph.h.

Referenced by DotClassGraph(), and getBaseName().

◆ m_lrRank

bool DotClassGraph::m_lrRank
private

Definition at line 66 of file dotclassgraph.h.

Referenced by computeTheGraph(), and DotClassGraph().

◆ m_startNode

DotNode* DotClassGraph::m_startNode
private

◆ m_usedNodes

DotNodeMap DotClassGraph::m_usedNodes
private

Definition at line 62 of file dotclassgraph.h.

Referenced by addClass(), DotClassGraph(), writeDEF(), writeDocbook(), and writeXML().


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