Package org.verapdf.processor
Class AbstractXmlHandler
- java.lang.Object
-
- org.verapdf.processor.AbstractBatchHandler
-
- org.verapdf.processor.AbstractXmlHandler
-
- All Implemented Interfaces:
Closeable,AutoCloseable,BatchProcessingHandler
public abstract class AbstractXmlHandler extends AbstractBatchHandler
- Version:
- 0.1 Created 09 Nov 2016:00:32:49
- Author:
- Carl Wilson carlwilson AT github
-
-
Field Summary
Fields Modifier and Type Field Description protected static StringstrmExcpMessTmplprotected static StringunmarshalErrMessageprotected XMLStreamWriterwriterprotected static StringwritingMessage
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractXmlHandler(Writer dest)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddAttribute(String name, String value)voidclose()protected static voidendDoc(XMLStreamWriter writer)protected static voidnewLine(XMLStreamWriter writer)protected <T> voidserialseElement(T obj, String eleName, boolean format, boolean fragment)protected static voidstartDoc(XMLStreamWriter writer)protected static VeraPDFExceptionwrapMarshallException(JAXBException excep, String typePart)protected static VeraPDFExceptionwrapStreamException(XMLStreamException excep)protected static VeraPDFExceptionwrapStreamException(XMLStreamException excep, String verbPart)-
Methods inherited from class org.verapdf.processor.AbstractBatchHandler
handleResult
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.verapdf.processor.BatchProcessingHandler
handleBatchEnd, handleBatchStart
-
-
-
-
Field Detail
-
strmExcpMessTmpl
protected static final String strmExcpMessTmpl
- See Also:
- Constant Field Values
-
unmarshalErrMessage
protected static final String unmarshalErrMessage
- See Also:
- Constant Field Values
-
writingMessage
protected static final String writingMessage
- See Also:
- Constant Field Values
-
writer
protected XMLStreamWriter writer
-
-
Constructor Detail
-
AbstractXmlHandler
protected AbstractXmlHandler(Writer dest) throws VeraPDFException
- Throws:
VeraPDFException
-
-
Method Detail
-
serialseElement
protected <T> void serialseElement(T obj, String eleName, boolean format, boolean fragment) throws VeraPDFException- Throws:
VeraPDFException
-
close
public void close()
-
startDoc
protected static void startDoc(XMLStreamWriter writer) throws XMLStreamException
- Throws:
XMLStreamException
-
endDoc
protected static void endDoc(XMLStreamWriter writer) throws XMLStreamException
- Throws:
XMLStreamException
-
addAttribute
protected void addAttribute(String name, String value) throws XMLStreamException
- Throws:
XMLStreamException
-
newLine
protected static void newLine(XMLStreamWriter writer) throws XMLStreamException
- Throws:
XMLStreamException
-
wrapStreamException
protected static VeraPDFException wrapStreamException(XMLStreamException excep)
-
wrapStreamException
protected static VeraPDFException wrapStreamException(XMLStreamException excep, String verbPart)
-
wrapMarshallException
protected static final VeraPDFException wrapMarshallException(JAXBException excep, String typePart)
-
-