why are using HttpServlet in realtime projects and why are
not using Genericservlet
Answer Posted / prakash
Generic servlet is a abstract class which is not
implementing service() method,to serve the client requests
service method has to execute. and also generic servlet is
containing all general statements,and methods which are
changing by protocol wise.
But HttpServlet is a Http protocol specific class,it is also
one abstract class,eventhough all methods got implemented it
is qualified as abstract class to restrict the creation of
objects. Httpservlt class is implementing service() method
to serve the client requests.
so we are using HttpServlet in realtime projects.
| Is This Answer Correct ? | 8 Yes | 1 No |
Post New Answer View All Answers
How native code can be used in a servlet?
What are life cycle methods of a servlet?
How does tomcat servlet container work?
How can the session in servlet can be destroyed?
Why session tracking is needed?
When servlet object is created?
What are the life cycle methods of the servlet?
What is the difference between the servlets and cgi programs?
What is the major difference between servlet and applet?
What is servlet? Explain
What is life cycle of Servlet?
Whether we can get deadlock situation in servlets?
When should you prefer to use doget() over dopost()?
Name the different ways of session tracking.
What is servlet configuration?