Java Servlet Programming, 2nd Edition > B. HTTP Servlet API Quick Reference > HttpSessionBindingListener |
SynopsisInterface Name: javax.servlet.http.HttpSessionBindingListener Superinterface: java.util.EventListener Immediate Subinterfaces: None Implemented By: None Availability: Servlet API 2.0 and later DescriptionAn object that implements HttpSessionBindingListener is notified via calls to valueBound( ) and valueUnbound( ) when it is bound to or unbound from an HttpSession. Among other things, this interface allows orderly cleanup session-specific resources, such as database connections. Note that in a distributed environment the valueBound( ) call may be made inside a different JVM than the valueUnbound( ) call. Interface Declarationpublic interface HttpSessionBindingListener extends java.util.EventListener { // Methods public abstract void valueBound(HttpSessionBindingEvent event); public abstract void valueUnbound(HttpSessionBindingEvent event); } MethodsvalueBound()public abstract void valueBound(HttpSessionBindingEvent event)
valueUnbound()public abstract void valueUnbound(HttpSessionBindingEvent event)
|