Which method the Servlet container call to create the
instance of the servlet?

Answer Posted / ravikiran(aptech mumbai)

After The successfull parsing of web.xml container will find
the particular class name which is mapped in web.xml and calls
class.forName(classname).newInstance() method.Then calls
init(ServletConfig config) of GenericServlet for
initializing the instance of the servlet.

Is This Answer Correct ?    35 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is servlet in tomcat?

550


What is SingleThreadModel interface?

663


Is servlet a framework?

526


What is the element?

577


Why do we need servlet filter?

557






What are some advantages of storing session state in cookies?

585


What is the difference between the http servlet and generic servlet?

587


how many jsp scripting elements are there and what are those?

534


What is cookie? Why is cookie used?

570


What is Servlets and explain the advantages of Servlet life cycle?

574


Explain the concept of ssi ?

581


What is servlet invoker?

593


How do I use cookies to store session state on the client?

523


What are the steps that are involved in using the httpservlet class?

562


What are the phases of the servlet life cycle?

595