public class EnhancedListener extends Object
ServletContainerInitializer so that it's able to boot Weld before any application code is called, and thus injections
will succeed for all listeners, servlets, filters etc.
This listener MUST NOT be defined in web.xml because it registers itself during ServletContainerInitializer#onStartup(Set, ServletContext)
notification!
ServletRequest and HttpSession notifications are no-op in case of the Listener is registered as well.Listener| Modifier and Type | Field and Description |
|---|---|
static String |
ENHANCED_LISTENER_USED_ATTRIBUTE_NAME |
| Modifier and Type | Method and Description |
|---|---|
void |
contextDestroyed(ServletContextEvent sce) |
void |
contextInitialized(ServletContextEvent sce) |
protected org.jboss.weld.servlet.api.ServletListener |
delegate() |
void |
onStartup(Set<Class<?>> classes,
ServletContext context) |
void |
requestDestroyed(ServletRequestEvent sre) |
void |
requestInitialized(ServletRequestEvent sre) |
void |
sessionCreated(HttpSessionEvent se) |
void |
sessionDestroyed(HttpSessionEvent se) |
public static final String ENHANCED_LISTENER_USED_ATTRIBUTE_NAME
public void onStartup(Set<Class<?>> classes, ServletContext context) throws ServletException
ServletExceptionpublic void contextInitialized(ServletContextEvent sce)
public void contextDestroyed(ServletContextEvent sce)
public void requestDestroyed(ServletRequestEvent sre)
public void requestInitialized(ServletRequestEvent sre)
public void sessionCreated(HttpSessionEvent se)
public void sessionDestroyed(HttpSessionEvent se)
protected org.jboss.weld.servlet.api.ServletListener delegate()
Copyright © 2017. All rights reserved.