public class JAXBErrorHandler extends Object implements ErrorHandler
Implementation of org.xml.sax.ErrorHandler. When JAXBMarshaller or JAXBUnmarshaller is given a ValidationEventHandler a JAXBErrorHandler is used to wrap it. This ErrorHandler is then used by the underlying XMLMarshaller or XMLUnmarshaller.
Constructor and Description |
---|
JAXBErrorHandler(ValidationEventHandler validationEventHandler)
Create a new JAXBErrorHandler with the specified ValidationEventHandler
|
Modifier and Type | Method and Description |
---|---|
void |
error(SAXParseException exception)
Handle errors.
|
void |
fatalError(SAXParseException exception)
Handle fatal errors.
|
ValidationEventHandler |
getValidationEventHandler()
Return the ValidationEventHandler associated with this JAXBErrorHandler.
|
void |
warning(SAXParseException exception)
Handle warnings
The exception will be given to the ValidationEventHandler at to attempt to handle.
|
public JAXBErrorHandler(ValidationEventHandler validationEventHandler)
validationEventHandler
- public void warning(SAXParseException exception) throws SAXException
warning
in interface ErrorHandler
exception
- the SAXParseException that occurredSAXException
public void error(SAXParseException exception) throws SAXException
error
in interface ErrorHandler
exception
- the SAXParseException that occurredSAXException
public void fatalError(SAXParseException exception) throws SAXException
fatalError
in interface ErrorHandler
exception
- the SAXParseException that occurredSAXException
public ValidationEventHandler getValidationEventHandler()
Copyright © 2017–2020 Eclipse.org - EclipseLink Project. All rights reserved.