Name
HttpSessionBindingEvent
Synopsis
Class Name:
javax.servlet.http.HttpSessionBindingEvent
Superclass: java.util.EventObject
Immediate Subclasses: None
Interfaces Implemented: None
Availability: Servlet API 2.0 and later
Description
An HttpSessionBindingEvent
is passed to an
HttpSessionBindingListener
when the listener
object is bound to or unbound from a session.
Class Summary
public class HttpSessionBindingEvent extends java.util.EventObject { // Constructors public HttpSessionBindingEvent(HttpSession session, String name); // Instance methods public String getName(); public HttpSession getSession(); }
Constructors
HttpSessionBindingEvent()
public HttpSessionBindingEvent(HttpSession session, String name)
- Description
Constructs a new
HttpSessionBindingEvent
using the session being bound and the name that this object is being assigned (this is the same name passed to thesetAttribute( )
method ofHttpSession
). Servlet programmers should never need to use this constructor.
Instance Methods
getName()
public String getName()
- Description
Returns the name this object has been assigned within the session.
getSession()
public HttpSession getSession()
- Description
Returns the session this object is being bound to or unbound from.
Get Java Servlet Programming, 2nd 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.