Class PDFExtensionHandler
java.lang.Object
org.xml.sax.helpers.DefaultHandler
org.apache.fop.render.pdf.extensions.PDFExtensionHandler
- All Implemented Interfaces:
ContentHandlerFactory.ObjectSource
,ContentHandler
,DTDHandler
,EntityResolver
,ErrorHandler
public class PDFExtensionHandler
extends DefaultHandler
implements ContentHandlerFactory.ObjectSource
ContentHandler (parser) for restoring PDF extension objects from XML.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate boolean
private StringBuffer
private Stack
<PDFCollectionExtension> private Attributes
protected static final org.apache.commons.logging.Log
Logger instanceprivate PDFExtensionAttachment
private org.apache.xmlgraphics.xmp.XMPHandler
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
characters
(char[] data, int start, int length) void
void
endElement
(String uri, String localName, String qName) private void
void
Set a listener which gets notified when the object is fully built.void
startElement
(String uri, String localName, String qName, Attributes attributes) Methods inherited from class org.xml.sax.helpers.DefaultHandler
endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning
-
Field Details
-
log
protected static final org.apache.commons.logging.Log logLogger instance -
returnedObject
-
listener
-
lastAttributes
-
collections
-
captureContent
private boolean captureContent -
characters
-
xmpHandler
private org.apache.xmlgraphics.xmp.XMPHandler xmpHandler
-
-
Constructor Details
-
PDFExtensionHandler
public PDFExtensionHandler()
-
-
Method Details
-
startElement
public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException - Specified by:
startElement
in interfaceContentHandler
- Overrides:
startElement
in classDefaultHandler
- Throws:
SAXException
-
characters
- Specified by:
characters
in interfaceContentHandler
- Overrides:
characters
in classDefaultHandler
- Throws:
SAXException
-
endElement
- Specified by:
endElement
in interfaceContentHandler
- Overrides:
endElement
in classDefaultHandler
- Throws:
SAXException
-
setExtension
private void setExtension() -
endDocument
- Specified by:
endDocument
in interfaceContentHandler
- Overrides:
endDocument
in classDefaultHandler
- Throws:
SAXException
-
getObject
- Specified by:
getObject
in interfaceContentHandlerFactory.ObjectSource
- Returns:
- the object parsed from the SAX stream (call valid after parsing)
-
setObjectBuiltListener
Description copied from interface:ContentHandlerFactory.ObjectSource
Set a listener which gets notified when the object is fully built.- Specified by:
setObjectBuiltListener
in interfaceContentHandlerFactory.ObjectSource
- Parameters:
listener
- the listener which gets notified
-