com.groupdocs.parser.options

Class PreviewOptions



  • public class PreviewOptions
    extends Object
    Provides options to sets requirements and stream delegates for preview generation.
    • Constructor Detail

      • PreviewOptions

        public PreviewOptions(ICreatePageStream createPageStream)
        Initializes a new instance of the PreviewOptions class causing the output stream to be closed.
        Parameters:
        createPageStream - Creates a stream for a specific page preview.
      • PreviewOptions

        public PreviewOptions(ICreatePageStream createPageStream,
                      IReleasePageStream releasePageStream)
        Initializes a new instance of PreviewOptions class causing the output stream to be returned to the client for further use.
        Parameters:
        createPageStream - Creates a stream for a specific page preview
        releasePageStream - Notifies that the page preview generation is done and gets the output stream.
    • Method Detail

      • getWidth

        public int getWidth()
        Gets the page preview width.
        Returns:
        The page width.
      • setWidth

        public void setWidth(int width)
        Sets the page preview width.
        Parameters:
        width - The page width.
      • getHeight

        public int getHeight()
        Gets the page preview height.
        Returns:
        The page height.
      • setHeight

        public void setHeight(int height)
        Sets the page preview height.
        Parameters:
        height - The page height.
      • getPageNumbers

        public int[] getPageNumbers()
        Gets an array of page numbers to generate previews.
        Returns:
        A collection of page numbers.
      • setPageNumbers

        public void setPageNumbers(int[] pageNumbers)
        Sets an array of page numbers to generate previews.
        Parameters:
        pageNumbers - A collection of page numbers.
      • setPreviewFormat

        public void setPreviewFormat(PreviewFormats previewFormat)
        Sets the preview image format.
        Parameters:
        previewFormat - The preview format.
      • getCreatePageStream

        public ICreatePageStream getCreatePageStream()
        Gets an instance of the page stream creation delegate.
        Returns:
        The page stream creation delegate.
      • setCreatePageStream

        public void setCreatePageStream(ICreatePageStream createPageStream)
        Sets an instance of the page stream creation delegate.
        Parameters:
        createPageStream - The page stream creation delegate.
      • getReleasePageStream

        public IReleasePageStream getReleasePageStream()
        Gets an instance of the page preview completion delegate.
        Returns:
        The page preview completion delegate.
      • setReleasePageStream

        public void setReleasePageStream(IReleasePageStream releasePageStream)
        Sets an instance of the page preview completion delegate.
        Parameters:
        releasePageStream - The page preview completion delegate.