Name
JspPage
Synopsis
The JspPage
interface
must be implemented by the generated JSP page-implementation classes.
The interface defines a protocol with 3 methods; only two of them,
jspInit( )
and jspDestroy( )
,
are part of this interface as the signature of the third method:
_jspService( )
. _jspservice( )
depends on the specific protocol used and cannot be expressed in a
generic way in Java. See also HttpJspPage
.
The JspPage
interface represents the basic,
protocol-independent contract between the container and a JSP
page-implementation object. A protocol-dependent subinterface, such
as HttpJspPage
, must be implemented by the class
generated from a JSP page.
The jspInit( )
and jspDestroy( )
methods can be defined by a JSP page author.
Synopsis
Interface name: |
|
Extends: |
None |
Implemented by: |
JSP page-implementation classes. |
Methods
-
public void jspDestroy( )
This method is invoked when the JSP page-implementation instance is about to be destroyed. It can perform clean-up, such as saving the state of instance variables to permanent storage.
-
public void jspInit( )
This method is invoked when the JSP page implementation instance is initialized. It can be used to perform tasks such as restoring the state of instance variables from permanent storage.
Get JavaServer Pages, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.