wood burning stoves 2.0*
The moose likes Servlets and the fly likes Calling the service() method Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Calling the service() method" Watch "Calling the service() method" New topic

Calling the service() method

Shini Akshi

Joined: Oct 21, 2007
Posts: 11
Can somebody help me on this.
Considering the life cycle of Servlet,if init() is not overridden , init() of GenericServlet is called.Then the service() of HttpServlet class is called. service() is available in the GenericServlet also. Could you please describe me the reason for calling service() of HttpServlet class rather than calling service() of GenericServlet.

David O'Meara

Joined: Mar 06, 2001
Posts: 13459

service() of GenericServlet is abstract - it doesn't actually exist. HttpServlet extends GenericServlet and implements the service() method.
I agree. Here's the link: http://aspose.com/file-tools
subject: Calling the service() method
Similar Threads
what code will be there in init() of GenericServlet
why HttpServlet class is abstract
HFSJ 2 ed. Final mock exam 43 question
Basic Servlet Doubt
init() and init(ServletConfig) doubt?