Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

why are extending GenericServlet and why are extending
HttpServlet explain?

Answer Posted / mahesh

There are some reasons are exited they are as follows
-->GenericServlet is protocol independent where as HttpServlet is protocol dependent .
-->Due to the un implementation of http protocol GenericServlet will not provide any flexibility for the developers to specify different types of request at client mechine.
i.e. If you specify any type of request at client mechine like get,post,head.....when at server side GenericServlet able to process all this request as a normal request by calling service().
-->Due to the imlementation of HttpProtocol in HttpServlet,vl provide very good flexibility for the request at client mechine .
i.e. If we specify the request types like get,post...client mechine then HS vl execute doGet(),doPost().....respectivly at serverside.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is cookie in servlet?

1060


What do you mean by a filter and how does it work?

955


Explain the servlet context.

1146


What is difference between ServletResponse sendRedirect() and RequestDispatcher forward() method?

1109


Why doesn’t a servlet include main()?

1050


Which protocol will be used by browser and servlet to communicate

1059


Explain the features are in servlet 3?

1054


What do you mean by default initialization in java servlet?

1101


What is servlet initializer?

976


What’s the use of the servlet wrapper classes??

1107


What is servletconfig?

1034


When a servlet accepts a call from a client, it receives two objects. What are they?

1245


What is the use of send redirect () method?

1091


What is the difference between Difference between doGet() and doPost()?

1302


What is the use of servletconfig interface?

1049