Package org.apache.tika.sax
Class XMPContentHandler
- java.lang.Object
-
- org.xml.sax.helpers.DefaultHandler
-
- org.apache.tika.sax.ContentHandlerDecorator
-
- org.apache.tika.sax.SafeContentHandler
-
- org.apache.tika.sax.XMPContentHandler
-
- All Implemented Interfaces:
ContentHandler,DTDHandler,EntityResolver,ErrorHandler
public class XMPContentHandler extends SafeContentHandler
Content handler decorator that simplifies the task of producing XMP output.- Since:
- Apache Tika 1.0
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.tika.sax.SafeContentHandler
SafeContentHandler.Output
-
-
Constructor Summary
Constructors Constructor Description XMPContentHandler(ContentHandler handler)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidendDescription()voidendDocument()Ends the XMP document by writing the following footer and clearing the namespace mappings:voidmetadata(Metadata metadata)voidproperty(String name, String value)voidstartDescription(String about, String prefix, String uri)voidstartDocument()Starts an XMP document by setting up the namespace mappings and writing out the following header:-
Methods inherited from class org.apache.tika.sax.SafeContentHandler
characters, endElement, ignorableWhitespace, isInvalid, startElement, writeReplacement
-
Methods inherited from class org.apache.tika.sax.ContentHandlerDecorator
endPrefixMapping, error, fatalError, handleException, processingInstruction, setContentHandler, setDocumentLocator, skippedEntity, startPrefixMapping, toString, warning
-
Methods inherited from class org.xml.sax.helpers.DefaultHandler
notationDecl, resolveEntity, unparsedEntityDecl
-
-
-
-
Field Detail
-
RDF
public static final String RDF
The RDF namespace URI- See Also:
- Constant Field Values
-
XMP
public static final String XMP
The XMP namespace URI- See Also:
- Constant Field Values
-
-
Constructor Detail
-
XMPContentHandler
public XMPContentHandler(ContentHandler handler)
-
-
Method Detail
-
startDocument
public void startDocument() throws SAXExceptionStarts an XMP document by setting up the namespace mappings and writing out the following header:<rdf:RDF>
- Specified by:
startDocumentin interfaceContentHandler- Overrides:
startDocumentin classContentHandlerDecorator- Throws:
SAXException
-
endDocument
public void endDocument() throws SAXExceptionEnds the XMP document by writing the following footer and clearing the namespace mappings:</rdf:RDF>
- Specified by:
endDocumentin interfaceContentHandler- Overrides:
endDocumentin classSafeContentHandler- Throws:
SAXException
-
startDescription
public void startDescription(String about, String prefix, String uri) throws SAXException
- Throws:
SAXException
-
endDescription
public void endDescription() throws SAXException- Throws:
SAXException
-
property
public void property(String name, String value) throws SAXException
- Throws:
SAXException
-
metadata
public void metadata(Metadata metadata) throws SAXException
- Throws:
SAXException
-
-