summaryrefslogtreecommitdiffstats
path: root/addon/doxmlparser/src/mainhandler.h
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2002-01-22 17:56:24 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2002-01-22 17:56:24 (GMT)
commit61e51f0c7b139596e54aaea4c4d684b59cbfae57 (patch)
treed15a4da33ccd88d9f7ebd50a6090a12c90ccbae4 /addon/doxmlparser/src/mainhandler.h
parent9d4d8095cd70a06a3536eea20c32ca7bbddd9f3a (diff)
downloadDoxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.zip
Doxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.tar.gz
Doxygen-61e51f0c7b139596e54aaea4c4d684b59cbfae57.tar.bz2
Doxygen-1.2.13-20020122
Diffstat (limited to 'addon/doxmlparser/src/mainhandler.h')
-rw-r--r--addon/doxmlparser/src/mainhandler.h77
1 files changed, 45 insertions, 32 deletions
diff --git a/addon/doxmlparser/src/mainhandler.h b/addon/doxmlparser/src/mainhandler.h
index e466b6f..da7fe75 100644
--- a/addon/doxmlparser/src/mainhandler.h
+++ b/addon/doxmlparser/src/mainhandler.h
@@ -3,7 +3,7 @@
* $Id$
*
*
- * Copyright (C) 1997-2001 by Dimitri van Heesch.
+ * Copyright (C) 1997-2002 by Dimitri van Heesch.
*
* Permission to use, copy, modify, and distribute this software and its
* documentation under the terms of the GNU General Public License is hereby
@@ -22,47 +22,60 @@
#include <doxmlintf.h>
#include "memberhandler.h"
+struct CompoundEntry;
+
+struct IndexEntry
+{
+ QString id;
+ QString name;
+};
+
+struct MemberEntry : public IndexEntry
+{
+ CompoundEntry *compound;
+};
+
+struct CompoundEntry : public IndexEntry
+{
+ CompoundEntry(int size) : memberDict(size)
+ { memberDict.setAutoDelete(TRUE); }
+ QDict<MemberEntry> memberDict;
+};
+
class MainHandler : public IDoxygen, public BaseHandler<MainHandler>
{
public:
virtual void startCompound(const QXmlAttributes& attrib);
+ virtual void startMember(const QXmlAttributes& attrib);
+ virtual void endMember();
+ virtual void startName(const QXmlAttributes& attrib);
+ virtual void endName();
MainHandler();
virtual ~MainHandler();
- ICompoundIterator *compounds() const
- {
- return new CompoundIterator(m_compounds);
- }
- ICompound *compoundById(const QString &id) const
- {
- return m_compoundDict[id];
- }
- virtual ICompound *compoundByName(const QString &name) const
- {
- return name.isEmpty() ? 0 : m_compoundNameDict[name];
- }
- virtual IMember *memberById(const QString &id) const
- {
- return m_memberDict[id];
- }
- virtual IMemberIterator *memberByName(const QString &name) const
- {
- QList<IMember> *ml = m_memberNameDict[name];
- if (ml==0) return 0;
- return new MemberIterator(*ml);
- }
- virtual void release() { delete this; }
- void insertMemberById(const QString &id,IMember *h);
- void insertMemberByName(const QString &name,IMember *h);
+ // IDoxygen
+ ICompoundIterator *compounds() const;
+ ICompound *compoundById(const QString &id) const;
+ virtual ICompound *compoundByName(const QString &name) const;
+ virtual ICompound *memberById(const QString &id) const;
+ virtual ICompoundIterator *memberByName(const QString &name) const;
- void initialize();
+ virtual void release();
+ void setDebugLevel(int level);
+ bool readXMLDir(const char *dirName);
+ void dump();
+ void unloadCompound(CompoundHandler *ch);
private:
- QList<ICompound> m_compounds;
- QDict<ICompound> m_compoundDict;
- QDict<ICompound> m_compoundNameDict;
- QDict<IMember> m_memberDict;
- QDict<QList<IMember> > m_memberNameDict;
+ CompoundEntry *m_curCompound;
+ MemberEntry *m_curMember;
+ QList<CompoundEntry> m_compounds;
+ QDict<CompoundEntry> m_compoundDict;
+ QDict<CompoundEntry> m_compoundNameDict;
+ QDict<MemberEntry> m_memberDict;
+ QDict<QList<CompoundEntry> > m_memberNameDict;
+ QString m_xmlDirName;
+ QDict<CompoundHandler> m_compoundsLoaded;
};
#endif