What are the methods in HttpServlet?

Answer Posted / prince singh

Guys there are several methods present in HttpServlet
1.void doGet(),
2.void doPost(),
3.void doDelete(),
4.void doHead(),
5.void doOptions(),
6.void doTrace(),
7.void doPut(),

8.long getLastModified(),
9.public service(ServletRequest request,ServletResponse)

This services method internaly call public service method
10.protected service(HttpServletRequest request,HttpServletResponse)

protected service method calls to the doGet or doPost method according to the users requirement.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why servlet is mostly used?

748


Can filter be used as request or response?

546


What is load-on-startup in servlet?

588


What are the advantages of servlets over traditional cgi?

632


What are the different mode that servlets can be used?

557






What are the benefits of using servlet over cgi?

582


Explain the war file?

612


What are the different methods of session management in servlets?

543


What is cookie? Why is cookie used?

585


Explain session tracking and its importance?

548


Explain the methods of request dispatcher in servlet?

517


Whether we can get deadlock situation in servlets?

578


What are the types of servlets? Explain

678


Explain jsessionid and when is it created?

597


What is servlet used for?

698