Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.

  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 27. JavaServer Pages > jspInit, jspDestroy, and Other Methods

jspInit, jspDestroy, and Other Methods

As mentioned before, a JSP is translated into a servlet source file and then compiled into a servlet class. A JSP page body more or less translates into the service method of Servlet. However, in a servlet you have the init and destroy methods for writing initialization and cleaning up code. How do you override these methods in a JSP page?

In a JSP page you have two similar methods:


  

You are currently reading a PREVIEW of this book.

                                                                                                                    

Get instant access to over $1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint