Packages

 

com.aspose.imaging.fileformats.psd.layers.layerresources

Class LnsrResource

    • Field Detail

      • TYPE_TOOL_KEY

        public static final int TYPE_TOOL_KEY

        The type tool info key.

        See Also:
        Constant Field Values
    • Constructor Detail

      • LnsrResource

        public LnsrResource(int lnsrResourceType)

        Initializes a new instance of the LnsrResource class.

        Parameters:
        lnsrResourceType - Type of the LNSR.
        Throws:
        PsdImageArgumentException - You can not create lnsr with Unknown type value
      • LnsrResource

        public LnsrResource(byte[] bytes)

        Initializes a new instance of the LnsrResource class. With custom or unknown value

        Parameters:
        bytes - The bytes.
        Throws:
        com.aspose.ms.System.Exception - Invalid lnsr Resource value
    • Method Detail

      • getSignature

        public int getSignature()

        Gets the signature.

        Specified by:
        getSignature in class LayerResource
        Returns:
        the signature.
      • getKey

        public int getKey()

        Gets the layer resource key.

        Specified by:
        getKey in class LayerResource
        Returns:
        the layer resource key.
      • getData

        public final byte[] getData()

        Gets the raw data.

        Returns:
        the raw data.
      • getValue

        public final int getValue()

        Gets the value as LnsrResourceType if corresponding enum is described. Otherwise return Unknown

        Returns:
        the value as LnsrResourceType if corresponding enum is described.
      • getLength

        public int getLength()

        Gets the layer resource length in bytes.

        Specified by:
        getLength in class LayerResource
        Returns:
        the layer resource length in bytes.
      • getPsdVersion

        public int getPsdVersion()

        Gets the psd version.

        Specified by:
        getPsdVersion in class LayerResource
        Returns:
        the psd version.
      • save

        public void save(StreamContainer streamContainer,
                         int psdVersion)

        Saves the specified stream container.

        Specified by:
        save in class LayerResource
        Parameters:
        streamContainer - The stream container.
        psdVersion - The PSD version.