File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes about protected void doGet() ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "about protected void doGet() ?" Watch "about protected void doGet() ?" New topic
Author

about protected void doGet() ?

hasan khan
Ranch Hand

Joined: Aug 04, 2003
Posts: 222

i have created an HttpServlet which overrides

protected void doGet()

since this method is protected how to container calls this method?


SCJP, SCWCD
Mani Ram
Ranch Hand

Joined: Mar 11, 2002
Posts: 1140
The container never calls the doXXX methods. Instead the container always calls the public void service(ServletRequest req, ServletResponse res) method in HttpServlet class. This service method inturn calls the protected void service(HttpServletRequest req, HttpServletResponse resp) method.

This protected service method, then delegate the calls to doXXX methods as required.


Mani
Quaerendo Invenietis
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: about protected void doGet() ?