summaryrefslogtreecommitdiff
path: root/ACEXML/common/SAXExceptions.h
diff options
context:
space:
mode:
Diffstat (limited to 'ACEXML/common/SAXExceptions.h')
-rw-r--r--ACEXML/common/SAXExceptions.h86
1 files changed, 60 insertions, 26 deletions
diff --git a/ACEXML/common/SAXExceptions.h b/ACEXML/common/SAXExceptions.h
index 5c2ffa29fef..8cf909befda 100644
--- a/ACEXML/common/SAXExceptions.h
+++ b/ACEXML/common/SAXExceptions.h
@@ -1,128 +1,162 @@
-// -*- C++ -*- $Id$
+// -*- C++ -*-
+
+//=============================================================================
+/**
+ * @file SAXExceptions.h
+ *
+ * $Id$
+ *
+ * @author Nanbor Wang <nanbor@cs.wustl.edu>
+ */
+//=============================================================================
#ifndef _ACEXML_SAXEXCEPTIONS_H_
#define _ACEXML_SAXEXCEPTIONS_H_
#include "common/Exception.h"
+/**
+ * @class ACEXML_SAXException SAXExceptions.h "common/SAXExceptions.h"
+ *
+ * @brief ACEXML_SAXException
+ *
+ * ACEXML_SAXException is the mother of all SAX related exceptions.
+ */
class ACEXML_Export ACEXML_SAXException : public ACEXML_Exception
{
public:
+ /// Default constructor.
ACEXML_SAXException (void);
+
+ /// Constructor initializing the exception message.
ACEXML_SAXException (const ACEXML_Char *msg);
+
+ /// Copy constructor.
ACEXML_SAXException (const ACEXML_SAXException &ex);
+ /// Destructor.
virtual ~ACEXML_SAXException (void);
static const ACEXML_Char *name (void);
- // Accessor for the exception name.
virtual const ACEXML_Char *id (void);
- // Return the exception type. (for safe downcast.)
+ /// Return the extra message accompanying the exception.
const ACEXML_Char *message (void);
- // Return the extra message accompanying the exception.
virtual ACEXML_Exception *duplicate (void);
- // Dynamically create a copy of this exception.
virtual int is_a (const ACEXML_Char *name);
- // Check whether this is an exception of type specify by
- // <name>.
virtual void print (void);
- // Print out exception using ACE_DEBUG.
protected:
static const ACEXML_Char *exception_name_;
+ /// A message providing more information about the exception being thrown.
ACEXML_Char *message_;
};
+/**
+ * @class ACEXML_SAXNotSupportedException SAXExceptions.h "common/SAXExceptions.h"
+ *
+ * @brief ACEXML_SAXNotSupportedException
+ */
class ACEXML_Export ACEXML_SAXNotSupportedException
: public ACEXML_SAXException
{
public:
+ /// Default constructor.
ACEXML_SAXNotSupportedException (void);
+
+ /// Copy constructor.
ACEXML_SAXNotSupportedException (const ACEXML_SAXNotSupportedException &ex);
+ /// Destructor.
virtual ~ACEXML_SAXNotSupportedException (void);
static const ACEXML_Char *name (void);
- // Accessor for the exception name.
virtual const ACEXML_Char *id (void);
- // Return the exception type. (for safe downcast.)
virtual ACEXML_Exception *duplicate (void);
- // Dynamically create a copy of this exception.
virtual int is_a (const ACEXML_Char *name);
- // Check whether this is an exception of type specify by
- // <name>.
virtual void print (void);
- // Print out exception using ACE_DEBUG.
protected:
static const ACEXML_Char *exception_name_;
};
+/**
+ * @class ACEXML_SAXNotRecognizedException SAXExceptions.h "common/SAXExceptions.h"
+ *
+ * @brief ACEXML_SAXNotRecognizedException
+ */
class ACEXML_Export ACEXML_SAXNotRecognizedException
: public ACEXML_SAXException
{
public:
+ /// Default constructor.
ACEXML_SAXNotRecognizedException (void);
+
+ /// Constructor with an initializing exception message.
ACEXML_SAXNotRecognizedException (const ACEXML_Char *msg);
+
+ /// Copy constructor.
ACEXML_SAXNotRecognizedException (const ACEXML_SAXNotRecognizedException &ex);
+ /// Destructor.
virtual ~ACEXML_SAXNotRecognizedException (void);
static const ACEXML_Char *name (void);
- // Accessor for the exception name.
virtual const ACEXML_Char *id (void);
- // Return the exception type. (for safe downcast.)
virtual ACEXML_Exception *duplicate (void);
- // Dynamically create a copy of this exception.
virtual int is_a (const ACEXML_Char *name);
- // Check whether this is an exception of type specify by
- // <name>.
virtual void print (void);
- // Print out exception using ACE_DEBUG.
protected:
static const ACEXML_Char *exception_name_;
};
+/**
+ * @class ACEXML_SAXParseException SAXExceptions.h "common/SAXExceptions.h"
+ *
+ * @brief ACEXML_SAXParseException
+ *
+ * @todo This exception needs to provide error location information to behave like
+ * the real SAXParseException defined in SAX2 spec.
+ */
class ACEXML_Export ACEXML_SAXParseException
: public ACEXML_SAXException
{
public:
+ /// Default constructor.
ACEXML_SAXParseException (void);
+
+ /// Constructor with an initializing exception message.
ACEXML_SAXParseException (const ACEXML_Char *msg);
+
+ /// Copy constructor.
ACEXML_SAXParseException (const ACEXML_SAXParseException &ex);
+ /// Destructor.
virtual ~ACEXML_SAXParseException (void);
static const ACEXML_Char *name (void);
- // Accessor for the exception name.
virtual const ACEXML_Char *id (void);
- // Return the exception type. (for safe downcast.)
virtual ACEXML_Exception *duplicate (void);
- // Dynamically create a copy of this exception.
virtual int is_a (const ACEXML_Char *name);
- // Check whether this is an exception of type specify by
- // <name>.
virtual void print (void);
- // Print out exception using ACE_DEBUG.
protected:
static const ACEXML_Char *exception_name_;