http://xml.apache.org/http://www.apache.org/http://www.w3.org/

Home

Readme
Charter
Release Info

Installation
Download
Build Instructions

FAQs
Samples
API Docs

DOM C++ Binding
Programming
Migration Guide

Feedback
Bug-Reporting
PDF Document

Source Repository
User Mail Archive
Devel Mail Archive

API Docs for SAX and DOM
 

XMLDOMMsg.hpp

Go to the documentation of this file.
00001 // This file is generated, don't edit it!!
00002 
00003 #if !defined(ERRHEADER_XMLDOMMsg)
00004 #define ERRHEADER_XMLDOMMsg
00005 
00006 #include <xercesc/framework/XMLErrorReporter.hpp>
00007 #include <xercesc/util/XercesDefs.hpp>
00008 #include <xercesc/dom/DOMError.hpp>
00009 
00010 XERCES_CPP_NAMESPACE_BEGIN
00011 
00012 class XMLDOMMsg
00013 {
00014 public :
00015     enum Codes
00016     {
00017         NoError                            = 0
00018       , F_LowBounds                        = 1
00019       , DOMEXCEPTION_ERRX                  = 2
00020       , INDEX_SIZE_ERR                     = 3
00021       , DOMSTRING_SIZE_ERR                 = 4
00022       , HIERARCHY_REQUEST_ERR              = 5
00023       , WRONG_DOCUMENT_ERR                 = 6
00024       , INVALID_CHARACTER_ERR              = 7
00025       , NO_DATA_ALLOWED_ERR                = 8
00026       , NO_MODIFICATION_ALLOWED_ERR        = 9
00027       , NOT_FOUND_ERR                      = 10
00028       , NOT_SUPPORTED_ERR                  = 11
00029       , INUSE_ATTRIBUTE_ERR                = 12
00030       , INVALID_STATE_ERR                  = 13
00031       , SYNTAX_ERR                         = 14
00032       , INVALID_MODIFICATION_ERR           = 15
00033       , NAMESPACE_ERR                      = 16
00034       , INVALID_ACCESS_ERR                 = 17
00035       , VALIDATION_ERR                     = 18
00036       , DOMRANGEEXCEPTION_ERRX             = 19
00037       , BAD_BOUNDARYPOINTS_ERR             = 20
00038       , INVALID_NODE_TYPE_ERR              = 21
00039       , Writer_NestedCDATA                 = 22
00040       , Writer_NotRepresentChar            = 23
00041       , Writer_NotRecognizedType           = 24
00042       , F_HighBounds                       = 25
00043       , W_LowBounds                        = 26
00044       , W_HighBounds                       = 27
00045       , E_LowBounds                        = 28
00046       , E_HighBounds                       = 29
00047     };
00048 
00049     static bool isFatal(const XMLDOMMsg::Codes toCheck)
00050     {
00051         return ((toCheck >= F_LowBounds) && (toCheck <= F_HighBounds));
00052     }
00053 
00054     static bool isWarning(const XMLDOMMsg::Codes toCheck)
00055     {
00056         return ((toCheck >= W_LowBounds) && (toCheck <= W_HighBounds));
00057     }
00058 
00059     static bool isError(const XMLDOMMsg::Codes toCheck)
00060     {
00061         return ((toCheck >= E_LowBounds) && (toCheck <= E_HighBounds));
00062     }
00063 
00064     static XMLErrorReporter::ErrTypes errorType(const XMLDOMMsg::Codes toCheck)
00065     {
00066        if ((toCheck >= W_LowBounds) && (toCheck <= W_HighBounds))
00067            return XMLErrorReporter::ErrType_Warning;
00068        else if ((toCheck >= F_LowBounds) && (toCheck <= F_HighBounds))
00069             return XMLErrorReporter::ErrType_Fatal;
00070        else if ((toCheck >= E_LowBounds) && (toCheck <= E_HighBounds))
00071             return XMLErrorReporter::ErrType_Error;
00072        return XMLErrorReporter::ErrTypes_Unknown;
00073     }
00074     static DOMError::ErrorSeverity  DOMErrorType(const XMLDOMMsg::Codes toCheck)
00075     {
00076        if ((toCheck >= W_LowBounds) && (toCheck <= W_HighBounds))
00077            return DOMError::DOM_SEVERITY_WARNING;
00078        else if ((toCheck >= F_LowBounds) && (toCheck <= F_HighBounds))
00079             return DOMError::DOM_SEVERITY_FATAL_ERROR;
00080        else return DOMError::DOM_SEVERITY_ERROR;
00081     }
00082 
00083 private:
00084     // -----------------------------------------------------------------------
00085     //  Unimplemented constructors and operators
00086     // -----------------------------------------------------------------------
00087     XMLDOMMsg();
00088 };
00089 
00090 XERCES_CPP_NAMESPACE_END
00091 
00092 #endif
00093 


Copyright © 1994-2004 The Apache Software Foundation. All Rights Reserved.