public class XmlProcessingException extends java.lang.Object implements XmlProcessingError
XmlProcessingError
interface that wraps an XPathException object.| Constructor and Description |
|---|
XmlProcessingException(XPathException exception)
Create an XmlProcessingException wrapping an XPathException
|
| Modifier and Type | Method and Description |
|---|---|
XmlProcessingException |
asWarning()
Return an XmlProcessingError containing the same information, but to be treated as
a warning condition
|
java.lang.Throwable |
getCause()
Return an underlying exception.
|
QName |
getErrorCode()
Get the error code, as a QName.
|
java.lang.String |
getFatalErrorMessage()
Ask whether this error is to be treated as fatal, and if so, return the relevant messsage
|
HostLanguage |
getHostLanguage() |
Location |
getLocation()
Get the location information associated with the error
|
java.lang.String |
getMessage()
Get the error message associated with this error
|
java.lang.String |
getPath()
Get the absolute XPath expression that identifies the node within its document
where the error occurred, if available
|
XPathException |
getXPathException()
Get the wrapped exception
|
boolean |
isAlreadyReported()
Ask whether this static error has already been reported
|
boolean |
isStaticError()
Ask whether this is a static error, defined as an error that can be detected during
static analysis of a stylesheet, query, schema, or XPath expression.
|
boolean |
isTypeError()
Ask whether this is a type error.
|
boolean |
isWarning()
Ask whether this error is being reported as a warning condition.
|
void |
setAlreadyReported(boolean reported)
Say whether this error has already been reported
|
void |
setFatal(java.lang.String message)
Indicate that this error is to be treated as fatal; that is, execution will be abandoned
after reporting this error.
|
void |
setWarning(boolean warning) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetModuleUrigetColumnNumber, getInstructionName, getLineNumberpublic XmlProcessingException(XPathException exception)
exception - the wrapped exceptionpublic XPathException getXPathException()
public HostLanguage getHostLanguage()
getHostLanguage in interface XmlProcessingErrorpublic boolean isStaticError()
XmlProcessingErrorisStaticError in interface XmlProcessingErrorpublic boolean isTypeError()
XmlProcessingErrorisTypeError in interface StaticErrorisTypeError in interface XmlProcessingErrorpublic QName getErrorCode()
XmlProcessingErrorgetErrorCode in interface StaticErrorgetErrorCode in interface XmlProcessingErrorpublic java.lang.String getMessage()
XmlProcessingErrorgetMessage in interface StaticErrorgetMessage in interface XmlProcessingErrorpublic Location getLocation()
XmlProcessingErrorgetLocation in interface StaticErrorgetLocation in interface XmlProcessingErrorpublic boolean isWarning()
XmlProcessingErrorisWarning in interface StaticErrorisWarning in interface XmlProcessingErrorpublic java.lang.String getPath()
XmlProcessingErrorgetPath in interface StaticErrorgetPath in interface XmlProcessingErrorpublic java.lang.Throwable getCause()
XmlProcessingErrorgetCause in interface XmlProcessingErrorpublic void setWarning(boolean warning)
public XmlProcessingException asWarning()
XmlProcessingErrorasWarning in interface XmlProcessingErrorpublic void setFatal(java.lang.String message)
ErrorReporter, for example
if the error is considered so severe that further processing is not worthwhile, or if
too many errors have been signalled. There is no absolute guarantee that setting this
property will cause execution to be abandoned. If a dynamic error is marked as fatal, it
will generally not be caught by any try/catch mechanism within the stylesheet or query.setFatal in interface StaticErrormessage - an error message giving the reason for the fatal errorpublic java.lang.String getFatalErrorMessage()
getFatalErrorMessage in interface StaticErrorpublic boolean isAlreadyReported()
isAlreadyReported in interface XmlProcessingErrorpublic void setAlreadyReported(boolean reported)
setAlreadyReported in interface XmlProcessingErrorreported - true if the error has been reportedCopyright (c) 2004-2020 Saxonica Limited.