Total members 9952 | Gratitudes |It is currently Sat Feb 11, 2012 2:02 pm Login / Join Codemiles


All times are UTC [ DST ]




Post new topic Reply to topic  Quick reply  [ 1 post ] 
Author Question
 Question subject: Explain the life-cycle mehtods in JSP
PostPosted: Fri Nov 07, 2008 12:51 pm 
Offline
Newbie
User avatar

Joined: Wed Mar 28, 2007 7:31 pm
Posts: 14
Has thanked: 0 time
Have thanks: 0 time

Q: Explain the life-cycle mehtods in JSP?


A: THe generated servlet class for a JSP page implements the HttpJspPage interface of the javax.servlet.jsp package. Hte HttpJspPage interface extends the JspPage interface which inturn extends the Servlet interface of the javax.servlet package. the generated servlet class thus implements all the methods of the these three interfaces. The JspPage interface declares only two mehtods - jspInit() and jspDestroy() that must be implemented by all JSP pages regardless of the client-server protocol. However the JSP specification has provided the HttpJspPage interfaec specifically for the JSp pages serving HTTP requests. This interface declares one method _jspService().
The jspInit()- The container calls the jspInit() to initialize te servlet instance.It is called before any other method, and is called only once for a servlet instance.
The _jspservice()- The container calls the _jspservice() for each request, passing it the request and the response objects.
The jspDestroy()- The container calls this when it decides take the instance out of service. It is the last method called n the servlet instance.

_________________
best for you
yours, Mahmoud
http://www.templatesdragon.com


TOP
 Profile Send private message  
Reply with quote  
Post new topic Reply to topic Quick reply  [ 1 post ] 
Quick reply


  


 Similar topics
 Topic title   Forum   Author   Comments 
 Please Explain Little Bit More!  PHP  johnmccem  1
 GDI=Income for Life  Job Opportunities  jpc2784  0
 Explain ServletContext.  Servlets / JSP  karkaur  0
 Explain the life cycle methods of a Servlet.  Servlets / JSP  karkaur  0
 Game Of Life 3D  C-C++  blackslither  2

All times are UTC [ DST ]


Users browsing similar posts

Users browsing this forum: No registered users and 2 guests



Jump to:  
Previous Question | Next Question 




Home
General Talks
Finished Projects
Code Library
Games
Tutorials

Java
C/C++
C-sharp
php
Script
JSP/Servlets
Ajax
ASP/ASP.net
Google SEO
Database
Communications
Phpbb3 styles
Photoshop tutorials
Flash tutorials
Find a job






Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
All copyrights reserved to codemiles.com 2007-2011
mileX v1.0 designed by codemiles team