1.

How To Override The Lifecycle Methods Of Jsp?

Answer»

Lifecycle METHOD jspService() cannot be OVERRIDDEN within a JSP page however methods like jspInit() and jspDestroy() can be overridden within a JSP page. Method jspInit() is used for ALLOCATING resource while method jspDestroy() is used to free allocated resource. But it should be kept in mind that during the lifecycle of a Java SERVER Page both the method jsplnit() and jspDestroy() is EXECUTED once and are declared as JSP declarations.

Lifecycle method jspService() cannot be overridden within a JSP page however methods like jspInit() and jspDestroy() can be overridden within a JSP page. Method jspInit() is used for allocating resource while method jspDestroy() is used to free allocated resource. But it should be kept in mind that during the lifecycle of a Java Server Page both the method jsplnit() and jspDestroy() is executed once and are declared as JSP declarations.



Discussion

No Comment Found