java.lang.Object
com.aoapps.encoding.servlet.DoctypeEE
Manages
Doctype in a Servlet environment.- Author:
- AO Industries, Inc.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringContext init parameter that may be used to configure the default doctype within an application. -
Method Summary
Modifier and TypeMethodDescriptionstatic Doctypeget(ServletContext servletContext, ServletRequest request) Gets the doctype in effect for the request, or the default when not yet set.static DoctypegetDefault(ServletContext servletContext) Determines the default doctype by first checking for context-param ofDEFAULT_INIT_PARAM, then usingDoctype.DEFAULTwhen unspecified or "default".static Doctypereplace(ServletRequest request, Doctype doctype) Replaces the doctype in effect for the request.static voidset(ServletRequest request, Doctype doctype) Registers the doctype in effect for the request.
-
Field Details
-
DEFAULT_INIT_PARAM
Context init parameter that may be used to configure the default doctype within an application.
-
-
Method Details
-
getDefault
Determines the default doctype by first checking for context-param ofDEFAULT_INIT_PARAM, then usingDoctype.DEFAULTwhen unspecified or "default". -
set
Registers the doctype in effect for the request. -
replace
Replaces the doctype in effect for the request.- Returns:
- The previous attribute value, if any
-
get
Gets the doctype in effect for the request, or the default when not yet set.Once the default is resolved, sets the request attribute.
-
