1 package com.opensymphony.webwork.lifecycle; 2 3 import javax.servlet.http.HttpSessionEvent; 4 import javax.servlet.http.HttpSessionListener; 5 6 /** 7 * The default mechanism for initializing the session and application scopes for XWork's IoC 8 * container. If for any reason you don't wish to use session-scoped objects, you can include 9 * just the {@link ApplicationLifecycleListener} rather than this class, but generally this 10 * class will be fine for almost all needs. 11 * 12 * @author Patrick Lightbody 13 * @see ApplicationLifecycleListener 14 * @see SessionLifecycleListener 15 * @see com.opensymphony.webwork.dispatcher.FilterDispatcher 16 * @since 2.2 17 */ 18 public class LifecycleListener extends ApplicationLifecycleListener implements HttpSessionListener { 19 SessionLifecycleListener session = new SessionLifecycleListener(); 20 21 public void sessionCreated(HttpSessionEvent httpSessionEvent) { 22 session.sessionCreated(httpSessionEvent); 23 } 24 25 public void sessionDestroyed(HttpSessionEvent httpSessionEvent) { 26 session.sessionDestroyed(httpSessionEvent); 27 } 28 } 29