summaryrefslogtreecommitdiffstats
path: root/addon/xmlread/saxhandlers.h
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2000-07-30 13:58:29 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2000-07-30 13:58:29 (GMT)
commit3876f92c80e9cc62af30916f0ccdeb83cdc2ff05 (patch)
tree2d71d4688e381dc8e0c968d120b25fdd0763c27e /addon/xmlread/saxhandlers.h
parent7295388a3c6b3a12a77dc7a56862333c97e4ccb6 (diff)
downloadDoxygen-3876f92c80e9cc62af30916f0ccdeb83cdc2ff05.zip
Doxygen-3876f92c80e9cc62af30916f0ccdeb83cdc2ff05.tar.gz
Doxygen-3876f92c80e9cc62af30916f0ccdeb83cdc2ff05.tar.bz2
Release-1.2.0-20000730
Diffstat (limited to 'addon/xmlread/saxhandlers.h')
-rw-r--r--addon/xmlread/saxhandlers.h101
1 files changed, 101 insertions, 0 deletions
diff --git a/addon/xmlread/saxhandlers.h b/addon/xmlread/saxhandlers.h
new file mode 100644
index 0000000..c9f38b8
--- /dev/null
+++ b/addon/xmlread/saxhandlers.h
@@ -0,0 +1,101 @@
+#ifndef _SAXHANDLERS_H
+#define _SAXHANDLERS_H
+
+#include "compounddef.h"
+#include <sax/HandlerBase.hpp>
+
+/*! SAX Handlers used for pass 1. */
+class SaxPass1Handlers : public HandlerBase
+{
+ public:
+ // -----------------------------------------------------------------------
+ //! @name Constructors
+ // -----------------------------------------------------------------------
+ //@{
+ /*! Constructor */
+ SaxPass1Handlers(CompoundSDict *comp);
+ /*! Destructor */
+ ~SaxPass1Handlers();
+ //@}
+
+ // -----------------------------------------------------------------------
+ //! @name Implementations of the SAX DocumentHandler interface
+ // -----------------------------------------------------------------------
+ //@{
+ /*! Handler called at the start of the XML document */
+ void startDocument() {}
+ /*! Handler called at the end of the XML document */
+ void endDocument();
+ /*! Handler called when an element is found in the XML file
+ * \param name The element's name.
+ * \param attributes The list of attributes for the element.
+ */
+ void startElement(const XMLCh* const name, AttributeList& attributes);
+ /*! Handler called when the element of an element is found in the XML file
+ * \param name The element's name.
+ */
+ void endElement(const XMLCh* const name);
+ /*! Handler called when a character string is found in the XML file.
+ * \param chars Zero terminated string of characters.
+ * \param length The number of characters in the string.
+ */
+ void characters(const XMLCh* const chars, const unsigned int length);
+
+ /*! Handler called when an amount of whitespace is found, that is not
+ * Part of the text.
+ */
+ void ignorableWhitespace(const XMLCh* const /*chars*/,
+ const unsigned int /*length*/
+ ) {}
+
+ /*! Handler called when a preprocessing intruction is found.
+ */
+ void processingInstruction(const XMLCh* const /*target*/,
+ const XMLCh* const /*data*/
+ ) {}
+ //@}
+
+ // -----------------------------------------------------------------------
+ //! @name Implementations of the SAX ErrorHandler interface
+ // -----------------------------------------------------------------------
+ //@{
+ /*! Handler called for a parser warning. */
+ void warning(const SAXParseException& exception);
+ /*! Handler called for a parser error. */
+ void error(const SAXParseException& exception);
+ /*! Handler called for a parser fatal error. */
+ void fatalError(const SAXParseException& exception);
+ //@}
+
+ // -----------------------------------------------------------------------
+ //! @name Implementation of the SAX DTDHandler interface
+ // -----------------------------------------------------------------------
+ //@{
+ /*! Handler for DTD notation declaration. */
+ void notationDecl(const XMLCh* const /*name*/,
+ const XMLCh* const /*publicId*/,
+ const XMLCh* const /*systemId*/
+ ) {}
+
+ /*! Handler for DTD unparsed entity declaration. */
+ void unparsedEntityDecl(const XMLCh* const /*name*/,
+ const XMLCh* const /*publicId*/,
+ const XMLCh* const /*systemId*/,
+ const XMLCh* const /*notationName*/
+ ) {}
+ //@}
+
+ private:
+ // -----------------------------------------------------------------------
+ // Private data members
+ //
+ // -----------------------------------------------------------------------
+
+ enum CharActions { Done, ReadCompoundName };
+ CompoundSDict *m_compounds;
+ CompoundDef_Impl *m_currentCompound;
+ QCString m_compoundName;
+ CharActions m_charAction;
+};
+
+#endif