34#define ENTRY_SPECIFICATIONS \
37 ESPEC(MemberDeclStart) ESPEC(MemberDeclEnd) ESPEC(MemberDecl) \
38 ESPEC(MemberDefStart) ESPEC(MemberDefEnd) ESPEC(MemberDef) \
39 ESPEC(BriefDesc) ESPEC(DetailedDesc) \
40 ESPEC(AuthorSection) \
42 ESPEC(ClassIncludes) ESPEC(ClassInlineClasses) \
43 ESPEC(ClassInheritanceGraph) ESPEC(ClassNestedClasses) \
44 ESPEC(ClassCollaborationGraph) ESPEC(ClassAllMembersLink) \
45 ESPEC(ClassUsedFiles) \
47 ESPEC(ConceptDefinition) \
49 ESPEC(NamespaceNestedNamespaces) ESPEC(NamespaceNestedConstantGroups) \
50 ESPEC(NamespaceClasses) ESPEC(NamespaceConcepts) ESPEC(NamespaceInterfaces) ESPEC(NamespaceStructs) ESPEC(NamespaceExceptions) \
51 ESPEC(NamespaceInlineClasses) \
53 ESPEC(FileClasses) ESPEC(FileConcepts) ESPEC(FileInterfaces) ESPEC(FileStructs) ESPEC(FileExceptions) ESPEC(FileConstantGroups) ESPEC(FileNamespaces) \
54 ESPEC(FileIncludes) ESPEC(FileIncludeGraph) \
55 ESPEC(FileIncludedByGraph) ESPEC(FileSourceLink) \
56 ESPEC(FileInlineClasses) \
58 ESPEC(ModuleExports) ESPEC(ModuleClasses) ESPEC(ModuleConcepts) ESPEC(ModuleUsedFiles) \
60 ESPEC(GroupClasses) ESPEC(GroupConcepts) ESPEC(GroupModules) ESPEC(GroupInlineClasses) ESPEC(GroupNamespaces) \
61 ESPEC(GroupDirs) ESPEC(GroupNestedGroups) ESPEC(GroupFiles) \
62 ESPEC(GroupGraph) ESPEC(GroupPageDocs) \
64 ESPEC(DirSubDirs) ESPEC(DirFiles) ESPEC(DirGraph)
76#define ESPEC(x) case x: return #x; break;
79 default:
return "unknown";
82 virtual std::string
id()
const = 0;
93 std::string
id()
const override {
return m_id; }
121 std::string
id()
const override {
return m_id; }
139 std::string
id()
const override {
return m_id; }
156#define NAV_SPECIFICATIONS \
162 NSPEC(ModuleMembers,) \
165 NSPEC(NamespaceList,) \
166 NSPEC(NamespaceMembers,) \
171 NSPEC(ClassHierarchy,) \
172 NSPEC(ClassMembers,) \
174 NSPEC(InterfaceList,) \
175 NSPEC(InterfaceIndex,) \
176 NSPEC(InterfaceHierarchy,) \
179 NSPEC(StructIndex,) \
181 NSPEC(ExceptionList,) \
182 NSPEC(ExceptionIndex,) \
183 NSPEC(ExceptionHierarchy,) \
186 NSPEC(FileGlobals,) \
193#define NSPEC(x,y) x y,
201#define NSPEC(x,y) case x: return #x; break;
204 default:
return "unknown";
222 void insertChild(
size_t pos,std::unique_ptr<LayoutNavEntry> &&e);
223 void appendChild(std::unique_ptr<LayoutNavEntry> &&e);
238 child->m_parent =
this;
254#define PART_SPECIFICATIONS \
255 PSPEC(Undefined, = -1) \
256 PSPEC(Class,) PSPEC(Concept,) PSPEC(Namespace,) PSPEC(File,) PSPEC(Group,) PSPEC(Directory,) PSPEC(Module,) \
265#define PSPEC(x,y) x y,
275#define PSPEC(x,y) case x: return #x; break;
278 default:
return "unknown";
291 void parse(
const DString &fileName,
const char* data =
nullptr);
A String class for use with Doxygen wrapping std::string and adding some additional functionality off...
const std::string & str() const
Singleton providing access to the (user configurable) layout of the documentation.
void mergeNavEntries(LayoutDocManager &manager)
static std::string partToString(int k)
void parse(const DString &fileName, const char *data=nullptr)
Parses a user provided layout.
std::unique_ptr< Private > d
LayoutNavEntry * createChildNavEntry(LayoutNavEntry *root, LayoutNavEntry::Kind k, bool vs, const DString &bf, const DString &tl, const DString &intro)
append a new node as a child to root.
static LayoutDocManager & instance()
Returns a reference to this singleton.
friend class LayoutParser
void mergeDocEntries(const DString &fileName, LayoutDocManager &manager)
void addEntry(LayoutPart p, LayoutDocEntryPtr &&e)
LayoutNavEntry * rootNavEntry() const
returns the (invisible) root of the navigation tree.
void removeInvisibleDocEntries()
const LayoutDocEntryList & docEntries(LayoutPart part) const
Returns the list of LayoutDocEntry's in representation order for a given page identified by part.
A model of a class/file/namespace member symbol.
Wrapper class for the MemberListType type.
#define NON_COPYABLE(cls)
Macro to help implementing the rule of 5 for a non-copyable & movable class.
#define ABSTRACT_BASE_CLASS(cls)
Macro to implement rule of 5 for an abstract base class.
constexpr DocNodeVariant * parent(DocNodeVariant *n)
returns the parent node of a given node n or nullptr if the node has no parent.
std::unique_ptr< LayoutDocEntry > LayoutDocEntryPtr
std::vector< std::unique_ptr< LayoutNavEntry > > LayoutNavEntryList
void writeDefaultLayoutFile(const DString &fileName)
std::vector< LayoutDocEntryPtr > LayoutDocEntryList
Base class representing a piece of a documentation page.
std::string entryToString() const
virtual Kind kind() const =0
virtual std::string id() const =0
virtual bool visible() const =0
DString subtitle(SrcLangExt lang) const
std::string id() const override
LayoutDocEntryMemberDecl(MemberListType tp, const std::string &id, const DString &tl, const DString &ss, bool v)
DString title(SrcLangExt lang) const
Kind kind() const override
bool visible() const override
std::string id() const override
Kind kind() const override
DString title(SrcLangExt lang) const
bool visible() const override
LayoutDocEntryMemberDef(MemberListType tp, const std::string &id, const DString &tl, bool v)
DString title(SrcLangExt lang) const
LayoutDocEntrySection(Kind k, const std::string &id, const DString &tl, bool v)
Kind kind() const override
bool visible() const override
LayoutDocEntrySimple(Kind k, const std::string &id, bool v)
std::string id() const override
Base class for the layout of a navigation item at the top of the HTML pages.
LayoutNavEntryList m_children
const LayoutNavEntryList & children() const
LayoutNavEntryList & children()
LayoutNavEntry * find(LayoutNavEntry::Kind k, const DString &file=DString()) const
void updateVisibility(LayoutNavEntry *parent)
void appendChild(std::unique_ptr< LayoutNavEntry > &&e)
void insertChild(size_t pos, std::unique_ptr< LayoutNavEntry > &&e)
LayoutNavEntry * parent() const
void swap(LayoutNavEntry &other)
LayoutNavEntry(LayoutNavEntry *parent, Kind k, bool vs, const DString &bf, const DString &tl, const DString &intro)
LayoutNavEntry * m_parent
friend class LayoutDocManager
std::string navToString() const
This file contains a number of basic enums and types.