summaryrefslogtreecommitdiffstats
path: root/src/classdef.h
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2015-02-21 16:12:30 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2015-02-21 16:17:14 (GMT)
commit080a465b1321ff93c05ce398cd18a577e0ebae4b (patch)
tree0bae20bf26007d2856f0460143125a31cff131b5 /src/classdef.h
parent5bfda3d4c1158e5429349a2698339650dcfbbe88 (diff)
downloadDoxygen-080a465b1321ff93c05ce398cd18a577e0ebae4b.zip
Doxygen-080a465b1321ff93c05ce398cd18a577e0ebae4b.tar.gz
Doxygen-080a465b1321ff93c05ce398cd18a577e0ebae4b.tar.bz2
Added type constraint relations for Java generics to dot graphs and XML output
Diffstat (limited to 'src/classdef.h')
-rw-r--r--src/classdef.h64
1 files changed, 62 insertions, 2 deletions
diff --git a/src/classdef.h b/src/classdef.h
index 0729d20..d98e5de 100644
--- a/src/classdef.h
+++ b/src/classdef.h
@@ -24,6 +24,7 @@
#include "definition.h"
+struct Argument;
class MemberDef;
class MemberList;
class MemberDict;
@@ -38,6 +39,7 @@ class MemberDef;
class ExampleSDict;
class MemberNameInfoSDict;
class UsesClassDict;
+class ConstraintClassDict;
class MemberGroupSDict;
class QTextStream;
class PackageDef;
@@ -229,6 +231,8 @@ class ClassDef : public Definition
UsesClassDict *usedInterfaceClasses() const;
+ ConstraintClassDict *templateTypeConstraints() const;
+
bool isTemplateArgument() const;
/** Returns the definition of a nested compound if
@@ -371,6 +375,7 @@ class ClassDef : public Definition
void findSectionsInDocumentation();
void addMembersToMemberGroup();
void addListReferences();
+ void addTypeConstraints();
void computeAnchors();
void mergeMembers();
void sortMemberLists();
@@ -441,12 +446,13 @@ class ClassDef : public Definition
void getTitleForMemberListType(MemberListType type,
QCString &title,QCString &subtitle);
QCString includeStatement() const;
+ void addTypeConstraint(const QCString &typeConstraint,const QCString &type);
-
ClassDefImpl *m_impl;
-
};
+//------------------------------------------------------------------------
+
/** Class that contains information about a usage relation.
*/
struct UsesClassDef
@@ -500,6 +506,8 @@ class UsesClassDictIterator : public QDictIterator<UsesClassDef>
~UsesClassDictIterator() {}
};
+//------------------------------------------------------------------------
+
/** Class that contains information about an inheritance relation.
*/
struct BaseClassDef
@@ -558,4 +566,56 @@ class BaseClassListIterator : public QListIterator<BaseClassDef>
QListIterator<BaseClassDef>(bcl) {}
};
+//------------------------------------------------------------------------
+
+
+/** Class that contains information about a type constraint relations.
+ */
+struct ConstraintClassDef
+{
+ ConstraintClassDef(ClassDef *cd) : classDef(cd)
+ {
+ accessors = new QDict<void>(17);
+ }
+ ~ConstraintClassDef()
+ {
+ delete accessors;
+ }
+ void addAccessor(const char *s)
+ {
+ if (accessors->find(s)==0)
+ {
+ accessors->insert(s,(void *)666);
+ }
+ }
+ /** Class definition that this relation uses. */
+ ClassDef *classDef;
+
+ /** Dictionary of member types names that form the edge labels of the
+ * constraint relation.
+ */
+ QDict<void> *accessors;
+};
+
+/** Dictionary of constraint relations.
+ */
+class ConstraintClassDict : public QDict<ConstraintClassDef>
+{
+ public:
+ ConstraintClassDict(int size) : QDict<ConstraintClassDef>(size) {}
+ ~ConstraintClassDict() {}
+};
+
+/** Iterator class to iterate over a dictionary of constraint relations.
+ */
+class ConstraintClassDictIterator : public QDictIterator<ConstraintClassDef>
+{
+ public:
+ ConstraintClassDictIterator(const QDict<ConstraintClassDef> &d)
+ : QDictIterator<ConstraintClassDef>(d) {}
+ ~ConstraintClassDictIterator() {}
+};
+
+//------------------------------------------------------------------------
+
#endif