can we override service method in my servlet class..?? if
yes or no why ??

Answer Posted / muzaffar

Yes, we can override service method. But then we have to give our own implementation to detect which type of method request is using.(i.e GET or POST). Since we mostly use HTTP as a protocol itz best to extend HTTPServlet and override doGET or doPOST accordingly.

Is This Answer Correct ?    2 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What do you mean by session tracking and also explain its techniques?

501


Can we fetch the attributes related to a servlet on a different servlet?

636


Servlet is pure java object or not?

719


How does tomcat servlet container work?

592


Explain how to improve Servlet Performance?

598






What is the difference between 2 types of servlets?

649


What is the difference between servlet and filter?

531


What are the benefits of using servlet over cgi?

580


What is the use of welcome-file-list?

574


What are the functions of Servlet container?

609


What exactly are the functions of servlet?

601


How we can create war file in servlet?

663


Can you explain in detail 'javax.servlet' package?

549


What's the difference between authentication and authorization?

552


What is the difference between portlet and servlet?

514