List of usage examples for org.springframework.boot.web.servlet.server AbstractServletWebServerFactory setLocaleCharsetMappings
@Override public void setLocaleCharsetMappings(Map<Locale, Charset> localeCharsetMappings)
From source file:org.springframework.boot.web.servlet.server.AbstractServletWebServerFactoryTests.java
@Test public void localeCharsetMappingsAreConfigured() throws Exception { AbstractServletWebServerFactory factory = getFactory(); Map<Locale, Charset> mappings = new HashMap<>(); mappings.put(Locale.GERMAN, Charset.forName("UTF-8")); factory.setLocaleCharsetMappings(mappings); this.webServer = factory.getWebServer(); assertThat(getCharset(Locale.GERMAN).toString()).isEqualTo("UTF-8"); assertThat(getCharset(Locale.ITALIAN)).isNull(); }