Package de.swa.gmaf.plugin
Class ExifHandler
java.lang.Object
de.swa.gmaf.plugin.ExifHandler
- All Implemented Interfaces:
GMAF_Plugin
public class ExifHandler extends java.lang.Object implements GMAF_Plugin
Exif Plugin based on Apache Commons Imaging
- Author:
- stefan_wagenpfeil
-
Constructor Summary
Constructors Constructor Description ExifHandler()
-
Method Summary
Modifier and Type Method Description static void
attachFeatureVector(java.io.File f, MMFG fv)
attaches a MMFG to the exif metadataboolean
canProcess(java.lang.String extension)
returns true, if one of the extensions is jpg, jpeg, png, tiff, or gifjava.util.Vector<Node>
getDetectedNodes()
this method is called by the GMAF to receive the results of this plugin and to fuse it into the MMFGstatic MMFG
getFeatureVectorFromExif(java.io.File f)
extracts a MMFG from the exif data, if it is contained withinboolean
isGeneralPlugin()
returns always truevoid
process(java.net.URL url, java.io.File f, byte[] bytes, MMFG fv)
processes the assetboolean
providesRecoursiveData()
returns always false, as exif is not recursive
-
Constructor Details
-
ExifHandler
public ExifHandler()
-
-
Method Details
-
canProcess
public boolean canProcess(java.lang.String extension)returns true, if one of the extensions is jpg, jpeg, png, tiff, or gif- Specified by:
canProcess
in interfaceGMAF_Plugin
- Returns:
- true or false
-
getFeatureVectorFromExif
extracts a MMFG from the exif data, if it is contained within -
attachFeatureVector
attaches a MMFG to the exif metadata -
process
processes the asset- Specified by:
process
in interfaceGMAF_Plugin
- Parameters:
url
- represents the temporary URL of the Multimedia asset to be processf
- represents the temporary file of the asset to be processedbytes
- contains the file's bytesfv
- represents the current MMFG, where the results of this plugin should be fused into
-
isGeneralPlugin
public boolean isGeneralPlugin()returns always true- Specified by:
isGeneralPlugin
in interfaceGMAF_Plugin
- Returns:
- true, if it is a general plugin
-
providesRecoursiveData
public boolean providesRecoursiveData()returns always false, as exif is not recursive- Specified by:
providesRecoursiveData
in interfaceGMAF_Plugin
- Returns:
- true, if recursive data is available
-
getDetectedNodes
Description copied from interface:GMAF_Plugin
this method is called by the GMAF to receive the results of this plugin and to fuse it into the MMFG- Specified by:
getDetectedNodes
in interfaceGMAF_Plugin
- Returns:
- a vector of MMFG nodes
-