Take a look at this:
public class ApplicationContextListener implements ServletContextListener
{
private ServletContext servletContext = null;
public void contextInitialized(ServletContextEvent arg0) {
servletContext = arg0.getServletContext();
ApplicationBean applicationBean = new ApplicationBean();
servletContext.setAttribute("applicationBean",
applicationBean);
}
public void contextDestroyed(ServletContextEvent arg0) {
servletContext = arg0.getServletContext();
servletContext.removeAttribute("applicationBean");
}
}
HTH,
Glenn
"Nils Liebelt" <[EMAIL PROTECTED]>
10/05/2005 10:41 AM
Please respond to
"Struts Users Mailing List" <[email protected]>
To
"'Struts Users Mailing List'" <[email protected]>
cc
<[EMAIL PROTECTED]>
Subject
Global scope
Classification
Hi everybody,
Is there a global scope where you could dump e.g. a list of all users or
stuff that is needed in global context. Or just adding to each single
session?
GreetZ
Nils