Package net.webpdf.wsclient.openapi
Class OperationConverterHtml
- java.lang.Object
-
- net.webpdf.wsclient.openapi.OperationConverterHtml
-
public class OperationConverterHtml extends Object
These settings are only used for HTML (e.g. websites) and HTML-based documents (e.g. e-mails).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classOperationConverterHtml.ImageModeEnumThis defines how downloaded images are inserted into the HTML content (with reference to the `<downloadImages>` parameter).
-
Field Summary
Fields Modifier and Type Field Description static StringJSON_PROPERTY_ADJUST_FONTSstatic StringJSON_PROPERTY_BASE_U_R_Lstatic StringJSON_PROPERTY_DOWNLOAD_IMAGESstatic StringJSON_PROPERTY_ERROR_REPORTstatic StringJSON_PROPERTY_IMAGE_MODEstatic StringJSON_PROPERTY_PREFER_C_S_S_PAGE_SIZEstatic StringJSON_PROPERTY_TEMPLATE_DATAstatic StringJSON_PROPERTY_USE_AS_TEMPLATEstatic StringJSON_PROPERTY_USE_BACKGROUND
-
Constructor Summary
Constructors Constructor Description OperationConverterHtml()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OperationConverterHtmladjustFonts(Boolean adjustFonts)OperationConverterHtmlbaseURL(String baseURL)OperationConverterHtmldownloadImages(Boolean downloadImages)booleanequals(Object o)OperationConverterHtmlerrorReport(OperationConverterHtmlErrorReport errorReport)@Nullable BooleangetAdjustFonts()If \"true\", then the font specifications \"Arial\", \"Helvetica\" and \"Sans-Serif\" in HTML documents and e-mails (which are based on HTML) are automatically replaced by the \"Arial Unicode MS\" font.@Nullable StringgetBaseURL()Used to define the URL that will be the base for all URLs in the HTML document that are not defined as absolute URLs.@Nullable BooleangetDownloadImages()If \"true\", then externally referenced images of the HTML document are downloaded and inserted into the document.@Nullable OperationConverterHtmlErrorReportgetErrorReport()Get errorReport@Nullable OperationConverterHtml.ImageModeEnumgetImageMode()This defines how downloaded images are inserted into the HTML content (with reference to the `<downloadImages>` parameter).@Nullable BooleangetPreferCSSPageSize()If \"true\", then the page size and margins are preferentially used from the CSS.@Nullable OperationTemplateDatagetTemplateData()Get templateData@Nullable BooleangetUseAsTemplate()If \"true\", the HTML document will be interpreted as a template, i.e., the system will search for variables in the HTML and replace them with the data passed in \"templateData\".@Nullable BooleangetUseBackground()If \"true\", the background defined in the HTML document will be output in the PDF document as well.inthashCode()OperationConverterHtmlimageMode(OperationConverterHtml.ImageModeEnum imageMode)OperationConverterHtmlpreferCSSPageSize(Boolean preferCSSPageSize)voidsetAdjustFonts(Boolean adjustFonts)voidsetBaseURL(String baseURL)voidsetDownloadImages(Boolean downloadImages)voidsetErrorReport(OperationConverterHtmlErrorReport errorReport)voidsetImageMode(OperationConverterHtml.ImageModeEnum imageMode)voidsetPreferCSSPageSize(Boolean preferCSSPageSize)voidsetTemplateData(OperationTemplateData templateData)voidsetUseAsTemplate(Boolean useAsTemplate)voidsetUseBackground(Boolean useBackground)OperationConverterHtmltemplateData(OperationTemplateData templateData)StringtoString()OperationConverterHtmluseAsTemplate(Boolean useAsTemplate)OperationConverterHtmluseBackground(Boolean useBackground)
-
-
-
Field Detail
-
JSON_PROPERTY_ADJUST_FONTS
public static final String JSON_PROPERTY_ADJUST_FONTS
- See Also:
- Constant Field Values
-
JSON_PROPERTY_BASE_U_R_L
public static final String JSON_PROPERTY_BASE_U_R_L
- See Also:
- Constant Field Values
-
JSON_PROPERTY_DOWNLOAD_IMAGES
public static final String JSON_PROPERTY_DOWNLOAD_IMAGES
- See Also:
- Constant Field Values
-
JSON_PROPERTY_ERROR_REPORT
public static final String JSON_PROPERTY_ERROR_REPORT
- See Also:
- Constant Field Values
-
JSON_PROPERTY_IMAGE_MODE
public static final String JSON_PROPERTY_IMAGE_MODE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_PREFER_C_S_S_PAGE_SIZE
public static final String JSON_PROPERTY_PREFER_C_S_S_PAGE_SIZE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_TEMPLATE_DATA
public static final String JSON_PROPERTY_TEMPLATE_DATA
- See Also:
- Constant Field Values
-
JSON_PROPERTY_USE_AS_TEMPLATE
public static final String JSON_PROPERTY_USE_AS_TEMPLATE
- See Also:
- Constant Field Values
-
JSON_PROPERTY_USE_BACKGROUND
public static final String JSON_PROPERTY_USE_BACKGROUND
- See Also:
- Constant Field Values
-
-
Method Detail
-
adjustFonts
public OperationConverterHtml adjustFonts(Boolean adjustFonts)
-
getAdjustFonts
@Nullable public @Nullable Boolean getAdjustFonts()
If \"true\", then the font specifications \"Arial\", \"Helvetica\" and \"Sans-Serif\" in HTML documents and e-mails (which are based on HTML) are automatically replaced by the \"Arial Unicode MS\" font. The improves the appearance of the typeface in the PDF result.- Returns:
- adjustFonts
-
setAdjustFonts
public void setAdjustFonts(Boolean adjustFonts)
-
baseURL
public OperationConverterHtml baseURL(String baseURL)
-
getBaseURL
@Nullable public @Nullable String getBaseURL()
Used to define the URL that will be the base for all URLs in the HTML document that are not defined as absolute URLs. The URL must be absolute and contain a scheme (e.g. 'http' or 'https'); the scheme 'file' is not allowed.- Returns:
- baseURL
-
setBaseURL
public void setBaseURL(String baseURL)
-
downloadImages
public OperationConverterHtml downloadImages(Boolean downloadImages)
-
getDownloadImages
@Nullable public @Nullable Boolean getDownloadImages()
If \"true\", then externally referenced images of the HTML document are downloaded and inserted into the document. If false, the images are not downloaded and the external references to the image are removed, leaving already embedded images intact.- Returns:
- downloadImages
-
setDownloadImages
public void setDownloadImages(Boolean downloadImages)
-
errorReport
public OperationConverterHtml errorReport(OperationConverterHtmlErrorReport errorReport)
-
getErrorReport
@Nullable public @Nullable OperationConverterHtmlErrorReport getErrorReport()
Get errorReport- Returns:
- errorReport
-
setErrorReport
public void setErrorReport(OperationConverterHtmlErrorReport errorReport)
-
imageMode
public OperationConverterHtml imageMode(OperationConverterHtml.ImageModeEnum imageMode)
-
getImageMode
@Nullable public @Nullable OperationConverterHtml.ImageModeEnum getImageMode()
This defines how downloaded images are inserted into the HTML content (with reference to the `<downloadImages>` parameter). When referencing large images in the HTML content, it is recommended to use `<file>` to reduce the size of the HTML file and speed up the rendering of the HTML. * base64 = embed images as BASE64 content * file = embed images as file links to local temporary files- Returns:
- imageMode
-
setImageMode
public void setImageMode(OperationConverterHtml.ImageModeEnum imageMode)
-
preferCSSPageSize
public OperationConverterHtml preferCSSPageSize(Boolean preferCSSPageSize)
-
getPreferCSSPageSize
@Nullable public @Nullable Boolean getPreferCSSPageSize()
If \"true\", then the page size and margins are preferentially used from the CSS. Otherwise, the sizes from the passed page parameter are used. The values can also be only partially overwritten, so that e.g. the page size is determined by the parameter values and the page margins are defined in the CSS.- Returns:
- preferCSSPageSize
-
setPreferCSSPageSize
public void setPreferCSSPageSize(Boolean preferCSSPageSize)
-
templateData
public OperationConverterHtml templateData(OperationTemplateData templateData)
-
getTemplateData
@Nullable public @Nullable OperationTemplateData getTemplateData()
Get templateData- Returns:
- templateData
-
setTemplateData
public void setTemplateData(OperationTemplateData templateData)
-
useAsTemplate
public OperationConverterHtml useAsTemplate(Boolean useAsTemplate)
-
getUseAsTemplate
@Nullable public @Nullable Boolean getUseAsTemplate()
If \"true\", the HTML document will be interpreted as a template, i.e., the system will search for variables in the HTML and replace them with the data passed in \"templateData\". The document will not be converted to HTML format until after this step is completed. This means that by using the HTML document as a template together with passed data, you can obtain a dynamically generated PDF document.- Returns:
- useAsTemplate
-
setUseAsTemplate
public void setUseAsTemplate(Boolean useAsTemplate)
-
useBackground
public OperationConverterHtml useBackground(Boolean useBackground)
-
getUseBackground
@Nullable public @Nullable Boolean getUseBackground()
If \"true\", the background defined in the HTML document will be output in the PDF document as well. If \"false\", the background will be hidden.- Returns:
- useBackground
-
setUseBackground
public void setUseBackground(Boolean useBackground)
-
-