What is Generic Servlet and how it is different from Http
Servlet?

Answer Posted / l sujata

Actually generic sevlet class is a super class of
HttpServlet class.both of these classes are abstract in
nature.As in generic servlet service () methob is not
defined so they r defined in HttpServlet class. as we are
not interested to create an object of HttpServlet class
so,we make it as abstract class and class that implemnts
HttpServlet Class creates objects and uses three methods
such as init(),service(),destroy() mainly.

Is This Answer Correct ?    6 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the process to implement doget and dopost methods?

540


A client sends requests to two different web components. Both of the components access the session. Will they end up using the same session object or different session ?

599


What is the difference between 2 types of servlets?

634


Which method of the httpservletrequest object is used?

556


Explain how does JSP handle run-time exceptions?

574






Why do we have servlet filters?

591


What are the types of Session Tracking ?

636


How to get the current httpsession object?

644


Can we override servlet service method?

583


What are different Authentication options available in Servlets.

561


How do you communicate in between Applets and Servlets?

583


Define the lifecycle for executing a jsp page.

584


What are the new features added to servlet 2.5?

583


Who is responsible to create the object of servlet?

710


What is the difference between using getSession(true) and getSession(false) methods?

562