com.groupdocs.watermark.common

Class Attachment

    • Constructor Detail

      • Attachment

        protected Attachment()

        Initializes a new instance of the Attachment class.

    • Method Detail

      • getDocumentInfo

        public final IDocumentInfo getDocumentInfo()

        Gets the information about a document stored in the attached file.

        Returns:
        The IDocumentInfo instance that contains detected information
      • getContent

        public abstract byte[] getContent()

        Gets the attached file content.

        Returns:
        The attached file content.
      • setContent

        public abstract void setContent(byte[] value)

        Sets the attached file content.

        Parameters:
        value - The attached file content.
      • createWatermarker

        public final Watermarker createWatermarker()

        Loads a content from the attached file.

        Returns:
        Instance of appropriate descendant of Contents.Content class.
      • createWatermarker

        public final Watermarker createWatermarker(LoadOptions loadOptions)

        Loads a content from the attached file.

        Parameters:
        loadOptions - Additional options to use when loading an attachment content.
        Returns:
        Instance of appropriate descendant of Contents.Content class.
      • createWatermarker

        public final Watermarker createWatermarker(LoadOptions loadOptions,
                                    WatermarkerSettings watermarkerSettings)

        Loads a content from the attached file.

        Parameters:
        loadOptions - Additional options to use when loading an attachment content.
        watermarkerSettings - Additional settings to use when working with loaded document.
        Returns:
        Instance of appropriate descendant of Contents.Content class.
      • updateContent

        public final void updateContent(Watermarker updatedVersion)

        Updates the attached content.

        Parameters:
        updatedVersion - The updated version of the content.