• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

getParameter() and other methods....

 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
This is a basic question....which is pondering in my mind. We have interfaces HttpServletRequest and HttpServletResponse...
When a servlet lets says extends HttpServlet and implements method
doPost( HttpServletRequest req, HttpServletResponse res) {
String whatever = req.getParameter("MyParm");
}
Where is actually getParameter() method implemented ??? is it in the container ?? can we see at its implementation ? is it some network specific ?
Any information in this regard will be helpful...
Thanks
Venkatesh
[ January 09, 2004: Message edited by: venkatesh rajmendram ]
 
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
as the name sugests, it is implemented in the HttpServletRequest .
 
venkatesh rajmendram
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi...
BTW the HttpServletRequest is an interface...There will not be implementation of getParameter() in interface....It should be implemented in some concrete or abstract class...
So still the question remains...
- Venkatesh
 
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by venkatesh rajmendram:
Hi,
This is a basic question....which is pondering in my mind. We have interfaces HttpServletRequest and HttpServletResponse...
When a servlet lets says extends HttpServlet and implements method
doPost( HttpServletRequest req, HttpServletResponse res) {
String whatever = req.getParameter("MyParm");
}
Where is actually getParameter() method implemented ??? is it in the container ?? can we see at its implementation ? is it some network specific ?
Any information in this regard will be helpful...
Thanks
Venkatesh
[ January 09, 2004: Message edited by: venkatesh rajmendram ]


Yes, the actual implementation of HttpServletRequest is provided by the Container!
 
Ranch Hand
Posts: 662
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The container with wrap the client request into a nice object(not sure of what class ) that implements the HttpServletRequest interface which is provided to our servlet's http methods.
 
reply
    Bookmark Topic Watch Topic
  • New Topic