Class ServletContainerInitializerRegistrationBean<T extends javax.servlet.ServletContainerInitializer>

  • Type Parameters:
    T - Type of the actual ServletContainerInitializer implementation
    All Implemented Interfaces:
    org.springframework.boot.web.server.WebServerFactoryCustomizer<org.springframework.boot.web.servlet.server.ConfigurableServletWebServerFactory>
    Direct Known Subclasses:
    MyFacesInitializerRegistrationBean

    public class ServletContainerInitializerRegistrationBean<T extends javax.servlet.ServletContainerInitializer>
    extends Object
    implements org.springframework.boot.web.server.WebServerFactoryCustomizer<org.springframework.boot.web.servlet.server.ConfigurableServletWebServerFactory>
    RegistrationBean for ServletContainerInitializers.

    This is implemented as WebServerFactoryCustomizer so its only applied to embedded servlet-containers. When deployed as war file, the external servlet-container will handle the ServletContainerInitializer.

    • Constructor Detail

      • ServletContainerInitializerRegistrationBean

        public ServletContainerInitializerRegistrationBean​(Class<T> servletContainerInitializerClass)
    • Method Detail

      • customize

        public void customize​(org.springframework.boot.web.servlet.server.ConfigurableServletWebServerFactory factory)
        Specified by:
        customize in interface org.springframework.boot.web.server.WebServerFactoryCustomizer<T extends javax.servlet.ServletContainerInitializer>
      • performClasspathScan

        @Nullable
        protected Set<Class<?>> performClasspathScan()
      • handleScanResult

        protected void handleScanResult​(io.github.classgraph.ScanResult scanResult)
      • getServletContainerInitializerClass

        public Class<T> getServletContainerInitializerClass()
      • isUsePreparedScanResult

        public boolean isUsePreparedScanResult()
      • setUsePreparedScanResult

        public void setUsePreparedScanResult​(boolean usePreparedScanResult)