com.groupdocs.metadata

Interfaces

Classes

Exceptions

com.groupdocs.metadata

Class PsdFormat

    • Constructor Detail

      • PsdFormat

        public PsdFormat(String fileName)

        Initializes a new instance of the PsdFormat class.

        Parameters:
        fileName - Absolute path to the file.
      • PsdFormat

        public PsdFormat(InputStream input)

        Initializes a new instance of the PsdFormat class.

        Parameters:
        input - File stream.
    • Method Detail

      • getType

        public int getType()

        Gets document type.

        Specified by:
        getType in class FormatBase
        Returns:
        Document type.
      • hasXmp

        public final boolean hasXmp()

        Gets true if PsdFormat contains XMP data.

        Specified by:
        hasXmp in interface IXmp
        Returns:
        true if PSD file has XMP; otherwise, false.
      • getLayers

        public final PsdLayer[] getLayers()

        Gets the layers.

        Returns:
        The layers.
      • getXmpValues

        public final XmpEditableCollection getXmpValues()

        Gets XmpEditableCollection. Provides access for all XMP properties in edit mode.

        Specified by:
        getXmpValues in interface IXmp
        Returns:
        XMP values.
      • hasIptc

        public final boolean hasIptc()

        Gets a value indicating whether the PSD file contains IPTC IIM metadata.

        Specified by:
        hasIptc in interface IIptc
        Returns:
        true if the image has IPTC IIM metadata; otherwise, false.
      • hasImageResourceBlocks

        public final boolean hasImageResourceBlocks()

        Gets true if file contains Photoshop Image Resource Blocks.

        Specified by:
        hasImageResourceBlocks in interface IImageResourceBlocks
        Returns:
        true if file has image resource blocks; otherwise, false.
      • getXmpData

        public final XmpPacketWrapper getXmpData()

        Returns the XMP packet.

        Specified by:
        getXmpData in interface IXmp
        Returns:
        XmpPacketWrapper if XMP data is presented; otherwise null.
      • getXmpProperties

        public final XmpProperties getXmpProperties()

        Returns all XMP properties presented in specific format.

        Specified by:
        getXmpProperties in interface IXmp
        Returns:
        XmpProperties if XMP data is presented; otherwise null.
      • setXmpData

        public final boolean setXmpData(XmpPacketWrapper package_)

        Updates XMP packet.

        Specified by:
        setXmpData in interface IXmp
        Parameters:
        package - XMP packet wrapper.
        Returns:
        true if the XMP is successfully updated; otherwise false.
        Throws:
        ArgumentNullException - XMP packet could not be null.
      • removeXmpData

        public final void removeXmpData()

        Removes all XMP data.


        This feature is not available in trial mode.

        Specified by:
        removeXmpData in interface IXmp
      • getDublinCore

        public final DublinCoreMetadata getDublinCore()

        Gets Dublin Core metadata.

        Specified by:
        getDublinCore in interface IDublinCore
        Returns:
        DublinCoreMetadata if Dublin Core metadata is presented; otherwise null.


        This feature is not supported in trial mode.

      • cleanMetadata

        public void cleanMetadata()

        Removes (reset) metadata. In some cases(DOC, XLS, PPT, PDF) metadata could not be deleted, just be dropped to default value.


        This feature is not available in trial mode.

        Overrides:
        cleanMetadata in class ImageFormat
      • getIptc

        public final IptcCollection getIptc()

        Gets the IPTC collection.

        Specified by:
        getIptc in interface IIptc
        Returns:
        The IptcCollection instance.
      • updateIptc

        public final void updateIptc(IptcCollection collection)

        Updates IPTC metadata.

        Specified by:
        updateIptc in interface IIptc
        Parameters:
        collection - An IPTC collection.
        Throws:
        ArgumentNullException - The collection could not be null.
      • updateIptc

        public final void updateIptc(IptcDataSet dataSet)

        Updates a specific IPTC dataset.

        Specified by:
        updateIptc in interface IIptc
        Parameters:
        dataSet - An IPTC dataset.
        Throws:
        ArgumentNullException - The DataSet could not be null.
      • removeIptc

        public final void removeIptc()

        Removes IPTC metadata from the image.

        Specified by:
        removeIptc in interface IIptc