File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Calling the service() method

 
Shini Akshi
Greenhorn
Posts: 11
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
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.

thanks
Shini
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
service() of GenericServlet is abstract - it doesn't actually exist. HttpServlet extends GenericServlet and implements the service() method.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic