Class CharacterEncodingConfiguration
java.lang.Object
com.foreach.across.modules.web.config.CharacterEncodingConfiguration
@Order(-2147483648)
@Configuration
@Import(org.springframework.boot.autoconfigure.web.servlet.HttpEncodingAutoConfiguration.class)
@ConditionalOnProperty(prefix="server.servlet.encoding",
value="enabled",
matchIfMissing=true)
public class CharacterEncodingConfiguration
extends Object
Registers a default
CharacterEncodingFilter
as the very first
filter in the chain. It is vital that this filter comes first so the encoding is applied as early as possible.
This configuration reuses HttpEncodingAutoConfiguration
and corresponding
org.springframework.boot.autoconfigure.http.HttpProperties.Encoding
.
- Author:
- Arne Vandamme
- See Also:
-
HttpEncodingAutoConfiguration
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.boot.web.servlet.FilterRegistrationBean
characterEncodingFilterRegistration
(org.springframework.web.filter.CharacterEncodingFilter characterEncodingFilter)
-
Field Details
-
FILTER_NAME
- See Also:
-
-
Constructor Details
-
CharacterEncodingConfiguration
public CharacterEncodingConfiguration()
-
-
Method Details
-
characterEncodingFilterRegistration
@Bean @ConditionalOnConfigurableServletContext public org.springframework.boot.web.servlet.FilterRegistrationBean characterEncodingFilterRegistration(org.springframework.web.filter.CharacterEncodingFilter characterEncodingFilter)
-