Package com.fasterxml.aalto
Class ValidationException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- javax.xml.stream.XMLStreamException
-
- org.codehaus.stax2.validation.XMLValidationException
-
- com.fasterxml.aalto.ValidationException
-
- All Implemented Interfaces:
java.io.Serializable
public class ValidationException extends org.codehaus.stax2.validation.XMLValidationExceptionSpecific exception thrown when document has validation (DTD, W3C Schema) errors; things that are not well-formedness problems.The current implementation does not add much beyond basic
XMLValidationException, except for fixing some problems that underlyingXMLStreamExceptionhas.Note that some of the code is shared with other sub-classes. Unfortunately it is not possible to extend it, since they extend
XMLStreamException, notXMLValidationException.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedValidationException(org.codehaus.stax2.validation.XMLValidationProblem cause, java.lang.String msg)protectedValidationException(org.codehaus.stax2.validation.XMLValidationProblem cause, java.lang.String msg, javax.xml.stream.Location loc)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ValidationExceptioncreate(org.codehaus.stax2.validation.XMLValidationProblem cause)protected java.lang.StringgetLocationDesc()java.lang.StringgetMessage()Method is overridden for two main reasons: first, default method does not display public/system id information, even if it exists, and second, default implementation can not handle nested Location information.java.lang.StringtoString()-
Methods inherited from class org.codehaus.stax2.validation.XMLValidationException
createException, getValidationProblem, throwMissing
-
-
-
-
Constructor Detail
-
ValidationException
protected ValidationException(org.codehaus.stax2.validation.XMLValidationProblem cause, java.lang.String msg)
-
ValidationException
protected ValidationException(org.codehaus.stax2.validation.XMLValidationProblem cause, java.lang.String msg, javax.xml.stream.Location loc)
-
-
Method Detail
-
create
public static ValidationException create(org.codehaus.stax2.validation.XMLValidationProblem cause)
-
getMessage
public java.lang.String getMessage()
Method is overridden for two main reasons: first, default method does not display public/system id information, even if it exists, and second, default implementation can not handle nested Location information.- Overrides:
getMessagein classjava.lang.Throwable
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Throwable
-
getLocationDesc
protected java.lang.String getLocationDesc()
-
-