Home > DeveloperSection > Interviews > What is ServletConfig object?

Posted on    November-03-2014 11:06 PM

 ASP.Net Java  Session 
 1 Answer(s)
  769  View(s)
Rate this:

Kamlakar Singh
Kamlakar Singh

Total Post:80

Posted on    November-04-2014 12:06 AM

javax.servlet.ServletConfig is used to pass configuration information to Servlet. Every servlet has it’s own ServletConfig object and servlet container is responsible for instantiating this object. We can provide servlet init parameters in web.xml file or through use of WebInitParam annotation. We can use getServletConfig() method to get the ServletConfig object of the servlet.

Don't want to miss updates? Please click the below button!

Follow MindStick