public class PreviewOptions extends PageOptions implements IPreviewOptions
Represents document preview options.
Constructor and Description |
---|
PreviewOptions(PageStreamFactory pageStreamFactory,
int previewMode)
Initializes a new instance of the
PreviewOptions class. |
PreviewOptions(PageStreamFactory pageStreamFactory,
int previewMode,
int[] pageNumbers)
Initializes a new instance of the
PreviewOptions class. |
PreviewOptions(PageStreamFactory pageStreamFactory,
int previewMode,
int startNumber,
int endNumber)
Initializes a new instance of the
PreviewOptions class. |
PreviewOptions(PageStreamFactory pageStreamFactory,
int previewMode,
int startNumber,
int endNumber,
int mode)
Initializes a new instance of the
PreviewOptions class. |
Modifier and Type | Method and Description |
---|---|
int |
getHeight()
Preview height.
|
int |
getMode()
Mode for preview.
|
PageStreamFactory |
getPageStreamFactory()
PageStreamFactory for create or release output page preview stream.
|
String |
getPathByPageNumber(int pageNumber,
String extension)
Gets the full file path of previewed document by page number with defined extension.
|
int |
getWidth()
Preview width.
|
void |
setHeight(int value)
Preview height.
|
void |
setWidth(int value)
Preview width.
|
void |
validate(FileType fileType)
Validates the preview options.
|
pages
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getPages
public PreviewOptions(PageStreamFactory pageStreamFactory, int previewMode)
Initializes a new instance of the PreviewOptions
class.
pageStreamFactory
- The method that instantiates stream used to write output page data.previewMode
- The preview mode of Mode
(getMode()
/setMode(int)
)public PreviewOptions(PageStreamFactory pageStreamFactory, int previewMode, int[] pageNumbers)
Initializes a new instance of the PreviewOptions
class.
pageStreamFactory
- The method that instantiates stream used to write output page data.previewMode
- The preview mode of Mode
(getMode()
/setMode(int)
)pageNumbers
- Page numbers.public PreviewOptions(PageStreamFactory pageStreamFactory, int previewMode, int startNumber, int endNumber) throws Exception
Initializes a new instance of the PreviewOptions
class.
pageStreamFactory
- The method that instantiates stream used to write output page data.previewMode
- The preview mode of Mode
(getMode()
/setMode(int)
)startNumber
- The start page number.endNumber
- The end page number.Exception
public PreviewOptions(PageStreamFactory pageStreamFactory, int previewMode, int startNumber, int endNumber, int mode) throws Exception
Initializes a new instance of the PreviewOptions
class.
pageStreamFactory
- The method that instantiates stream used to write output page data.previewMode
- The preview mode of Mode
(getMode()
/setMode(int)
)startNumber
- The start page number.endNumber
- The end page number.mode
- The range mode.Exception
public final int getHeight()
Preview height.
getHeight
in interface IPreviewOptions
public final int getMode()
Mode for preview.
getMode
in interface IPreviewOptions
public PageStreamFactory getPageStreamFactory()
PageStreamFactory for create or release output page preview stream.
getPageStreamFactory
in interface IPreviewOptions
public final String getPathByPageNumber(int pageNumber, String extension)
Gets the full file path of previewed document by page number with defined extension.
getPathByPageNumber
in interface IPreviewOptions
pageNumber
- Page number of preview.extension
- Extension of file.public final int getWidth()
Preview width.
getWidth
in interface IPreviewOptions
public final void setHeight(int value)
Preview height.
setHeight
in interface IPreviewOptions
public final void setWidth(int value)
Preview width.
setWidth
in interface IPreviewOptions
public final void validate(FileType fileType) throws Exception
Validates the preview options.
validate
in interface IPreviewOptions
fileType
- The file type.Exception