Xerces-C++: DOMError Class Reference (original) (raw)
DOMError is an interface that describes an error. More...
#include <[xercesc/dom/DOMError.hpp](DOMError%5F8hpp%5Fsource.html)>
| Public Types | |
|---|---|
| Public constants | |
| enum | ErrorSeverity { DOM_SEVERITY_WARNING = 1 , DOM_SEVERITY_ERROR = 2 , DOM_SEVERITY_FATAL_ERROR = 3 } |
| The severity of the error described by the DOMError. More... | |
| Public Member Functions | |
|---|---|
| Destructor | |
| virtual | ~DOMError () |
| Destructor. | |
| Functions introduced in DOM Level 3 | |
| virtual ErrorSeverity | getSeverity () const =0 |
| Get the severity of the error. | |
| virtual const XMLCh * | getMessage () const =0 |
| Get the message describing the error that occured. | |
| virtual DOMLocator * | getLocation () const =0 |
| Get the location of the error. | |
| virtual void * | getRelatedException () const =0 |
| The related platform dependent exception if any. | |
| virtual const XMLCh * | getType () const =0 |
| A XMLCh* indicating which related data is expected in relatedData. | |
| virtual void * | getRelatedData () const =0 |
| The related DOMError::getType dependent data if any. | |
| Protected Member Functions |
|---|
| Hidden constructors |
DOMError is an interface that describes an error.
See also
Since
DOM Level 3
◆ ErrorSeverity
The severity of the error described by the [DOMError](classDOMError.html "DOMError is an interface that describes an error.").
DOM_SEVERITY_ERROR: The severity of the error described by the [DOMError](classDOMError.html "DOMError is an interface that describes an error.") is error. A DOM_SEVERITY_ERROR may not cause the processing to stop if the error can be recovered, unless [DOMErrorHandler::handleError()](classDOMErrorHandler.html#a156c98881fb79279c83f52f20ac8f5c4 "This method is called on the error handler when an error occurs.") returns false.
DOM_SEVERITY_FATAL_ERROR The severity of the error described by the [DOMError](classDOMError.html "DOMError is an interface that describes an error.") is fatal error. A DOM_SEVERITY_FATAL_ERROR will cause the normal processing to stop. The return value of [DOMErrorHandler::handleError()](classDOMErrorHandler.html#a156c98881fb79279c83f52f20ac8f5c4 "This method is called on the error handler when an error occurs.") is ignored unless the implementation chooses to continue, in which case the behavior becomes undefined.
DOM_SEVERITY_WARNING The severity of the error described by the [DOMError](classDOMError.html "DOMError is an interface that describes an error.") is warning. A DOM_SEVERITY_WARNING will not cause the processing to stop, unless [DOMErrorHandler::handleError()](classDOMErrorHandler.html#a156c98881fb79279c83f52f20ac8f5c4 "This method is called on the error handler when an error occurs.") returns false.
Since
DOM Level 3
| Enumerator |
|---|
| DOM_SEVERITY_WARNING |
| DOM_SEVERITY_ERROR |
| DOM_SEVERITY_FATAL_ERROR |
| DOMError::DOMError ( ) | protected |
|---|
◆ ~DOMError()
| virtual DOMError::~DOMError ( ) | virtual |
|---|
Destructor.
◆ getLocation()
| virtual DOMLocator * DOMError::getLocation ( ) const | pure virtual |
|---|
Get the location of the error.
Since
DOM Level 3
◆ getMessage()
| virtual const XMLCh * DOMError::getMessage ( ) const | pure virtual |
|---|
Get the message describing the error that occured.
Since
DOM Level 3
◆ getRelatedData()
| virtual void * DOMError::getRelatedData ( ) const | pure virtual |
|---|
The related DOMError::getType dependent data if any.
Since
DOM Level 3
◆ getRelatedException()
| virtual void * DOMError::getRelatedException ( ) const | pure virtual |
|---|
The related platform dependent exception if any.
Since
DOM Level 3
◆ getSeverity()
| virtual ErrorSeverity DOMError::getSeverity ( ) const | pure virtual |
|---|
Get the severity of the error.
See also
setSeverity
Since
DOM Level 3
◆ getType()
| virtual const XMLCh * DOMError::getType ( ) const | pure virtual |
|---|
A XMLCh* indicating which related data is expected in relatedData.
Users should refer to the specification of the error in order to find its XMLCh* type and relatedData definitions if any.
Note: As an example, [DOMDocument::normalizeDocument()](classDOMDocument.html#a885bc5e1454842a82d22f75c35c25ff7 "This method acts as if the document was going through a save and load cycle, putting the document in ...") does generate warnings when the "split-cdata-sections" parameter is in use. Therefore, the method generates a DOM_SEVERITY_WARNING with type "cdata-sections-splitted" and the first [DOMCDATASection](classDOMCDATASection.html "CDATA sections are used to escape blocks of text containing characters that would otherwise be regard...") node in document order resulting from the split is returned by the relatedData attribute.
Since
DOM Level 3
The documentation for this class was generated from the following file: