Package com.day.cq.dam.api.handler.xmp
Interface XMPHandler
-
public interface XMPHandler
TheXMPHandler
interface defines the functionality needed to read and write XMP meta info to and from Asset. There can be only one active implementation at any given time. Highest ranked service will be used if more than one implementations are available.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description boolean
isSupported(String mimeType)
Checks if the provided mime type is supported by the implementationXMPMeta
readXmp(Asset asset)
Deprecated.XMPMetadata
readXmpMetadata(Asset asset)
Read xmp packet from the original binaryvoid
writeXmp(Asset asset, byte[] xmpBytes)
Write xmp bytes back to the original binaryvoid
writeXmp(Asset asset, byte[] xmpBytes, boolean createVersion)
Deprecated.usewriteXmp(Asset, byte[], XMPWriteBackOptions)
insteadvoid
writeXmp(Asset asset, byte[] xmpBytes, XMPWriteBackOptions writeBackOptions)
Write xmp bytes back to the original/renditions' binaryvoid
writeXmp(Asset asset, XMPMeta xmpMeta)
Deprecated.void
writeXmp(Asset asset, XMPMeta xmpMeta, boolean createVersion)
Deprecated.usewriteXmp(Asset, XMPMeta, XMPWriteBackOptions)
insteadvoid
writeXmp(Asset asset, XMPMeta xmpMeta, XMPWriteBackOptions writeBackOptions)
Write xmp meta back to the original/renditions' binaryvoid
writeXmpMetadata(Asset asset, XMPMetadata xmpMetadata, XMPWriteBackOptions writeBackOptions)
Write xmp meta back to the original binary
-
-
-
Method Detail
-
isSupported
boolean isSupported(String mimeType)
Checks if the provided mime type is supported by the implementation- Parameters:
mimeType
- to be checked- Returns:
- true if the given mime type is supported
-
readXmp
@Deprecated XMPMeta readXmp(Asset asset) throws IOException
Deprecated.Read xmp packet from the original binary- Parameters:
asset
- asset to read xmp from- Returns:
- XMPMeta
- Throws:
IOException
- if fails to read xmp
-
readXmpMetadata
XMPMetadata readXmpMetadata(Asset asset) throws IOException
Read xmp packet from the original binary- Parameters:
asset
- asset to read xmp metadata from- Returns:
- XMPMetaData
- Throws:
IOException
- if fails to read xmp
-
writeXmp
void writeXmp(Asset asset, byte[] xmpBytes) throws IOException
Write xmp bytes back to the original binary- Parameters:
asset
- asset to write xmp bytes back toxmpBytes
- xmp bytes to be written back- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmp
@Deprecated void writeXmp(Asset asset, XMPMeta xmpMeta) throws IOException
Deprecated.Write xmp meta back to the original binary- Parameters:
asset
- asset to write xmp meta back toxmpMeta
- object- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmp
void writeXmp(Asset asset, byte[] xmpBytes, boolean createVersion) throws IOException
Deprecated.usewriteXmp(Asset, byte[], XMPWriteBackOptions)
insteadWrite xmp bytes back to the original binary- Parameters:
asset
- asset asset to write xmp bytes back toxmpBytes
- xmp bytes to be written backcreateVersion
- if true then create versions of the asset on each writeback- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmp
void writeXmp(Asset asset, XMPMeta xmpMeta, boolean createVersion) throws IOException
Deprecated.usewriteXmp(Asset, XMPMeta, XMPWriteBackOptions)
insteadWrite xmp meta back to the original binary- Parameters:
asset
- asset to write xmp meta back toxmpMeta
- objectcreateVersion
- if true then create versions of the asset on each writeback- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmp
void writeXmp(Asset asset, byte[] xmpBytes, XMPWriteBackOptions writeBackOptions) throws IOException
Write xmp bytes back to the original/renditions' binary- Parameters:
asset
- asset to write xmp bytes back toxmpBytes
- xmp bytes to be written backwriteBackOptions
- the XMP write back options- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmpMetadata
void writeXmpMetadata(Asset asset, XMPMetadata xmpMetadata, XMPWriteBackOptions writeBackOptions) throws IOException
Write xmp meta back to the original binary- Parameters:
asset
- asset to write xmp meta back toxmpMetadata
- objectwriteBackOptions
- the XMP write back options- Throws:
IOException
- if fails to write back xmp to the binary
-
writeXmp
void writeXmp(Asset asset, XMPMeta xmpMeta, XMPWriteBackOptions writeBackOptions) throws IOException
Write xmp meta back to the original/renditions' binary- Parameters:
asset
- asset to write xmp meta back toxmpMeta
- objectwriteBackOptions
- the XMP write back options- Throws:
IOException
- if fails to write back xmp to the binary
-
-