Advertisement



< Prev
Next >



Listener Interfaces



Using the feature of Listener introduced in Servlet, we can make a web application which responds to events taking place in a web application. These events can be of request, session or application level scope. On the basis of these different types of events, there are several Listener interfaces defined under javax.servlet package.




Listener Interfaces


Some of the most important Listener interfaces are -




ServletContextListener


Doing so, we can initialize the objects in servlet context of the web application and destroy these objects when servlet context of a web application is going to be destroyed.




ServletContextAttributeListener







HttpSessionListener


Doing so, we can initialize the objects in HttpSession of the web application and destroy these objects when HttpSession of a web application is going to be invalidated.


Advertisement




HttpSessionAttributeListener







HttpSessionBindingListener







ServletRequestListener







ServletRequestAttributeListener







Please share this article -




< Prev
Next >
< User Authentication Filter
Servlet Request Listener >



Advertisement

Please Subscribe

Please subscribe to our social media channels for daily updates.


Decodejava Facebook Page  DecodeJava Twitter Page Decodejava Google+ Page




Advertisement

Notifications



Please check our latest addition

PYTHON


Advertisement