My Project
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
define.h
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  *
4  *
5  * Copyright (C) 1997-2015 by Dimitri van Heesch.
6  *
7  * Permission to use, copy, modify, and distribute this software and its
8  * documentation under the terms of the GNU General Public License is hereby
9  * granted. No representations are made about the suitability of this software
10  * for any purpose. It is provided "as is" without express or implied warranty.
11  * See the GNU General Public License for more details.
12  *
13  * Documents produced by Doxygen are derivative works derived from the
14  * input used in their production; they are not affected by this license.
15  *
16  */
17 
18 #ifndef DEFINE_H
19 #define DEFINE_H
20 
21 #include <qdict.h>
22 #include <qlist.h>
23 
24 class FileDef;
25 
27 class Define
28 {
29  public:
30  Define();
31  Define(const Define &d);
32  ~Define();
33  bool hasDocumentation();
34  QCString name;
35  QCString definition;
36  QCString fileName;
37  QCString doc;
38  QCString brief;
39  QCString args;
40  QCString anchor;
42  int lineNr;
43  int columnNr;
44  int nargs;
45  bool undef;
46  bool varArgs;
49 };
50 
52 class DefineList : public QList<Define>
53 {
54  public:
55  DefineList() : QList<Define>() {}
57  private:
58  int compareValues(const Define *d1,const Define *d2) const
59  {
60  return qstricmp(d1->name,d2->name);
61  }
62 };
63 
65 class DefineName : public QList<Define>
66 {
67  public:
68  DefineName(const char *n) : QList<Define>() { name=n; }
70  const char *nameString() const { return name; }
71 
72  private:
73  int compareValues(const Define *d1,const Define *d2) const
74  {
75  return qstricmp(d1->name,d2->name);
76  }
77  QCString name;
78 };
79 
81 class DefineNameList : public QList<DefineName>
82 {
83  public:
84  DefineNameList() : QList<DefineName>() {}
86  private:
87  int compareValues(const DefineName *n1,const DefineName *n2) const
88  {
89  return qstricmp(n1->nameString(),n2->nameString());
90  }
91 };
92 
94 typedef QDict<Define> DefineDict;
95 
97 typedef QDict<DefineName> DefineNameDict;
98 
99 #endif