public interface ConfigurableServletWebServerFactory extends ConfigurableWebServerFactory, ServletWebServerFactory, WebListenerRegistry
ServletWebServerFactory
.ServletWebServerFactory
,
WebServerFactoryCustomizer
Modifier and Type | Method and Description |
---|---|
void |
addCookieSameSiteSuppliers(CookieSameSiteSupplier... cookieSameSiteSuppliers)
Add
CookieSameSiteSuppliers to those that should be
used to obtain the Cookie.SameSite attribute of any added cookie. |
void |
addInitializers(ServletContextInitializer... initializers)
Add
ServletContextInitializer s to those that should be applied in addition
to ServletWebServerFactory.getWebServer(ServletContextInitializer...)
parameters. |
void |
setContextPath(String contextPath)
Sets the context path for the web server.
|
void |
setCookieSameSiteSuppliers(List<? extends CookieSameSiteSupplier> cookieSameSiteSuppliers)
Sets
CookieSameSiteSuppliers that should be used to
obtain the Cookie.SameSite attribute of any added cookie. |
void |
setDisplayName(String displayName)
Sets the display name of the application deployed in the web server.
|
void |
setDocumentRoot(File documentRoot)
Sets the document root directory which will be used by the web context to serve
static files.
|
void |
setInitializers(List<? extends ServletContextInitializer> initializers)
Sets
ServletContextInitializer that should be applied in addition to
ServletWebServerFactory.getWebServer(ServletContextInitializer...)
parameters. |
void |
setInitParameters(Map<String,String> initParameters)
Sets the init parameters that are applied to the container's
ServletContext . |
void |
setJsp(Jsp jsp)
Sets the configuration that will be applied to the server's JSP servlet.
|
void |
setLocaleCharsetMappings(Map<Locale,Charset> localeCharsetMappings)
Sets the Locale to Charset mappings.
|
void |
setMimeMappings(MimeMappings mimeMappings)
Sets the mime-type mappings.
|
void |
setRegisterDefaultServlet(boolean registerDefaultServlet)
Set if the DefaultServlet should be registered.
|
void |
setSession(Session session)
Sets the configuration that will be applied to the container's HTTP session
support.
|
setAddress, setCompression, setErrorPages, setHttp2, setPort, setServerHeader, setShutdown, setSsl, setSslStoreProvider
addErrorPages
getWebServer
addWebListeners
void setContextPath(String contextPath)
contextPath
- the contextPath to setvoid setDisplayName(String displayName)
displayName
- the displayName to setvoid setSession(Session session)
session
- the session configurationvoid setRegisterDefaultServlet(boolean registerDefaultServlet)
false
since
2.4.registerDefaultServlet
- if the default servlet should be registeredvoid setMimeMappings(MimeMappings mimeMappings)
mimeMappings
- the mime type mappings (defaults to
MimeMappings.DEFAULT
)void setDocumentRoot(File documentRoot)
documentRoot
- the document root or null
if not requiredvoid setInitializers(List<? extends ServletContextInitializer> initializers)
ServletContextInitializer
that should be applied in addition to
ServletWebServerFactory.getWebServer(ServletContextInitializer...)
parameters. This method will replace any previously set or added initializers.initializers
- the initializers to setaddInitializers(org.springframework.boot.web.servlet.ServletContextInitializer...)
void addInitializers(ServletContextInitializer... initializers)
ServletContextInitializer
s to those that should be applied in addition
to ServletWebServerFactory.getWebServer(ServletContextInitializer...)
parameters.initializers
- the initializers to addsetInitializers(java.util.List<? extends org.springframework.boot.web.servlet.ServletContextInitializer>)
void setJsp(Jsp jsp)
jsp
- the JSP servlet configurationvoid setLocaleCharsetMappings(Map<Locale,Charset> localeCharsetMappings)
localeCharsetMappings
- the Locale to Charset mappingsvoid setInitParameters(Map<String,String> initParameters)
ServletContext
.initParameters
- the init parametersvoid setCookieSameSiteSuppliers(List<? extends CookieSameSiteSupplier> cookieSameSiteSuppliers)
CookieSameSiteSuppliers
that should be used to
obtain the Cookie.SameSite
attribute of any added cookie. This method will replace
any previously set or added suppliers.cookieSameSiteSuppliers
- the suppliers to addaddCookieSameSiteSuppliers(org.springframework.boot.web.servlet.server.CookieSameSiteSupplier...)
void addCookieSameSiteSuppliers(CookieSameSiteSupplier... cookieSameSiteSuppliers)
CookieSameSiteSuppliers
to those that should be
used to obtain the Cookie.SameSite
attribute of any added cookie.cookieSameSiteSuppliers
- the suppliers to addsetCookieSameSiteSuppliers(java.util.List<? extends org.springframework.boot.web.servlet.server.CookieSameSiteSupplier>)