File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "servlets" Watch "servlets" New topic
Author

servlets

vasanthrao kumarbabu
Greenhorn

Joined: Jul 02, 2007
Posts: 1
hi , if we want to write any servlet this should be extends from HttpServlet it is an abstract class but in our class we are not implementing any methods. and we are not declaring our class as abstract why it is.
Rahul Bhattacharjee
Ranch Hand

Joined: Nov 29, 2005
Posts: 2308
Originally posted by vasanthrao kumarbabu:
we are not declaring our class as abstract why it is.


There are no methods in HTTPServlet class which are abstract.So no need to declare the class abstract which is extending the HTTPServlet class.


Rahul Bhattacharjee
LinkedIn - Blog
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

If you want your servlet to do something, you'll have to override at least one of the methods. Usually this is doPost, doGet, or both.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: servlets
 
Similar Threads
collection Framework
Abstract class
Regarding abstract class
why we not override method of HttpServlet
Why HttpServlet is abstract ?