Why does most servlets extend HttpServlet?

Answer Posted / dhiraj

All servlet classes extend the HttpServlet abstract class.
HttpServlet simplifies writing HTTP servlets by providing a
framework for handling the HTTP protocol. Because
HttpServlet is abstract, your servlet class must extend it
and override at least one of its methods. An abstract class
is a class that contains unimplemented methods and cannot be
instantiated itself.

Is This Answer Correct ?    4 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between ear, jar and war file?

576


Explain about RMI Architecture?

612


Difference between DurableSubscription and non- DurableSubscription?

1716


what are the advantages of JTA over JTS?

1674


What is the difference between session and entity beans?

582






what is handle?

1857


Explain about thread synchronization inside a monitor?

2004


Can constructors be synchronized in java?

621


What is a class loader?

591


What do you need to set-up a cluster with jboss?

579


What are JTA/JTS and how they used by client?

1720


Why doesn’t the focus feature on the tag work in every circumstance?

573


What is scalable, portability in the view of J2EE?

1879


the same information whether it will connect to the database or it will be used previous information?

577


Where we can write Rmi registry in the code, without having to write it at the command prompt?

2266