Name

HttpSessionBindingEvent

Synopsis

An HttpSessionBindingEvent is passed to the appropriate method of an HttpSessionBindingListener when an object is bound to or unbound from an HttpSession. The getName() method returns the name to which the bound object has been assigned, and the getSession() method provides a reference to the session the object is being bound to.

                  
public class HttpSessionBindingEvent extends HttpSessionEvent {
// Public Constructors
   public HttpSessionBindingEvent(HttpSession session, 
        String name);  
   public HttpSessionBindingEvent(HttpSession session,           // 2.3
        String name, Object value);  
// Public Instance Methods
   public String getName();  
   public Object getValue();                                     // 2.3
                  // Public Methods Overriding HttpSessionEvent
   public HttpSession getSession();  
}

Passed To

HttpSessionAttributeListener.{attributeAdded(), attributeRemoved(), attributeReplaced()}, HttpSessionBindingListener.{valueBound(), valueUnbound()}

Get Java Enterprise in a Nutshell, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.