MCQs Test!! VB Basic Test !! Essentials of VB !! Creating User Services !! function !! Anatomy !! GK March-2019 !! DATA TYPES IN JAVA !! Classes ,Constructor ,Methods,Inheritance !! Ecology-I !! Biology 2019 !! Gk april 2019 !! Biology (living world) !! Plant anatomy !! CELL STRUCTURES AND FUNCTION !! General biology !! Human physiology !! Data structure !! Ecology-II !! GK TEST !! Reproduction in plants !! Human reproduction !! The ABC of C !! Operating system set1 !! Operating system set2 !! Gk and current affairs !! Animal kingdom !! Number system !! Animal kingdom-II !! Gk TEST-III !! Number series !! Microorganisms !! Interview question in c !! Time and Work !! Percentage !! General history !! Average !! Cells !! Locomotion and Movement !! paging !! Bacteriology !! Page replacement policy !! Secondary memory and Disk scheduling !! Introduction of Nervous System and neurons !! Plant harmones !! Transport and Mineral Nutrition in Plants !! Neurotransmitters !! Modern Indian History !! Photosynthesis in Plants !! Modern Indian History-II !! Plant respiration !! Environment & Biodiversity !! Environment & Biodiversity - II !! Algae, Bryophytes, Pteridophytes !! Area !! Cricket !! Days of the Year (India and the World) !! Plant Pathology - I !! Indian Transport System !! Plant Pathology - II !! Aptitude !! Biology !! Botany !! C language !! Computer Science !! Core Java !! Gate !! GK !! Mysql !! Operating system !! Physics !! VB-Visual Basic !! Zoology

Java Servlet Programing Laungage

Java Servlet Projects

Servlet Project 3

Java Servlet :ServletContext and servletConfig Interface
Previous Home Next

Servlet Context:

ServletContext is an interface of servlet API, implementation of which is provided by the vendor.An object of type ServletContext is created by the server at the time of application deployment.ServletContext is a interface which helps us to communicate with the servlet container.

There is only one ServletContext for the entire web application and the components of the web application can share it.The ServetContext is created by the container when the web application is deployed and after that only the context is available to each servlet in the web application. This object has following uses:

  1. It is used by the server to provide application scope initialization parameters to the servlet.
  2. It is used by the servlet to share information in the form of attributes accross multiple request.
  3. It is used by the servlet to interact with the web server.



For each servlet webserver creates an object of type ServletConfig.This object has following two use:-

  1. It is used by the server to provide the reference of ServletContext to the servlet.
  2. It is used by the server to provide servlet specific initialization parameters to the servlet.
Previous Home Next