posted 11 years ago
The container calls the appropriate service method based on the http method in the request it receives (i.e. doPost() for a POST, doGet() for a GET...). In your code, if a call is made to the doPost() method, it, in turn, calls the doGet() method. This is done when you want your servlet to do the same thing regardless of whether it is called by a POST or a GET request.