CodesJava

Easy learning with example program codes

what are jsp lifecycle methods?


1. jspInit(): It is used to perform initialization process. This method is called by the web container only once when first request comes.
Syntax:public void jspInit()
2. _jspService(): This method is called by web container every time when a request is come for the jsp.
Syntax: public void _jspService() throws ServletException,IOException
Note: In this method underscore (_) represents that implementation of this method is provided by auto generated servlet and it can’t be overridden by developer.
3. jspDestroy(): It is used to perform cleanup process before destroying jsp page. This method is called by the web container only once.
Syntax: public void jspDestroy()

Related topics

Posted in JSP   


Copyright © 2018 CodesJava DMCA.com Protection Status SiteMap