• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Doubt in sessions from Hanumant Deskhmukh book

 
deepti bellubbi
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am a bit confused about the answer to this question. Please advise.

Which of the following methods will be invoked on a session attribute that
implements appropriate interfaces when the session is invalidated? (Select one)
a sessionDestroyed of HttpSessionListener
b attributeRemoved of HttpSessionAttributeListener
c valueUnbound of HttpSessionBindingListener
d sessionWillPassivate of HttpSessionActivationListener

I think the answer should be "a" since the question clearly says invalidate, however the books says the answer is "C".
 
Pham Hoai Van
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The question states that: "methods will be invoked on a session attribute"
And HttpSessionBindingListener is the only interface that an attribute can implement so C is obvious.
 
deepti bellubbi
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks..confusion solved
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic