Package org.apache.tika.parser.xml
Class AttributeMetadataHandler
java.lang.Object
org.xml.sax.helpers.DefaultHandler
org.apache.tika.parser.xml.AttributeMetadataHandler
- All Implemented Interfaces:
- ContentHandler,- DTDHandler,- EntityResolver,- ErrorHandler
SAX event handler that maps the contents of an XML attribute into
 a metadata field.
- Since:
- Apache Tika 0.10
- 
Constructor SummaryConstructorsConstructorDescriptionAttributeMetadataHandler(String uri, String localName, Metadata metadata, String name) AttributeMetadataHandler(String uri, String localName, Metadata metadata, Property property) 
- 
Method SummaryModifier and TypeMethodDescriptionprotected voidaddMetadata(String value) Adds the given metadata value.voidstartElement(String uri, String localName, String qName, Attributes attributes) Methods inherited from class org.xml.sax.helpers.DefaultHandlercharacters, endDocument, endElement, endPrefixMapping, error, fatalError, ignorableWhitespace, notationDecl, processingInstruction, resolveEntity, setDocumentLocator, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warningMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.xml.sax.ContentHandlerdeclaration
- 
Constructor Details- 
AttributeMetadataHandler
- 
AttributeMetadataHandler
 
- 
- 
Method Details- 
startElementpublic void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException - Specified by:
- startElementin interface- ContentHandler
- Overrides:
- startElementin class- DefaultHandler
- Throws:
- SAXException
 
- 
addMetadataAdds the given metadata value. The value is ignored if it isnullor empty. If the metadata entry already exists, then the given value is appended to it with a comma as the separator.- Parameters:
- value- metadata value
 
 
-