Win a copy of AWS Security this week in the Cloud/Virtualization forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
  • Piet Souris
  • salvin francis
  • fred rosenberger

let me get this straight....

Ranch Hand
Posts: 57
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Am I correct in concluding that...

When a HttpServlet receives a request, the object's service(ServletRequest request, ServletResponse response) method is called (inherited from GenericServlet) and that method in turn calls the object's service(HttpServletRequest request, HttpServletResponse response) method.
In essence, the method would look like this...
public void service(ServletRequest request, ServletResponse response) throws IOException, ServletException
service((HttpServletRequest)request, (HttpServletRespose)response); // object casting
Am I on the right track?
Ranch Hand
Posts: 321
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi jimmey,
yeah u r on the right track...whenever a request is made the service method of the Generic Servelet class is called , then if its a HttpServlet the service method has to be overridden by HttpServlet's service( public/protected)which in turn calls either the doGet/doPost as per the mode of request.
Of course, I found a very beautiful couch. Definitely. And this tiny ad:
Devious Experiments for a Truly Passive Greenhouse!
    Bookmark Topic Watch Topic
  • New Topic