PreviewOptions

Inheritance: java.lang.Object

public class PreviewOptions

Provides options to sets requirements and stream delegates for preview generation.

Constructors

Constructor Description
PreviewOptions(ICreatePageStream createPageStream) Initializes a new instance of the [PreviewOptions](../../com.groupdocs.watermark.options/previewoptions) class causing the output stream to be closed.
PreviewOptions(ICreatePageStream createPageStream, IReleasePageStream releasePageStream) Initializes a new instance of [PreviewOptions](../../com.groupdocs.watermark.options/previewoptions) class causing the output stream to be returned to the client for further use.

Methods

Method Description
getWidth() Gets the page preview width.
setWidth(int value) Sets the page preview width.
getHeight() Gets the page preview height.
setHeight(int value) Sets the page preview height.
getPageNumbers() Gets an array of page numbers to generate previews.
setPageNumbers(int[] value) Sets an array of page numbers to generate previews.
getPreviewFormat() Gets the preview image format.
setPreviewFormat(int value) Sets the preview image format.
getCreatePageStream() Gets an instance of the page stream creation class.
setCreatePageStream(ICreatePageStream value) Sets an instance of the page stream creation class.
getReleasePageStream() Gets an instance of the page preview completion class.
setReleasePageStream(IReleasePageStream value) Sets an instance of the page preview completion class.

PreviewOptions(ICreatePageStream createPageStream)

public PreviewOptions(ICreatePageStream createPageStream)

Initializes a new instance of the [PreviewOptions](../../com.groupdocs.watermark.options/previewoptions) class causing the output stream to be closed.

Parameters:

Parameter Type Description
createPageStream ICreatePageStream Creates a stream for a specific page preview.

PreviewOptions(ICreatePageStream createPageStream, IReleasePageStream releasePageStream)

public PreviewOptions(ICreatePageStream createPageStream, IReleasePageStream releasePageStream)

Initializes a new instance of [PreviewOptions](../../com.groupdocs.watermark.options/previewoptions) class causing the output stream to be returned to the client for further use.

Parameters:

Parameter Type Description
createPageStream ICreatePageStream Creates a stream for a specific page preview.
releasePageStream IReleasePageStream Notifies that the page preview generation is done and gets the output stream.

getWidth()

public final int getWidth()

Gets the page preview width.

Returns: int - The page preview width.

setWidth(int value)

public final void setWidth(int value)

Sets the page preview width.

Parameters:

Parameter Type Description
value int The page preview width.

getHeight()

public final int getHeight()

Gets the page preview height.

Returns: int - The page preview height.

setHeight(int value)

public final void setHeight(int value)

Sets the page preview height.

Parameters:

Parameter Type Description
value int The page preview height.

getPageNumbers()

public final int[] getPageNumbers()

Gets an array of page numbers to generate previews.

Returns: int[] - The array of page numbers to generate previews.

setPageNumbers(int[] value)

public final void setPageNumbers(int[] value)

Sets an array of page numbers to generate previews.

Parameters:

Parameter Type Description
value int[] The array of page numbers to generate previews.

getPreviewFormat()

public final int getPreviewFormat()

Gets the preview image format.

Returns: int - The preview image format.

setPreviewFormat(int value)

public final void setPreviewFormat(int value)

Sets the preview image format.

Parameters:

Parameter Type Description
value int The preview image format.

getCreatePageStream()

public final ICreatePageStream getCreatePageStream()

Gets an instance of the page stream creation class.

Returns: ICreatePageStream - The instance of the page stream creation class.

setCreatePageStream(ICreatePageStream value)

public final void setCreatePageStream(ICreatePageStream value)

Sets an instance of the page stream creation class.

Parameters:

Parameter Type Description
value ICreatePageStream The instance of the page stream creation class.

getReleasePageStream()

public final IReleasePageStream getReleasePageStream()

Gets an instance of the page preview completion class.

Returns: IReleasePageStream - The instance of the page preview completion delegate.

setReleasePageStream(IReleasePageStream value)

public final void setReleasePageStream(IReleasePageStream value)

Sets an instance of the page preview completion class.

Parameters:

Parameter Type Description
value IReleasePageStream The instance of the page preview completion delegate.