When the methods init() and Distroy() will be called?
Answer Posted / tulasi vani
The servlet life cycle included init() and destroy()(Small
d).
init() is called at the beginning of the servlet,it
performs certain one time activities which are required
during the lifetime of the servlet.It may be some
initialisation of variables or a database connection.
destroy() is called to destroy the servlet.Various
resources which are held by the servlet will be
released,database connections which were opened will be
closed.Later the servlet is destroyed.
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
Explain the servlet context.
How httpservlet is different from the genericservlet?
Why do we have servlet wrapper classes?
How to get the path of servlet in the server?
What is Servlet API used for connecting database?
What is the difference between get and post methods?
What are advantages of servlets over cgi?
What are different ways for servlet authentication?
What is meant by a web application
Why is httpservlet declared abstract?
What is difference between server and servlet?
Explain the features are in servlet 3?
What are the types of servlets? Explain
How can you push data from an Applet to a Servlet?
What is the purpose of requestdispatcher interface?