public class TiffRootPackage extends ImageRootPackage implements IXmp, IExif
Represents the root package allowing working with metadata in a TIFF image.
This example shows how to extract basic IPTC metadata properties from a TIFF image.
try (Metadata metadata = new Metadata(Constants.TiffWithIptc)) { TiffRootPackage root = metadata.getRootPackageGeneric(); if (root.getIptcPackage() != null) { if (root.getIptcPackage().getEnvelopeRecord() != null) { System.out.println(root.getIptcPackage().getEnvelopeRecord().getDateSent()); System.out.println(root.getIptcPackage().getEnvelopeRecord().getDestination()); System.out.println(root.getIptcPackage().getEnvelopeRecord().getFileFormat()); System.out.println(root.getIptcPackage().getEnvelopeRecord().getFileFormatVersion()); // ... } if (root.getIptcPackage().getApplicationRecord() != null) { System.out.println(root.getIptcPackage().getApplicationRecord().getHeadline()); System.out.println(root.getIptcPackage().getApplicationRecord().getByLine()); System.out.println(root.getIptcPackage().getApplicationRecord().getByLineTitle()); System.out.println(root.getIptcPackage().getApplicationRecord().getCaptionAbstract()); System.out.println(root.getIptcPackage().getApplicationRecord().getCity()); System.out.println(root.getIptcPackage().getApplicationRecord().getDateCreated()); System.out.println(root.getIptcPackage().getApplicationRecord().getReleaseDate()); // ... } } }
Modifier and Type | Method and Description |
---|---|
ExifPackage |
getExifPackage()
Gets the EXIF metadata package.
|
IptcRecordSet |
getIptcPackage()
Gets the IPTC metadata package.
|
XmpPacketWrapper |
getXmpPackage()
Gets the XMP metadata package.
|
void |
setExifPackage(ExifPackage value)
Sets the EXIF metadata package.
|
void |
setXmpPackage(XmpPacketWrapper value)
Sets the XMP metadata package.
|
getImageType
addProperties, findProperties, getFileType, removeProperties, sanitize, setProperties, updateProperties
contains, get_Item, getCount, getKeys, getKnowPropertyDescriptors, getMetadataType, iterator
public final XmpPacketWrapper getXmpPackage()
Gets the XMP metadata package.
getXmpPackage
in interface IXmp
public final void setXmpPackage(XmpPacketWrapper value)
Sets the XMP metadata package.
setXmpPackage
in interface IXmp
value
- The XMP metadata package.public final ExifPackage getExifPackage()
Gets the EXIF metadata package.
getExifPackage
in interface IExif
public final void setExifPackage(ExifPackage value)
Sets the EXIF metadata package.
setExifPackage
in interface IExif
value
- The EXIF metadata package.public final IptcRecordSet getIptcPackage()
Gets the IPTC metadata package.
Copyright © 2020. All rights reserved.