This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
If there is a HttpSessionAttributeListener declared in the DD, then the call back methods like attributeAdded() / attributeReplaced() etc will be called on this registered HttpSessionAttribute Listener.
If you want a particular object to be notified when it is added to the HttpSession, the the class of this object should implement HttpSessionBindingListener.
So, HttpSessionBindingListener is the right answer.
Hi, HttpSessionBindingListener is the correct answer to this: As specs says: "It Causes an object to be notified when it is bound to or unbound from a session. The object is notified by an HttpSessionBindingEvent object." Here bound and unbound itself mean added or removed.
Joined: Jun 06, 2008
Say you have this code:
Integer object = new Integer( 123 ); request.getSession().setAttribute( object );
Will it trigger a notification of any HttpSessionBindingListener, or a notification of HttpSessionAttributeListeners?
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com