The essence of ServletContext

I understand the ServletContext, I understand the very essence, with this interface we can get data about the environment in which the servlet is running, but how to apply this data and where in practice, I do not understand who can explain it.

Author: Dima Kovbasa, 2016-06-25

1 answers

ServletContext is a resource that is available within the session or in the HttpSession object, which can be obtained from HttpServletRequest, which is available in all classes involved in processing http requests, respectively, ServletContext is usually used as a session scope resource in the controller or view of standard MVC applications.

And more... A shared resource is used to exchange data between independent application components, such as scope variables class visibility, in particular cases, is used to exchange data between the methods of the class.

 3
Author: Jeck Jeck, 2016-06-25 14:51:23