Class WebConfigurer

java.lang.Object
org.powertac.visualizer.config.WebConfigurer
All Implemented Interfaces:
org.springframework.boot.web.server.WebServerFactoryCustomizer<org.springframework.boot.web.server.WebServerFactory>, org.springframework.boot.web.servlet.ServletContextInitializer

@Configuration
public class WebConfigurer
extends Object
implements org.springframework.boot.web.servlet.ServletContextInitializer, org.springframework.boot.web.server.WebServerFactoryCustomizer<org.springframework.boot.web.server.WebServerFactory>
Configuration of web application with Servlet 3.0 APIs.
  • Constructor Summary

    Constructors 
    Constructor Description
    WebConfigurer​(org.springframework.core.env.Environment env, io.github.jhipster.config.JHipsterProperties jHipsterProperties)  
  • Method Summary

    Modifier and Type Method Description
    org.springframework.web.filter.CorsFilter corsFilter()  
    void customize​(org.springframework.boot.web.server.WebServerFactory server)
    Customize the Servlet engine: Mime types, the document root, the cache.
    void onStartup​(javax.servlet.ServletContext servletContext)  
    void setMetricRegistry​(com.codahale.metrics.MetricRegistry metricRegistry)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • WebConfigurer

      public WebConfigurer​(org.springframework.core.env.Environment env, io.github.jhipster.config.JHipsterProperties jHipsterProperties)
  • Method Details

    • onStartup

      public void onStartup​(javax.servlet.ServletContext servletContext) throws javax.servlet.ServletException
      Specified by:
      onStartup in interface org.springframework.boot.web.servlet.ServletContextInitializer
      Throws:
      javax.servlet.ServletException
    • customize

      public void customize​(org.springframework.boot.web.server.WebServerFactory server)
      Customize the Servlet engine: Mime types, the document root, the cache.
      Specified by:
      customize in interface org.springframework.boot.web.server.WebServerFactoryCustomizer<org.springframework.boot.web.server.WebServerFactory>
    • corsFilter

      @Bean public org.springframework.web.filter.CorsFilter corsFilter()
    • setMetricRegistry

      @Autowired(required=false) public void setMetricRegistry​(com.codahale.metrics.MetricRegistry metricRegistry)