public class ImageMetadataExtractor extends Object
| Constructor and Description |
|---|
ImageMetadataExtractor(org.apache.tika.metadata.Metadata metadata) |
ImageMetadataExtractor(org.apache.tika.metadata.Metadata metadata,
org.apache.tika.parser.image.ImageMetadataExtractor.DirectoryHandler... handlers) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
handle(Iterator<com.drew.metadata.Directory> directories)
Copies extracted tags to tika metadata using registered handlers.
|
protected void |
handle(com.drew.metadata.Metadata metadataExtractor)
Copies extracted tags to tika metadata using registered handlers.
|
void |
parseJpeg(File file) |
void |
parseRawExif(byte[] exifData) |
void |
parseRawExif(InputStream stream,
int length,
boolean needsExifHeader) |
void |
parseRawXMP(byte[] xmpData) |
void |
parseTiff(File file) |
void |
parseWebP(File file) |
public ImageMetadataExtractor(org.apache.tika.metadata.Metadata metadata)
metadata - to extract to, using default directory handlerspublic ImageMetadataExtractor(org.apache.tika.metadata.Metadata metadata,
org.apache.tika.parser.image.ImageMetadataExtractor.DirectoryHandler... handlers)
metadata - to extract tohandlers - handlers in order, note that handlers may override values from earlier handlerspublic void parseJpeg(File file) throws IOException, SAXException, org.apache.tika.exception.TikaException
IOExceptionSAXExceptionorg.apache.tika.exception.TikaExceptionpublic void parseTiff(File file) throws IOException, SAXException, org.apache.tika.exception.TikaException
IOExceptionSAXExceptionorg.apache.tika.exception.TikaExceptionpublic void parseWebP(File file) throws IOException, org.apache.tika.exception.TikaException
IOExceptionorg.apache.tika.exception.TikaExceptionpublic void parseRawExif(InputStream stream, int length, boolean needsExifHeader) throws IOException, SAXException, org.apache.tika.exception.TikaException
IOExceptionSAXExceptionorg.apache.tika.exception.TikaExceptionpublic void parseRawExif(byte[] exifData)
throws IOException,
SAXException,
org.apache.tika.exception.TikaException
IOExceptionSAXExceptionorg.apache.tika.exception.TikaExceptionpublic void parseRawXMP(byte[] xmpData)
throws IOException,
SAXException,
org.apache.tika.exception.TikaException
IOExceptionSAXExceptionorg.apache.tika.exception.TikaExceptionprotected void handle(com.drew.metadata.Metadata metadataExtractor)
throws com.drew.metadata.MetadataException
metadataExtractor - Tag directories from a Metadata Extractor "reader"com.drew.metadata.MetadataException - This method does not handle exceptions from Metadata Extractorprotected void handle(Iterator<com.drew.metadata.Directory> directories) throws com.drew.metadata.MetadataException
directories - Metadata Extractor Directory instances.com.drew.metadata.MetadataException - This method does not handle exceptions from Metadata ExtractorCopyright © 2007–2016 The Apache Software Foundation. All rights reserved.