GeekInterview.com
Series: Subject: Topic:
Question: 116 of 398

what is the difference between servlet config and servlet context?

Asked by: eldhose222 | Member Since Jul-2006 | Asked on: Jul 29th, 2006

View all questions by eldhose222

Showing Answers 1 - 2 of 2 Answers
namit

Answered On : Aug 8th, 2006

Servlet context is used for the persistency of the data for the servlets within the same web application or within the same servlet engine.So a particular data is common for all servlets sharing the same web application.Whereas the servlet config is used to use a particular data for each servlet.Other servlet in the web application cannot access the data obtained by servlet config of other user.  Servlet config is used to access the data for itself. Other servlet cant access others servlet config data.

  
Login to rate this answer.
Neeraj

Answered On : Aug 19th, 2006

A servlet configuration object used by a servlet container used to pass information to a servlet during initialization. Servlet context is used to communicated within web container. There is one servlet context per Application per JVM. Servlet Context is part of ServletConfig.ServletContext = ServletConfig.getServletContext()

  
Login to rate this answer.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

Related Open Questions

Ads

Connect

twitter fb Linkedin GPlus RSS

Ads

Interview Question

 Ask Interview Question?

 

Latest Questions

Interview & Career Tips

Get invaluable Interview and Career Tips delivered directly to your inbox. Get your news alert set up today, Once you confirm your Email subscription, you will be able to download Job Inteview Questions Ebook . Please contact me if you there is any issue with the download.