public interface HtmlConfig extends XmlConfig
Modifier and Type | Method and Description |
---|---|
default DefaultHtmlConfig |
cloneForAjax()
Clone the config for an AJAX processing
|
String |
getContentType()
Get a content type where a recommended value is
"text/html" |
CharSequence[] |
getCssLinks()
CSS links of a HTML page
|
ApiInjector |
getHeaderInjector() |
Optional<CharSequence> |
getLanguage()
Language of a HTML page
|
CharSequence |
getRawHeaderText()
Deprecated.
Use method
getHeaderInjector() |
String |
getRootElementName()
A name of root element
|
CharSequence |
getTitle()
Title is a required element by HTML 5
|
boolean |
isDocumentObjectModel()
Build a real model or a plain writer with a recommended value
false |
boolean |
isHtmlHeaderRequest()
A request to generate a minimal HTML header
|
static DefaultHtmlConfig |
of(HtmlConfig htmlConfig)
Clone config form another
|
static DefaultHtmlConfig |
ofDefault()
Create a new default config
|
static DefaultHtmlConfig |
ofElement(String rootElementName,
boolean enabled)
No HTML header is generated, no Doctype and no new lines
|
static DefaultHtmlConfig |
ofElementName(String rootElementName)
No HTML header is generated, no Doctype and no new lines
|
static DefaultHtmlConfig |
ofEmptyElement()
Create a configuration for an AJAX response.
|
getDefaultValue, getDoctype, getFirstLevel, getFormatter, getCharset, getIndentation, getNewLine, isCacheAllowed, ofDoctype
@Nonnull CharSequence getTitle()
@Nonnull CharSequence[] getCssLinks()
@Nonnull Optional<CharSequence> getLanguage()
@Nonnull String getContentType()
"text/html"
boolean isDocumentObjectModel()
false
boolean isHtmlHeaderRequest()
@Deprecated @Nullable CharSequence getRawHeaderText()
getHeaderInjector()
@Nonnull ApiInjector getHeaderInjector()
String getRootElementName()
default DefaultHtmlConfig cloneForAjax()
@Nonnull static DefaultHtmlConfig ofDefault()
@Nonnull static DefaultHtmlConfig ofElementName(@Nullable String rootElementName)
rootElementName
- Element name cannot contain special HTML characters. An undefined value ignores the creation of the root element.@Nonnull static DefaultHtmlConfig ofElement(@Nullable String rootElementName, boolean enabled)
rootElementName
- Element name cannot contain special HTML characters.enabled
- Disabled root element ignores the creation of the root element.@Nonnull static DefaultHtmlConfig ofEmptyElement()
static DefaultHtmlConfig of(@Nonnull HtmlConfig htmlConfig)
Copyright 2019-2022, Pavel Ponec