Complete Servlet notes Day-3
Types of web container: 1. Stand-Alone web container 2. In-Process container 3. Out-Process container Stand alone web container: > This type of container application and server application both are running in same memory space. Servlet Life Cycle Methods: > There are five methods are available inside Servlet interface a. init() b. service() c. destroy() d. getServletConfig() e. getServletInfo() > Out of five methods there are three methods are part of servlet life cycle a. init() b. service() c. destroy() init(): > public void init(ServletConfig cofig)throws SE > After instantiating Servlet class init() method implicitly invoked by the web container jus after execution of constructor block. > For any servlet object init() method will be executed only once. Which type of logic should be placed inside init() method? > If you want to execute any logics exactly once for each servlet object then such type of logics should be placed inside init...