Search in sources :

Example 1 with UrlFilenameViewController

use of org.springframework.web.servlet.mvc.UrlFilenameViewController in project cas by apereo.

the class CasManagementWebAppConfiguration method handlerMappingC.

@Bean
public SimpleUrlHandlerMapping handlerMappingC() {
    final SimpleUrlHandlerMapping mapping = new SimpleUrlHandlerMapping();
    mapping.setOrder(1);
    mapping.setAlwaysUseFullPath(true);
    mapping.setRootHandler(rootController());
    final Properties properties = new Properties();
    properties.put("/*.html", new UrlFilenameViewController());
    mapping.setMappings(properties);
    return mapping;
}
Also used : UrlFilenameViewController(org.springframework.web.servlet.mvc.UrlFilenameViewController) CasConfigurationProperties(org.apereo.cas.configuration.CasConfigurationProperties) EnableConfigurationProperties(org.springframework.boot.context.properties.EnableConfigurationProperties) ServerProperties(org.springframework.boot.autoconfigure.web.ServerProperties) Properties(java.util.Properties) SimpleUrlHandlerMapping(org.springframework.web.servlet.handler.SimpleUrlHandlerMapping) ConditionalOnMissingBean(org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean) Bean(org.springframework.context.annotation.Bean)

Aggregations

Properties (java.util.Properties)1 CasConfigurationProperties (org.apereo.cas.configuration.CasConfigurationProperties)1 ConditionalOnMissingBean (org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean)1 ServerProperties (org.springframework.boot.autoconfigure.web.ServerProperties)1 EnableConfigurationProperties (org.springframework.boot.context.properties.EnableConfigurationProperties)1 Bean (org.springframework.context.annotation.Bean)1 SimpleUrlHandlerMapping (org.springframework.web.servlet.handler.SimpleUrlHandlerMapping)1 UrlFilenameViewController (org.springframework.web.servlet.mvc.UrlFilenameViewController)1