public class HtmlViewOptions extends ViewOptions
Provides options for rendering documents into HTML format.
Modifier and Type | Method and Description |
---|---|
static HtmlViewOptions |
forEmbeddedResources()
Initializes new instance of
HtmlViewOptions class. |
static HtmlViewOptions |
forEmbeddedResources(CreatePageStream createPageStream)
Initializes new instance of
HtmlViewOptions class for rendering into HTML with embedded resources. |
static HtmlViewOptions |
forEmbeddedResources(CreatePageStream createPageStream,
ReleasePageStream releasePageStream)
Initializes new instance of
HtmlViewOptions class for rendering into HTML with embedded resources. |
static HtmlViewOptions |
forEmbeddedResources(PageStreamFactory pageStreamFactory)
Initializes new instance of
HtmlViewOptions class for rendering into HTML with embedded resources. |
static HtmlViewOptions |
forEmbeddedResources(String filePathFormat)
Initializes new instance of
HtmlViewOptions class. |
static HtmlViewOptions |
forExternalResources()
Initializes new instance of
HtmlViewOptions class. |
static HtmlViewOptions |
forExternalResources(CreatePageStream createPageStream,
CreateResourceStream createResourceStream,
CreateResourceUrl createResourceUrl)
Initializes new instance of
HtmlViewOptions class for rendering into HTML with external resources. |
static HtmlViewOptions |
forExternalResources(CreatePageStream createPageStream,
CreateResourceStream createResourceStream,
CreateResourceUrl createResourceUrl,
ReleasePageStream releasePageStream,
ReleaseResourceStream releaseResourceStream) |
static HtmlViewOptions |
forExternalResources(PageStreamFactory pageStreamFactory,
ResourceStreamFactory resourceStreamFactory)
Initializes new instance of
HtmlViewOptions class for rendering into HTML with external resources. |
static HtmlViewOptions |
forExternalResources(String filePathFormat,
String resourceFilePathFormat,
String resourceUrlFormat)
Initializes new instance of
HtmlViewOptions class. |
List<String> |
getFontsToExclude()
The list of font names, to exclude from HTML document.
|
int |
getImageHeight()
The height of an output image in pixels.
|
int |
getImageMaxHeight()
Max height of an output image in pixels.
|
int |
getImageMaxWidth()
Max width of an output image in pixels.
|
int |
getImageWidth()
The width of the output image in pixels.
|
boolean |
isEmbedResources() |
boolean |
isExcludeFonts()
When enabled prevents adding any fonts into HTML document.
|
boolean |
isExternalResources() |
boolean |
isForPrinting()
Indicates whether to optimize output HTML for printing.
|
boolean |
isMinify()
Enables HTML content and HTML resources minification.
|
boolean |
isRenderResponsive()
Enables responsive rendering;
Responsive web-pages render well on a devices with different screen size.
|
boolean |
isRenderToSinglePage() |
void |
setExcludeFonts(boolean value)
When enabled prevents adding any fonts into HTML document.
|
void |
setFontsToExclude(List<String> value)
The list of font names, to exclude from HTML document.
|
void |
setForPrinting(boolean value)
Indicates whether to optimize output HTML for printing.
|
void |
setImageHeight(int imageHeight)
The height of an output image in pixels.
|
void |
setImageMaxHeight(int imageMaxHeight)
Max height of an output image in pixels.
|
void |
setImageMaxWidth(int imageMaxWidth)
Max width of an output image in pixels.
|
void |
setImageWidth(int imageWidth)
The width of the output image in pixels.
|
void |
setMinify(boolean value)
Enables HTML content and HTML resources minification.
|
void |
setRenderResponsive(boolean value)
Enables responsive rendering;
Responsive web-pages render well on a devices with different screen size.
|
void |
setRenderToSinglePage(boolean renderSinglePage)
Enables HTML content will be rendered to single page
|
getPageRotations, getWatermark, rotatePage, setWatermark
getArchiveOptions, getCadOptions, getDefaultFontName, getEmailOptions, getMailStorageOptions, getOutlookOptions, getPdfOptions, getProjectManagementOptions, getSpreadsheetOptions, getTextOptions, getVisioRenderingOptions, getWordProcessingOptions, isForHtmlView, isForJpgView, isForPngView, isForSinglePage, isRenderComments, isRenderHiddenPages, isRenderNotes, setArchiveOptions, setCadOptions, setDefaultFontName, setEmailOptions, setForHtmlView, setForJpgView, setForPngView, setForSinglePage, setMailStorageOptions, setOutlookOptions, setPdfOptions, setProjectManagementOptions, setRenderComments, setRenderHiddenPages, setRenderNotes, setSpreadsheetOptions, setTextOptions, setVisioRenderingOptions, setWordProcessingOptions
public static HtmlViewOptions forEmbeddedResources()
Initializes new instance of HtmlViewOptions
class.
public static HtmlViewOptions forEmbeddedResources(CreatePageStream createPageStream)
HtmlViewOptions
class for rendering into HTML with embedded resources.createPageStream
- The method that instantiates stream used to write output page data.HtmlViewOptions
class for rendering into HTML with embedded resources.public static HtmlViewOptions forEmbeddedResources(CreatePageStream createPageStream, ReleasePageStream releasePageStream)
HtmlViewOptions
class for rendering into HTML with embedded resources.createPageStream
- The method that instantiates stream used to write output page data.releasePageStream
- The method that releases stream created by method assigned to delegate that passed to createPageStream parameter.HtmlViewOptions
class for rendering into HTML with embedded resources.public static HtmlViewOptions forEmbeddedResources(PageStreamFactory pageStreamFactory)
Initializes new instance of HtmlViewOptions
class for rendering into HTML with embedded resources.
pageStreamFactory
- The factory which implements methods for creating and releasing output page stream.HtmlViewOptions
class for rendering into HTML with embedded resources.IllegalArgumentException
- Thrown when pageStreamFactory
is null.public static HtmlViewOptions forEmbeddedResources(String filePathFormat)
Initializes new instance of HtmlViewOptions
class.
filePathFormat
- The file path format e.g. 'page_{0}.html'.IllegalArgumentException
- Thrown when filePathFormat
is null or empty.public static HtmlViewOptions forExternalResources()
Initializes new instance of HtmlViewOptions
class.
HtmlViewOptions
public static HtmlViewOptions forExternalResources(CreatePageStream createPageStream, CreateResourceStream createResourceStream, CreateResourceUrl createResourceUrl)
HtmlViewOptions
class for rendering into HTML with external resources.createPageStream
- The method that instantiates stream used to write output page data.createResourceStream
- The method that releases stream created by createPageStream method.createResourceUrl
- The method that creates URL for HTML resource.HtmlViewOptions
class for rendering into HTML with external resources.public static HtmlViewOptions forExternalResources(CreatePageStream createPageStream, CreateResourceStream createResourceStream, CreateResourceUrl createResourceUrl, ReleasePageStream releasePageStream, ReleaseResourceStream releaseResourceStream)
public static HtmlViewOptions forExternalResources(PageStreamFactory pageStreamFactory, ResourceStreamFactory resourceStreamFactory)
Initializes new instance of HtmlViewOptions
class for rendering into HTML with external resources.
pageStreamFactory
- The factory which implements methods for creating and releasing output page stream.resourceStreamFactory
- The factory which implements methods that are required for creating resource URL, instantiating and releasing output HTML resource stream.HtmlViewOptions
class for rendering into HTML with external resources.IllegalArgumentException
- Thrown when pageStreamFactory
is null.IllegalArgumentException
- Thrown when resourceStreamFactory
is null.public static HtmlViewOptions forExternalResources(String filePathFormat, String resourceFilePathFormat, String resourceUrlFormat)
Initializes new instance of HtmlViewOptions
class.
filePathFormat
- The file path format e.g. 'page_{0}.html'.resourceFilePathFormat
- The resource file path format e.g. 'page_{0}/resource_{1}'.resourceUrlFormat
- The resource URL format e.g. 'page_{0}/resource_{1}'.IllegalArgumentException
- Thrown when filePathFormat
is null or empty.IllegalArgumentException
- Thrown when resourceFilePathFormat
is null or empty.IllegalArgumentException
- Thrown when resourceUrlFormat
is null or empty.public final List<String> getFontsToExclude()
The list of font names, to exclude from HTML document.
ExcludeFonts
(isExcludeFonts()
/setExcludeFonts(boolean)
)
options is disabled.
public int getImageHeight()
public int getImageMaxHeight()
public int getImageMaxWidth()
public int getImageWidth()
public final boolean isEmbedResources()
public final boolean isExcludeFonts()
When enabled prevents adding any fonts into HTML document.
public final boolean isExternalResources()
public final boolean isForPrinting()
Indicates whether to optimize output HTML for printing.
public final boolean isMinify()
Enables HTML content and HTML resources minification.
public final boolean isRenderResponsive()
Enables responsive rendering; Responsive web-pages render well on a devices with different screen size.
public boolean isRenderToSinglePage()
public final void setExcludeFonts(boolean value)
When enabled prevents adding any fonts into HTML document.
public final void setFontsToExclude(List<String> value)
The list of font names, to exclude from HTML document.
ExcludeFonts
(isExcludeFonts()
/setExcludeFonts(boolean)
)
options is disabled.
public final void setForPrinting(boolean value)
Indicates whether to optimize output HTML for printing.
public void setImageHeight(int imageHeight)
public void setImageMaxHeight(int imageMaxHeight)
public void setImageMaxWidth(int imageMaxWidth)
public void setImageWidth(int imageWidth)
public final void setMinify(boolean value)
Enables HTML content and HTML resources minification.
public final void setRenderResponsive(boolean value)
Enables responsive rendering; Responsive web-pages render well on a devices with different screen size.
public void setRenderToSinglePage(boolean renderSinglePage)