Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Whats the difference between GenericServlet and HttpServlet?

GenericServlet httpservlet
0
Posted

Whats the difference between GenericServlet and HttpServlet?

0

The GenericServlet is an abstract class that is extended by HttpServlet to provide HTTP protocol-specific methods. Java application developers normally extend the HttpServlet because it implements all the HTTP features necessary to create a Web application. The GenericServlet does not include protocol-specific methods for handling request parameters, cookies, sessions and setting response headers. The HttpServlet subclass passes generic service method requests to the relevant doGet() or doPost method. In principle, the GenericServlet could be extended to implement other protocols, such as an FtpServlet for example. Actions: Follow-up, clarify or correct this answer. Submit a new question.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.