section.h
Go to the documentation of this file.
1 /******************************************************************************
2  *
3  *
4  *
5  *
6  * Copyright (C) 1997-2015 by Dimitri van Heesch.
7  *
8  * Permission to use, copy, modify, and distribute this software and its
9  * documentation under the terms of the GNU General Public License is hereby
10  * granted. No representations are made about the suitability of this software
11  * for any purpose. It is provided "as is" without express or implied warranty.
12  * See the GNU General Public License for more details.
13  *
14  * Documents produced by Doxygen are derivative works derived from the
15  * input used in their production; they are not affected by this license.
16  *
17  */
18 
19 #ifndef SECTION_H
20 #define SECTION_H
21 
22 #include "sortdict.h"
23 
24 class Definition;
25 
26 /** Class representing a section in a page */
28 {
29  enum SectionType { Page = 0,
30  Section = 1,
31  Subsection = 2,
33  Paragraph = 4,
34  Anchor = 5,
35  Table = 6
36  };
37  SectionInfo(const char *f,const int lin,const char *l,const char *t,
38  SectionType st,int lev,const char *r=0) :
39  label(l), title(t), type(st), ref(r), definition(0),
40  fileName(f), lineNr(lin), generated(FALSE), level(lev)
41  {
42  }
44  {
45  label=s.label.copy();
46  title=s.title.copy();
47  type =s.type;
48  ref=s.ref.copy();
51  lineNr=s.lineNr;
53  level=s.level;
54  }
62  int lineNr;
63  bool generated;
64  int level;
65 };
66 
67 /** Unsorted dictionary of SectionInfo objects. */
68 class SectionDict : public SDict<SectionInfo>
69 {
70  public:
71  SectionDict(int size) : SDict<SectionInfo>(size) {}
73 };
74 
75 #endif
SectionDict(int size)
Definition: section.h:71
SectionInfo(const char *f, const int lin, const char *l, const char *t, SectionType st, int lev, const char *r=0)
Definition: section.h:37
SectionType type
Definition: section.h:58
bool generated
Definition: section.h:63
SectionInfo(const SectionInfo &s)
Definition: section.h:43
QCString ref
Definition: section.h:59
const bool FALSE
Definition: qglobal.h:370
QCString label
Definition: section.h:56
static QStrList * l
Definition: config.cpp:1044
QCString copy() const
Definition: qcstring.h:250
decltype(auto) constexpr size(T &&obj)
ADL-aware version of std::size.
Definition: StdUtils.h:92
Definition: sortdict.h:73
QCString fileName
Definition: section.h:61
int level
Definition: section.h:64
int lineNr
Definition: section.h:62
QCString title
Definition: section.h:57
~SectionInfo()
Definition: section.h:55
~SectionDict()
Definition: section.h:72
Definition * definition
Definition: section.h:60
static QCString * s
Definition: config.cpp:1042